mirror of
https://github.com/YunoHost-Apps/borg_ynh.git
synced 2024-09-03 18:16:05 +02:00
Rename backup-with-$app to backup-with-borg now that it's in install_dir
This commit is contained in:
parent
3f9a00861d
commit
2c20d67d51
4 changed files with 9 additions and 9 deletions
|
@ -1 +1 @@
|
||||||
__APP__ ALL=(root) NOPASSWD: __INSTALL_DIR__/backup-with-__APP__, __INSTALL_DIR__/venv/bin/borg, /usr/bin/yunohost backup create *, /usr/bin/yunohost app setting *, /bin/ls, /usr/bin/test
|
__APP__ ALL=(root) NOPASSWD: __INSTALL_DIR__/backup-with-borg, __INSTALL_DIR__/venv/bin/borg, /usr/bin/yunohost backup create *, /usr/bin/yunohost app setting *, /bin/ls, /usr/bin/test
|
||||||
|
|
|
@ -4,7 +4,7 @@ After=network.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=oneshot
|
Type=oneshot
|
||||||
ExecStart=/usr/bin/sudo __INSTALL_DIR__/backup-with-__APP__ __APP__
|
ExecStart=/usr/bin/sudo __INSTALL_DIR__/backup-with-borg __APP__
|
||||||
User=__APP__
|
User=__APP__
|
||||||
Group=__APP__
|
Group=__APP__
|
||||||
|
|
||||||
|
|
|
@ -61,9 +61,9 @@ mkdir -p /usr/share/yunohost/backup_method
|
||||||
ynh_add_config --template="backup_method" --destination="/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
ynh_add_config --template="backup_method" --destination="/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
||||||
chmod go=--- "/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
chmod go=--- "/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
||||||
|
|
||||||
ynh_add_config --template="backup-with-borg" --destination="$install_dir/backup-with-$app"
|
ynh_add_config --template="backup-with-borg" --destination="$install_dir/backup-with-borg"
|
||||||
chmod u+x "$install_dir/backup-with-$app"
|
chmod u+x "$install_dir/backup-with-borg"
|
||||||
chown "$app:$app" "$install_dir/backup-with-$app"
|
chown "$app:$app" "$install_dir/backup-with-borg"
|
||||||
|
|
||||||
ynh_add_config --template="sudoer" --destination="/etc/sudoers.d/$app"
|
ynh_add_config --template="sudoer" --destination="/etc/sudoers.d/$app"
|
||||||
chown root:root "/etc/sudoers.d/$app"
|
chown root:root "/etc/sudoers.d/$app"
|
||||||
|
|
|
@ -58,7 +58,7 @@ fi
|
||||||
if [ -d /opt/borg-env ]; then
|
if [ -d /opt/borg-env ]; then
|
||||||
ynh_secure_remove --file="/opt/borg-env"
|
ynh_secure_remove --file="/opt/borg-env"
|
||||||
ynh_secure_remove --file="/usr/local/bin/borg"
|
ynh_secure_remove --file="/usr/local/bin/borg"
|
||||||
ynh_secure_remove --file="/usr/local/bin/backup-with-$app"
|
ynh_secure_remove --file="/usr/local/bin/backup-with-borg"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -86,9 +86,9 @@ mkdir -p /usr/share/yunohost/backup_method
|
||||||
ynh_add_config --template="backup_method" --destination="/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
ynh_add_config --template="backup_method" --destination="/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
||||||
chmod go=--- "/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
chmod go=--- "/etc/yunohost/hooks.d/backup_method/05-${app}_app"
|
||||||
|
|
||||||
ynh_add_config --template="backup-with-borg" --destination="$install_dir/backup-with-$app"
|
ynh_add_config --template="backup-with-borg" --destination="$install_dir/backup-with-borg"
|
||||||
chmod u+x "$install_dir/backup-with-$app"
|
chmod u+x "$install_dir/backup-with-borg"
|
||||||
chown "$app:$app" "$install_dir/backup-with-$app"
|
chown "$app:$app" "$install_dir/backup-with-borg"
|
||||||
|
|
||||||
ynh_add_config --template="sudoer" --destination="/etc/sudoers.d/$app"
|
ynh_add_config --template="sudoer" --destination="/etc/sudoers.d/$app"
|
||||||
chown root:root "/etc/sudoers.d/$app"
|
chown root:root "/etc/sudoers.d/$app"
|
||||||
|
|
Loading…
Add table
Reference in a new issue