add user scripts support to sabnzbd
This commit is contained in:
parent
eb6c6eae60
commit
d121d1284c
|
@ -23,6 +23,8 @@ kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
namespace: sabnzbd
|
namespace: sabnzbd
|
||||||
name: sabnzbd
|
name: sabnzbd
|
||||||
|
annotations:
|
||||||
|
"reloader.stakater.com/auto": "true"
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
selector:
|
selector:
|
||||||
|
@ -61,6 +63,10 @@ spec:
|
||||||
capabilities:
|
capabilities:
|
||||||
add: ["NET_ADMIN","SYS_TIME"]
|
add: ["NET_ADMIN","SYS_TIME"]
|
||||||
volumes:
|
volumes:
|
||||||
|
- name: scripts
|
||||||
|
configMap:
|
||||||
|
name: sabnzbd-scripts
|
||||||
|
defaultMode: 0555
|
||||||
- name: config
|
- name: config
|
||||||
nfs:
|
nfs:
|
||||||
server: 172.16.18.1
|
server: 172.16.18.1
|
||||||
|
@ -80,6 +86,8 @@ spec:
|
||||||
- name: PGID
|
- name: PGID
|
||||||
value: "101"
|
value: "101"
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
|
- mountPath: /scripts
|
||||||
|
name: scripts
|
||||||
- mountPath: /volume1/dropbox
|
- mountPath: /volume1/dropbox
|
||||||
name: dropbox
|
name: dropbox
|
||||||
- mountPath: /config
|
- 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