-
Notifications
You must be signed in to change notification settings - Fork 5
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
Fix/Install Packer plugins when building the observatory image #641
Conversation
Codecov ReportAll modified lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #641 +/- ##
===========================================
+ Coverage 87.14% 87.16% +0.01%
===========================================
Files 34 34
Lines 4691 4697 +6
Branches 572 572
===========================================
+ Hits 4088 4094 +6
Misses 486 486
Partials 117 117
☔ View full report in Codecov by Sentry. |
"""Install the necessary plugins for packer.""" | ||
|
||
# Install the Packer plugins by doing an init on the observatory image config file | ||
args = ["packer", "init", "observatory-image.json.pkr.hcl"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the image config file always in the same directory that the packer script is being run? Would it be better to supply the absolute path?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is OK because the current working directory is set below cwd=self.terraform_build_path
acd7369
to
90926b8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing this Alex
"""Install the necessary plugins for packer.""" | ||
|
||
# Install the Packer plugins by doing an init on the observatory image config file | ||
args = ["packer", "init", "observatory-image.json.pkr.hcl"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is OK because the current working directory is set below cwd=self.terraform_build_path
Forgot to add this with the recent Packer upgrade. The new observatory-image.json.pkr.hcl file relies on external plugins to be installed first before the observatory-image can be built. I did this manually before when I upgraded so I missed it adding it to the platform.
I've tested it with a fresh Packer installation and I've added a unit test to suit.
Please review and edit as needed.