diff --git a/Vagrantfile b/Vagrantfile index 64decd5..479db84 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -2,7 +2,7 @@ # vi: set ft=ruby : Vagrant.configure(2) do |config| - config.vm.box = "debian/stretch64" + config.vm.box = "debian/buster64" config.vm.hostname = "gvaldap.local" config.vm.network "private_network", ip: "172.16.3.3", lxc__bridge_name: 'vlxcbr1' @@ -14,6 +14,7 @@ Vagrant.configure(2) do |config| config.vm.provision :salt do |salt| salt.bootstrap_script = "salt/bootstrap.sh" + salt.bootstrap_options = "-x python3" salt.minion_id = "gvaldap" salt.masterless = true salt.run_highstate = true diff --git a/docs/changelog.rst b/docs/changelog.rst index fe55a8d..9712d6e 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -1,6 +1,8 @@ Changelog ========= +* :support:`-` update Vagrant setup to Debian Buster and Python 3 + * :release:`0.6.0 <2020-03-03>` * :support:`-` add Python 3 support * :support:`-` upgrade to Django 2.2.10 diff --git a/salt/bootstrap.sh b/salt/bootstrap.sh index faeed2e..52f5494 100755 --- a/salt/bootstrap.sh +++ b/salt/bootstrap.sh @@ -1,19 +1,21 @@ #!/bin/sh - apt-get update -apt-get install -y python-cryptography +apt-get install -y python3-cryptography + +export salt_bootstrap_url=https://bootstrap.saltstack.com/ # We just download the bootstrap script by default and execute that. if [ -x /usr/bin/fetch ]; then - /usr/bin/fetch -o - https://raw.githubusercontent.com/saltstack/salt-bootstrap/stable/bootstrap-salt.sh | sh -s -- "$@" + /usr/bin/fetch -o - $salt_bootstrap_url | sh -s -- "$@" elif [ -x /usr/bin/curl ]; then - /usr/bin/curl -L https://raw.githubusercontent.com/saltstack/salt-bootstrap/stable/bootstrap-salt.sh | sh -s -- "$@" + /usr/bin/curl -L $salt_bootstrap_url | sh -s -- "$@" else - python \ - -c 'import urllib; print urllib.urlopen("https://raw.githubusercontent.com/saltstack/salt-bootstrap/stable/bootstrap-salt.sh").read()' \ - | sh -s -- "$@" + python3 -c "from urllib.request import urlopen; print(urlopen(\"$salt_bootstrap_url\").read().decode('utf-8'))" | sh -s -- "$@" fi +mkdir -p /etc/salt + cat >/etc/salt/minion <