diff options
-rw-r--r-- | debian/vyatta-cfg.postinst.in | 3 | ||||
-rw-r--r-- | scripts/vyos-user-postcommit-hooks.sh | 2 | ||||
-rw-r--r-- | scripts/vyos-user-precommit-hooks.sh | 2 |
3 files changed, 4 insertions, 3 deletions
diff --git a/debian/vyatta-cfg.postinst.in b/debian/vyatta-cfg.postinst.in index f840803..6907b7e 100644 --- a/debian/vyatta-cfg.postinst.in +++ b/debian/vyatta-cfg.postinst.in @@ -47,6 +47,7 @@ rm -f /etc/bash_completion.d/20vyatta-cfg # create symlink for post commit hook ln -sf /opt/vyatta/sbin/vyatta-log-commit.pl /etc/commit/post-hooks.d/10vyatta-log-commit.pl +# User pre/post-commit hook executors ln -s /opt/vyatta/sbin/vyos-user-precommit-hooks.sh /etc/commit/pre-hooks.d/99vyos-user-precommit-hooks -ln -s /opt/vyatta/sbin/vyos-user-postcommit-hooks.sh /etc/commit/pre-hooks.d/99vyos-user-postcommit-hooks +ln -s /opt/vyatta/sbin/vyos-user-postcommit-hooks.sh /etc/commit/post-hooks.d/99vyos-user-postcommit-hooks diff --git a/scripts/vyos-user-postcommit-hooks.sh b/scripts/vyos-user-postcommit-hooks.sh index fd23f82..22298a7 100644 --- a/scripts/vyos-user-postcommit-hooks.sh +++ b/scripts/vyos-user-postcommit-hooks.sh @@ -1,5 +1,5 @@ #!/bin/sh if [ -d /config/scripts/commit/post-hooks.d/ ]; then - /bin/run-parts /config/scripts/commit/post-hooks.d + sg vyattacfg -c "/bin/run-parts /config/scripts/commit/post-hooks.d" fi diff --git a/scripts/vyos-user-precommit-hooks.sh b/scripts/vyos-user-precommit-hooks.sh index cae38db..85b0151 100644 --- a/scripts/vyos-user-precommit-hooks.sh +++ b/scripts/vyos-user-precommit-hooks.sh @@ -1,6 +1,6 @@ #!/bin/sh if [ -d /config/scripts/commit/pre-hooks.d/ ]; then - /bin/run-parts /config/scripts/commit/pre-hooks.d + sg vyattacfg -c "/bin/run-parts /config/scripts/commit/pre-hooks.d" fi |