-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cdktf: specify deploy environment via environment variable (#187)
* Reorder imports * Build both spotlight and doj-demo on main and stable * Remove "deploy" call from Dockerfile. Context: I don't recall why this is here, but we'll find out soon * Add "pnpm deploy" step * Add separate workspaces for main and staging, and separate scripts for main and staging environments. * Fix type error on story * Use environment variables to distinguish separate deployment environments.
- Loading branch information
1 parent
ecedaa5
commit 9cca8fd
Showing
3 changed files
with
23 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import { App } from 'cdktf'; | ||
|
||
const app = new App(); | ||
|
||
const deployEnv = process.env.DEPLOY_ENV; | ||
|
||
switch (deployEnv) { | ||
case 'dev': | ||
import('./spaces/main'); | ||
break; | ||
case 'staging': | ||
import('./spaces/staging'); | ||
break; | ||
default: | ||
throw new Error('Please specify a valid environment'); | ||
} | ||
|
||
app.synth(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,7 @@ export default { | |
{ | ||
type: 'submit', | ||
text: 'Submit', | ||
submitAction: 'submit', | ||
}, | ||
], | ||
}, | ||
|