Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PACKER_HTTP_ADDR is unset for shell provisioner #117

Closed
sparshev opened this issue Mar 1, 2024 · 0 comments · Fixed by #118
Closed

PACKER_HTTP_ADDR is unset for shell provisioner #117

sparshev opened this issue Mar 1, 2024 · 0 comments · Fixed by #118

Comments

@sparshev
Copy link
Contributor

sparshev commented Mar 1, 2024

It seems the plugin forgets to set the PACKER_HTTP_IP (it's a standard interface of packer) so PACKER_HTTP_ADDR is left unpopulated. It's quite hard to pull any data from the host via standard packer's http server through shell provisioner without this env variable.

  • Current Tart plugin:

    packer-provisioner-shell plugin: [INFO] RPC client: Communicator ended with: 0
    packer-plugin-tart_v1.8.1_x5.0_darwin_arm64 plugin: 2024/02/29 16:25:30 [DEBUG] Opening new ssh session
    packer-plugin-tart_v1.8.1_x5.0_darwin_arm64 plugin: 2024/02/29 16:25:30 [DEBUG] starting remote command: chmod +x /tmp/script_2697.sh; PACKER_BUILDER_TYPE='tart-cli' PACKER_BUILD_NAME='tart-cli' PACKER_HTTP_PORT='8625'  /tmp/script_2697.sh
    
  • VMX:

    ...
    packer-provisioner-shell plugin: [INFO] RPC client: Communicator ended with: 0
    packer-builder-vmware-vmx plugin: [DEBUG] Opening new ssh session
    packer-builder-vmware-vmx plugin: [DEBUG] starting remote command: chmod +x /tmp/script_2346.sh; PACKER_BUILDER_TYPE='vmware-vmx' PACKER_BUILD_NAME='vmware-vmx' PACKER_HTTP_ADDR='172.16.1.1:8350' PACKER_HTTP_IP='172.16.1.1' PACKER_HTTP_PORT='8350'  /tmp/script_2346.sh
    ...
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant