Skip to content
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

Define environment variables and timeout in code #109

Merged
merged 2 commits into from
Oct 17, 2023

Conversation

jacksonj04
Copy link
Collaborator

@jacksonj04 jacksonj04 commented Oct 16, 2023

Previously we didn't define any environment variables at deploy time; instead we set them manually. A configuration change when we moved from Python 3.9 to 3.11 caused SAM to redefine the infrastructure, and this in turn caused a all existing environment variables to be wiped, bringing down the staging ingester.

This PR moves to defining the environment variables in the template.yml file which is used by SAM. The exact values are passed in at deploy time by GitHub Actions as part of configuring the infrastructure.

Variables are stored in GitHub environments.

@jacksonj04 jacksonj04 force-pushed the fix/env-variables-are-set-properly-on-deploy branch from 0a05122 to 83a49ae Compare October 16, 2023 16:47
@jacksonj04 jacksonj04 temporarily deployed to staging October 16, 2023 16:47 — with GitHub Actions Inactive
@jacksonj04 jacksonj04 force-pushed the fix/env-variables-are-set-properly-on-deploy branch from 83a49ae to dd33c27 Compare October 16, 2023 17:04
@dragon-dxw dragon-dxw changed the title Fix deploy Update how we perform deployments to set environment variables Oct 16, 2023
@dragon-dxw
Copy link
Collaborator

Currently suffering from a 3s timeout -- not ready for deploy to live.

@dragon-dxw dragon-dxw changed the title Update how we perform deployments to set environment variables ⚠️ Update how we perform deployments to set environment variables Oct 16, 2023
Previously we didn't define any environment variables at deploy time;
instead we set them manually. A configuration change when we moved from
Python 3.9 to 3.11 caused SAM to redefine the infrastructure, and this
in turn caused a all existing environment variables to be wiped,
bringing down the staging ingester.

This PR moves to defining the environment variables in the
`template.yml` file which is used by SAM. The exact values are passed in
at deploy time by GitHub Actions as part of configuring the
infrastructure.

Variables are stored in GitHub environments.
@jacksonj04 jacksonj04 force-pushed the fix/env-variables-are-set-properly-on-deploy branch from dd33c27 to 2409e83 Compare October 17, 2023 07:28
The default is three seconds, which isn't enough time for tasks to
complete.
@jacksonj04 jacksonj04 changed the title ⚠️ Update how we perform deployments to set environment variables Define environment variables and timeout in code Oct 17, 2023
@jacksonj04 jacksonj04 merged commit dc0a326 into main Oct 17, 2023
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