-
Notifications
You must be signed in to change notification settings - Fork 120
Add helper script for creating deployment connectivity resources #1306
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
base: main
Are you sure you want to change the base?
Conversation
✅ Deploy Preview will be available once build job completes!
|
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'm personally good with this, but will leave it to @JTorreG to approve and merge
To set up connectivity to your NGINXaaS deployment, you will need to configure a [Private Service Connect backend](https://cloud.google.com/vpc/docs/private-service-connect-backends). | ||
|
||
1. Access the [Google Cloud Console](https://console.cloud.google.com/). | ||
1. Access the [Google Cloud Console](https://console.cloud.google.com/) and choose a project where you would like to create resources for connecting to your F5 NGINXaaS deployment. |
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.
1. Access the [Google Cloud Console](https://console.cloud.google.com/) and choose a project where you would like to create resources for connecting to your F5 NGINXaaS deployment. | |
1. Access the [Google Cloud Console](https://console.cloud.google.com/) and select the project where your networking resources for connecting to your F5 NGINXaaS deployment should be created. |
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.
(probably just my own personal word style -- didn't like the "where you would like to" verbiage, but feel free to resolve as really not important)
- For **Port number**, enter the same port as your NEG's Producer port, for example, port `80`. | ||
|
||
|
||
If you have multiple ports configured on NGINX, you will have to create a new network endpoint group for every port. You can also automate these steps by using the following helper script: |
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.
If you have multiple ports configured on NGINX, you will have to create a new network endpoint group for every port. You can also automate these steps by using the following helper script: | |
Each listening port configured on NGINX requires its own network endpoint group with a matching port. You can use the following helper script to automate these steps: |
{{< details summary="Show helper script" >}} | ||
|
||
```bash | ||
#!/bin/bash |
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 we should always apply set -eo pipefail
in any bash scripts, otherwise poor error handling can lead to unexpected results.
I'd also suggest -u
to ensure any expected env vars are set (set -euo pipefail
)
Example: | ||
$0 --project my-project --region us-central1 --network my-vpc \\ | ||
--service-attachment "projects/producer-proj/regions/us-central1 serviceAttachments/ my-service" \\ |
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.
there are some interesting white-spaces added in this example. intentional?
--service-attachment "projects/producer-proj/regions/us-central1 serviceAttachments/ my-service" \\ | |
--service-attachment "projects/producer-proj/regions/us-central1/serviceAttachments/sa-aa4c6965-4b03-4518-85ea-2ca6fc2e869c" \\ |
# Set auto-generated proxy subnet name and VIP name | ||
PROXY_SUBNET="psc-proxy-subnet" | ||
VIPNAME="psc-vip" |
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.
nit: move these up to the top with the other default env vars. even though there isn't a command line flag to modify them right now, a user might want to just change what is hardcoded and it's easier to find at the top
- For **Port number**, enter the same port as your NEG's Producer port, for example, port `80`. | ||
|
||
|
||
If you have multiple ports configured on NGINX, you will have to create a new network endpoint group for every port. You can also automate these steps by using the following helper script: |
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.
If you have multiple ports configured on NGINX, you will have to create a new network endpoint group for every port. You can also automate these steps by using the following helper script: | |
Each listening port configured on NGINX requires its own network endpoint group with a matching port. You can use the following helper script to automate these steps: |
Proposed changes
Checklist
Before sharing this pull request, I completed the following checklist:
Footnotes
Potentially sensitive information includes personally identify information (PII), authentication credentials, and live URLs. Refer to the style guide for guidance about placeholder content. ↩