Skip to content

Conversation

@pix
Copy link
Contributor

@pix pix commented Sep 7, 2017

The first patch adds a debug switch to allow viewing the packer template.
The second one, adds a --profile option (since prepare_config is now aware of args) to override the selected profile in config.js

pix added 2 commits September 7, 2017 14:36
  Added a --show-packer-template debug switch to inspect what is going
  to be sent to packer.

  Useful to debug changes to templates / profiles

Signed-off-by: Camille Moncelier <camille@moncelier.fr>
Signed-off-by: Camille Moncelier <camille@moncelier.fr>
@obilodeau
Copy link
Contributor

--show-packer-template: I'm not fond of exposing a deep debugging option like that to the command-line.

In debug mode, malboxes will leave generated configuration files in the cache folder. That's how I check for issues. Maybe we can modify that behavior so that the generated packer.json will be shown on the command-line in debug mode instead?

--profile: I'm interested but let's see how the discussion in #77 evolves first.

@pix
Copy link
Contributor Author

pix commented Sep 8, 2017

To be honest I submitted this pull request because I spent quite some time doing tests and having a fast way to show what would the packer config looked like was useful (hence the formating using json.loads/json.dumps)

Also when a build failed, a quick --show-packer-template (since the original was deleted) was kind of useful.

Maybe this should be a hidden switch ?

As for the profile I answered in #77

@obilodeau
Copy link
Contributor

I'm willing to see the dump of the full json beautified config when in --debug mode but otherwise, I think either running tests or looking at cache folders should suffice. Thoughts?

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 this pull request may close these issues.

2 participants