migrate setup to s6-rc

This commit is contained in:
Daniel Wolf 2022-03-04 15:56:53 -05:00
parent d5a59ef904
commit 4c27ecf522
Signed by: nephatrine
GPG Key ID: 59D70EC2E4AAB4D0
7 changed files with 14 additions and 9 deletions

View File

@ -1,7 +0,0 @@
#!/usr/bin/with-contenv bash
if [[ ! -d /mnt/media/_h5ai ]]; then
s6-setuidgid guardian mkdir -p /mnt/media/_h5ai
fi
s6-setuidgid guardian cp -Rn /var/www/html/_h5ai/* /mnt/media/_h5ai/
s6-setuidgid guardian cp -R /var/www/html/_h5ai/private/php/* /mnt/media/_h5ai/private/php/

View File

@ -1,2 +0,0 @@
/mnt/media false guardian:users,1000:100 0644 0755
/mnt/media/_h5ai false guardian:users,1000:100 0644 0755

View File

@ -0,0 +1 @@
oneshot

View File

@ -0,0 +1,10 @@
#!/command/execlineb
foreground { /bin/chown guardian:users /mnt/media }
foreground {
if -n { /usr/bin/test -d /mnt/media/_h5ai }
/command/s6-setuidgid guardian /bin/mkdir -p /mnt/media/_h5ai
}
foreground { /command/s6-setuidgid guardian /bin/cp -Rn /var/www/html/_h5ai /mnt/media/ }
foreground { /command/s6-setuidgid guardian /bin/cp -R /var/www/html/_h5ai/private/php /mnt/media/_h5ai/private/ }

View File

@ -0,0 +1 @@

View File

@ -0,0 +1 @@