add user scripts support to sabnzbd
This commit is contained in:
parent
eb6c6eae60
commit
d121d1284c
sabnzbd
|
@ -23,6 +23,8 @@ kind: Deployment
|
|||
metadata:
|
||||
namespace: sabnzbd
|
||||
name: sabnzbd
|
||||
annotations:
|
||||
"reloader.stakater.com/auto": "true"
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
|
@ -61,6 +63,10 @@ spec:
|
|||
capabilities:
|
||||
add: ["NET_ADMIN","SYS_TIME"]
|
||||
volumes:
|
||||
- name: scripts
|
||||
configMap:
|
||||
name: sabnzbd-scripts
|
||||
defaultMode: 0555
|
||||
- name: config
|
||||
nfs:
|
||||
server: 172.16.18.1
|
||||
|
@ -80,6 +86,8 @@ spec:
|
|||
- name: PGID
|
||||
value: "101"
|
||||
volumeMounts:
|
||||
- mountPath: /scripts
|
||||
name: scripts
|
||||
- mountPath: /volume1/dropbox
|
||||
name: dropbox
|
||||
- mountPath: /config
|
||||
|
|
23
sabnzbd/scripts.yaml
Normal file
23
sabnzbd/scripts.yaml
Normal file
|
@ -0,0 +1,23 @@
|
|||
apiVersion: v1
|
||||
data:
|
||||
pp.sh: |
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
cd "$SAB_COMPLETE_DIR"
|
||||
|
||||
if [ $SAB_UNPACK -eq 0 ];then
|
||||
echo Skipping Extra Unpack
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ $SAB_UNPACK -ne 0 ];then
|
||||
find . -name '*.part01.rar' -exec unrar x {} +
|
||||
find . -name '*.zip' -exec unzip {} +
|
||||
fi
|
||||
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
creationTimestamp: null
|
||||
name: sabnzbd-scripts
|
||||
namespace: sabnzbd
|
Loading…
Reference in New Issue
Block a user