Unfortunately in that case the shell provisioner doesn't get called at all, 
I suspect because vagrant doesn't detect its definition.

On Saturday, 19 November 2016 22:12:47 UTC+11, Alvaro Miranda Aguilera 
wrote:
>
> Hello
>
> What happens if you put the shell provider inside the trigger block?
>
>     config.vm.provision "trigger" do |t|
>         
>         # this code is for clarification sake
>         print "#{aws_access_key}\n" # prints foo
>         print "#{aws_access_secret}\n" # prints bar
>         # =========================================
>    
>         t.fire do
>    
>             # this code is for clarification sake
>             print "#{aws_access_key}\n" # prints foo
>             print "#{aws_access_secret}\n" # prints bar
>             # =========================================
>    
>             print "Please provide your AWS credentials\n"
>             print "aws_access_key: "
>             aws_access_key = STDIN.noecho(&:gets).chomp # say I type qwerty
>             print "\naws_access_secret: "
>             aws_access_secret = STDIN.noecho(&:gets).chomp  # say I type 
> ytrewq
>             print "\n"
>     
>             # this code is for clarification sake
>             print "#{aws_access_key}\n" # prints qwerty
>             print "#{aws_access_secret}\n" # prints ytrewq
>
>             config.vm.provision "shell" do |s|
>                 s.inline = "echo Key: $1 Secret: $2" # echos foo and bar
>                 s.args = ["#{$aws_access_key}", "#{$aws_access_secret}"]
>             end       
>
>             # =========================================
>         end
>     end
>
>
>
>
>
>
>
> On 19/11/2016, at 9:54 AM, Marco Debo De Bortoli <[email protected] 
> <javascript:>> wrote:
>
> Hi everyone,
>
> I opened an issue on the relevant repo but I didn't get any reply so far 
> but I am fairly sure someone on here with better ruby/vagrant knowledge 
> than me, could also help.
>
> The problem is described here 
> https://github.com/emyl/vagrant-triggers/issues/77 and it still ongoing, 
> I am trying pretty much everything I can without great results. Any 
> idea/suggestion on how to acheive what I want?
>
> Thanks a lot for you help and consideration.
>
> Cheers,
> Debo
>
>
>
> -- 
> This mailing list is governed under the HashiCorp Community Guidelines - 
> https://www.hashicorp.com/community-guidelines.html. Behavior in 
> violation of those guidelines may result in your removal from this mailing 
> list.
>  
> GitHub Issues: https://github.com/mitchellh/vagrant/issues
> IRC: #vagrant on Freenode
> --- 
> You received this message because you are subscribed to the Google Groups 
> "Vagrant" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected] <javascript:>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/vagrant-up/CAM6ypFF%3Di%3DF7m7UKC0OsbWQnkjHMG-N5_nHhy1pYKgf9Uz%2BULg%40mail.gmail.com
>  
> <https://groups.google.com/d/msgid/vagrant-up/CAM6ypFF%3Di%3DF7m7UKC0OsbWQnkjHMG-N5_nHhy1pYKgf9Uz%2BULg%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
This mailing list is governed under the HashiCorp Community Guidelines - 
https://www.hashicorp.com/community-guidelines.html. Behavior in violation of 
those guidelines may result in your removal from this mailing list.

GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
--- 
You received this message because you are subscribed to the Google Groups 
"Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vagrant-up/11b50ba0-078d-4ae8-9d12-c7d05130c65e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to