Open hc-github-team-packer opened 2 years ago
With the archival of this repository all open issues will be marked as read-only. If you wish to further discuss this plugin or any of its open issues we invite you to open a discussion on the Packer community forum.
More details on the plugin archiving process for this provisioner can be found on the Plans to Archive Unmaintained Packer Provisioner Plugins blog post.
This issue was originally opened by @ldormoy in https://github.com/hashicorp/packer/issues/6961 and has been migrated to this repository. The original issue description is below.
I use Saltstack with the https://github.com/saltstack/salt-contrib/blob/master/grains/ec2_info.py script to generate ec2-related grains.
When using salt-masterless, the command to use to generate these custom grains would be something like:
This has to be done BEFORE calling state.highstate, as otherwise packer fails with the following error:
Problem: Saltstack is bootstrapped by the salt-masterless provisioner, so there is no way to simply manually run the sync command. It would involve using a file provisioner to sync the salt codebase, then a shell provisioner to manually bootstrap and configure saltstack and then run the salt-call sync command.
Solution: add a flag to allow grains syncing directly in the salt-masterless provisioner.