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

Logging #3

Closed
mitchellh opened this issue Apr 27, 2013 · 2 comments
Closed

Logging #3

mitchellh opened this issue Apr 27, 2013 · 2 comments
Milestone

Comments

@mitchellh
Copy link
Contributor

Logging is critical in my ability to debug things on Vagrant, and it wasn't added until like... 0.7. I don't want to make that same mistake with Packer. Let's put logging in RIGHT AWAY.

Key ideas:

  • PACKER_LOG environmental variable for controlling verbosity.
  • Multiple levels: debug, info, warn, etc. I don't actually care what they're named, just that they exist.
  • Must be easily available to all parts of the packer program and libraries.

Thoughts on implementation:

  • I think a global "Logger" like variable would be nice so ANY library component can hook into loggers.
  • However, it might be nice to have one logger per packer Environment. But is an Environment necessary for using other components that might want to log? Probably not. Ugh.
  • If we are running multiple packer builds in parallel, we'll want to be able to differentiate log output from the different builds.
@mitchellh
Copy link
Contributor Author

For simplicity, I just decided to use the standard log package. In the future we can differentiate between log levels using Unix tools like "grep". Some key points on how things work:

  • For packer, we'll configure log output depending on PACKER_LOG
  • For packer/plugin, log output ALWAYS goes to STDERR. The plugin client reads this in and appends it to the main app log, so we can even get the log output of plugins. Hizzah!

@mitchellh
Copy link
Contributor Author

Done? I think. WEE!

mitchellh pushed a commit that referenced this issue Nov 5, 2013
… the net_device template value, virtio is incorrect -- must be virtio-net).
mitchellh pushed a commit that referenced this issue Apr 28, 2014
… the net_device template value, virtio is incorrect -- must be virtio-net).
rasa pushed a commit that referenced this issue Feb 16, 2015
Boot command section was NOT working
gaserre pushed a commit to gaserre/packer that referenced this issue May 15, 2017
Set a number of parameters as defaults
mwhooker pushed a commit that referenced this issue Feb 8, 2018
SwampDragons pushed a commit that referenced this issue Feb 25, 2019
SwampDragons pushed a commit that referenced this issue Oct 21, 2019
* Adding NSG to the ARM eployment template when needed

* Adding tests and fixing bugs

* Removing denyall rule

* Fixing logic to determine which port to open

* Fixing config description
SwampDragons pushed a commit that referenced this issue Mar 2, 2020
Start step_first_boot_device_test and rejigger ParseBootDeviceIdentifier to avoid regex where reasonable.
jhawk28 referenced this issue in jhawk28/packer Mar 3, 2020
Start step_first_boot_device_test and rejigger ParseBootDeviceIdentifier to avoid regex where reasonable.
@hashicorp hashicorp locked and limited conversation to collaborators Apr 10, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant