mirror of
https://github.com/jbowdre/vagrant-saltlab.git
synced 2024-11-26 15:12:19 +00:00
update config to pull salt content from repo using gitfs
This commit is contained in:
parent
90518cff1d
commit
f67665858b
13 changed files with 19 additions and 8 deletions
27
Vagrantfile
vendored
27
Vagrantfile
vendored
|
@ -13,23 +13,34 @@ Vagrant.configure("2") do |config|
|
|||
salt.vm.provider :libvirt do |libvirt|
|
||||
libvirt.memory = 1024
|
||||
end
|
||||
salt.vm.synced_folder 'srv', '/srv', type: 'rsync'
|
||||
# salt.vm.synced_folder 'srv', '/srv', type: 'rsync'
|
||||
salt.vm.provision "shell", inline: <<-SHELL
|
||||
apt-get update
|
||||
apt-get install curl vim -y
|
||||
apt-get install curl vim python3-pygit2 -y
|
||||
curl -o bootstrap-salt.sh -L https://bootstrap.saltproject.io
|
||||
sh bootstrap-salt.sh -M -X -U
|
||||
cat << EOF > /etc/salt/master.d/lab.conf
|
||||
auto_accept: True
|
||||
auto_accept:
|
||||
file_roots:
|
||||
base:
|
||||
- /srv/salt
|
||||
pillar_roots:
|
||||
base:
|
||||
- /srv/pillar
|
||||
- /srv/
|
||||
fileserver_backend:
|
||||
- roots
|
||||
- gitfs
|
||||
gitfs_provider: pygit2
|
||||
gitfs_update_interval: 60
|
||||
gitfs_base: main
|
||||
gitfs_remotes:
|
||||
- https://github.com/jbowdre/vagrant-saltlab.git:
|
||||
- root: salt_content/salt
|
||||
- mountpoint: salt://
|
||||
ext_pillar:
|
||||
- git:
|
||||
- main https://github.com/jbowdre/vagrant-saltlab.git:
|
||||
- root: pillar
|
||||
reactor:
|
||||
- 'salt/minion/*/start':
|
||||
- /srv/reactor/sync_grains.sls
|
||||
- salt://_reactor/sync_grains.sls
|
||||
EOF
|
||||
systemctl start salt-master
|
||||
systemctl start salt-minion
|
||||
|
|
Loading…
Reference in a new issue