Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment
I want to be able to edit the packer user's groups, then tell packer to refresh the ssh connection so that I don't have to do any hacky business to get my permissions -- I want to be able to tell packer to logout, and login.
Use Case(s)
I am building an EC2 image with a docker image on it. I have to run the docker commands as sudo.
Potential configuration
provisioner "shell" {
inline = [
"sudo usermod -a -G docker ec2-user"
]
}
# 2nd shell provisioner, that can be configured to refresh the connection
provisioner "shell" {
new_connection = true
inline = [
"docker run hello-world"
]
}
Potential References
This was brought up in an old thread of google groups.
Community Note
Please search the existing issues for relevant feature requests, and use the reaction feature (https://blog.github.com/2016-03-10-add-reactions-to-pull-requests-issues-and-comments/) to add upvotes to pre-existing requests.
Description
I want to be able to edit the packer user's groups, then tell packer to refresh the ssh connection so that I don't have to do any hacky business to get my permissions -- I want to be able to tell packer to logout, and login.
Use Case(s)
I am building an EC2 image with a docker image on it. I have to run the docker commands as sudo.
Potential configuration
Potential References
This was brought up in an old thread of google groups.
https://groups.google.com/g/packer-tool/c/XPXwk7PgLcc