-
Notifications
You must be signed in to change notification settings - Fork 16
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
[Issue #3003] Add deployment info #3072
Conversation
run: make release-deploy \ | ||
APP_NAME=${{ inputs.app_name }} \ | ||
ENVIRONMENT=${{ inputs.environment }} \ | ||
DEPLOY_GITHUB_REF=${{ github.ref_name }} \ |
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 ref always the branch name, or does it become the release?
Just thinking about how we build the URLs in the API with this.
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.
@chouinar I'm pretty sure its the raw tag name, so the 2024.11.27-1
in https://github.com/HHS/simpler-grants-gov/tree/2024.11.27-1
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.
Will there be a consistent URL I can build if it can refer to both a branch and a release? Any pattern of github.com/something/<branch or release>
that I can follow?
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.
Err, I suppose the /tree
path does, but for releases I wonder if linking to the release page would be better - could maybe regex that
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.
For both the ref and commit the URL is gonna be https://github.com/HHS/simpler-grants-gov/tree/< commit / branch / release >
, examples:
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!
## Summary Relates to #3003, followup from #3072 Completes 50% of #3149 ### Time to review: __2 mins__ ## Changes proposed - adds DEPLOY_WHOAMI to the deploy metadata environment variables - adds them to the module layer so they're present on every service we deploy - removes from the CLI inputs because they're being input by terraform shell commands now (which is something I should have thought about sooner!) ## Testing From Github actions: <img width="325" alt="image" src="https://github.com/user-attachments/assets/a9417006-5a00-4aea-98e7-8885995ccb1d"> Locally: <img width="313" alt="image" src="https://github.com/user-attachments/assets/61972d42-eb2e-46ae-8857-acb9e5655782">
Summary
Relates #3003
Time to review: 5 mins
Changes proposed
Adds the following environment variables to API deployments:
You can find the definitions for these values here: https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/store-information-in-variables
Testing
https://us-east-1.console.aws.amazon.com/ecs/v2/task-definitions/api-dev/288/json?region=us-east-1
^ note that terraform doesn't provide a UNIX timestamp, which I'm a bit bummed about. But maybe we only put the timestamp into the healthcheck, and keep it as is?