saltstack / salt-bootstrap

Generic Salt Bootstrap Script
Other
927 stars 547 forks source link

Not able to run Saltstack service on minion #960

Closed NiteshSaxena closed 8 years ago

NiteshSaxena commented 8 years ago

I've an issue which isn't quite clear of if it's an issue with Vagrant or an issue with salt-bootstrap, Can somebody help me solve it. This is the link to issue on Vagrant project with relevant information: https://github.com/mitchellh/vagrant/issues/7806

rallytime commented 8 years ago

Hi @NiteshSaxena - I am not very knowledgable about windows issues, or how that plays with vagrant, but I think you need to be using the bootstrap-salt.ps1 script instead to install salt on a windows box?

@twangboy Do you have any more information to add?

twangboy commented 8 years ago

@UtahDave ^^^

NiteshSaxena commented 8 years ago

@rallytime, Thanks for your response. I did manage to solve this issue, I am not completely sure but I think the problem was bootstrap-salt.sh and parameters passed to it. My updated Vagrantfile is as below:

config.vm.define :envdev do |minion_config|
    minion_config.vm.box = "ubuntu/trusty64"
    minion_config.vm.hostname = "envdev"
    minion_config.vm.network "private_network", ip: "10.0.1.51"
    minion_config.vm.network "forwarded_port", guest: 80, host: 9001
    minion_config.vm.synced_folder "www", "/vagrant/www"
    minion_config.vm.provision :shell, inline: "apt-get update"
    minion_config.vm.provision :salt do |salt|
      salt.install_master = false
      salt.no_minion = false
      salt.bootstrap_script = "bootstrap-salt.sh"
      salt.bootstrap_options = "-P -D -c /tmp"
      salt.install_type = "stable"
      salt.version = "2016.3.0"
      salt.run_highstate = true
      salt.log_level = "debug"
      salt.minion_id = "envdev"
      salt.minion_config = "saltstack/config/envdev"
      salt.minion_key = "saltstack/keys/envdev.pem"
      salt.minion_pub = "saltstack/keys/envdev.pub"
    end
 end
rallytime commented 8 years ago

Oh, my apologies. I wasn't looking closely enough at your original vagrant file and I assumed you were doing something differently. I am glad you got it working! I'll close this for now.

Let us know if you have any other questions/concerns around this issue and I will gladly re-open it.