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
Add pre-install, post-install hooks to install-ptfe.sh #79
Conversation
This enables SSH connections to other machines from the main primary.
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.
Oh awesome, thanks for doing this over here! So, in AWS (and maybe Azure too?) there's already a startup_script
variable that runs pre-install. It seems that preinstall_script
will supersede this functionality so we should remove the startup_script
along side this addition.
@bnferguson Nice. I didn't consider defining separate scripts for cloud-init. Seems much cleaner. I'll update the GCP one to do the same rather than the script injection. |
This is a cleaner solution than calling the scripts from install-ptfe.sh.
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.
lgtm 🌈 much cleaner. I dig this.
variables.tf
Outdated
default = <<-EOD | ||
#!/bin/bash | ||
|
||
echo 'A post-install script was not provided.' | ||
EOD |
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.
so this isn't an explicit suggestion or a blocking question, but do we as a team have an opinionated stance on heredoc format over using file() for non templated things, this script is small enough to not run into any issues, but to align expectations I'm wondering if we want to put all these in the files/
dir as like postinstall.default.sh
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.
I think that sounds reasonable!
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.
How does b87a7fc look?
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.
Looks great!
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.
LGTM 🌈
Background
Primarily, this branch adds pre-install and post-install script hooks to
install-ptfe.sh
.Secondarily, this makes some minor development changes:
Asana task
How Has This Been Tested
I provisioned a cluster using the root module and verified that the default scripts were executed on primaries and secondaries.
Test Configuration
This PR makes me feel