Created
February 12, 2016 09:52
-
-
Save fabiang/f0a1c93204458c47c00a to your computer and use it in GitHub Desktop.
Revisions
-
fabiang created this gist
Feb 12, 2016 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,7 @@ [Create a Github access token](https://github.com/settings/tokens) and set it globally with: ``` git config --global github.accesstoken your_access_token ``` You can also set a separate token for each project, if you don't pass `--global` to `git config`. This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,15 @@ GITHUB_ACCESSTOKEN=`git config github.accesstoken`.strip! Vagrant.configure("2") do |config| config.vm.define "foobar" do |foobar| foobar.vm.provision :puppet do |puppet| puppet.facter = { "ssh_username" => "vagrant", "github_accesstoken" => GITHUB_ACCESSTOKEN, } puppet.manifests_path = "puppet/manifests" puppet.manifest_file = "site.pp" puppet.options = ["--verbose", "--hiera_config /vagrant/puppet/hiera.yaml", "--parser future"] end end end This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,10 @@ Exec { 'github-accesstoken': command => "git config --global github.accesstoken '$github_accesstoken'", unless => "test `git config --global github.accesstoken` = '$github_accesstoken'", onlyif => "test -n '$github_accesstoken'", before => Composer::Exec['composer-install'], require => Package['git'], user => 'vagrant', environment => "HOME=/home/vagrant", path => "/usr/bin", }