diff options
Diffstat (limited to 'debian')
-rw-r--r-- | debian/control | 1 | ||||
-rw-r--r-- | debian/vyos-1x.install | 1 | ||||
-rw-r--r-- | debian/vyos-1x.postinst | 21 |
3 files changed, 23 insertions, 0 deletions
diff --git a/debian/control b/debian/control index 7b95b2c75..5c176f40a 100644 --- a/debian/control +++ b/debian/control @@ -89,6 +89,7 @@ Depends: python3, pmacct (>= 1.6.0), python3-certbot-nginx, pppoe, + salt-minion, ${shlibs:Depends}, ${misc:Depends} Description: VyOS configuration scripts and data diff --git a/debian/vyos-1x.install b/debian/vyos-1x.install index dd8eebc0b..599f3f3f5 100644 --- a/debian/vyos-1x.install +++ b/debian/vyos-1x.install @@ -2,6 +2,7 @@ etc/dhcp etc/ppp etc/rsyslog.d etc/systemd +etc/sysctl.d etc/udev etc/vyos lib/ diff --git a/debian/vyos-1x.postinst b/debian/vyos-1x.postinst new file mode 100644 index 000000000..a308401ee --- /dev/null +++ b/debian/vyos-1x.postinst @@ -0,0 +1,21 @@ +#!/bin/sh -e +if ! deb-systemd-helper --quiet was-enabled salt-minion.service; then + # Enables the unit on first installation, creates new + # symlinks on upgrades if the unit file has changed. + deb-systemd-helper disable salt-minion.service >/dev/null || true +fi + +if [ -x "/etc/init.d/salt-minion" ]; then + update-rc.d -f salt-minion remove >/dev/null +fi + +# Add minion user for salt-minion +if ! grep -q '^minion' /etc/passwd; then + adduser --quiet --firstuid 100 --system --disabled-login --ingroup vyattacfg --gecos "salt minion user" --shell /bin/vbash minion + adduser --quiet minion frrvty + adduser --quiet minion sudo + adduser --quiet minion adm + adduser --quiet minion dip + adduser --quiet minion disk + adduser --quiet minion users +fi |