Add staging env
This commit is contained in:
parent
38ed9a7943
commit
210082be93
11 changed files with 41 additions and 14 deletions
11
src/env.ts
11
src/env.ts
|
@ -1,5 +1,10 @@
|
|||
if (typeof process.env.REACT_APP_AUTH_LOBBY !== 'string') {
|
||||
throw new Error('ENV: No auth lobby provided')
|
||||
if (typeof process.env.REACT_APP_BUILD !== 'string') {
|
||||
throw new Error('ENV: No env provided')
|
||||
}
|
||||
if (!['dev', 'staging', 'prod'].includes(process.env.REACT_APP_BUILD)) {
|
||||
throw new Error(
|
||||
`ENV: Env must be "dev", "staging", or "prod," got "${process.env.REACT_APP_BUILD}"`,
|
||||
)
|
||||
}
|
||||
|
||||
export const AUTH_LOBBY = process.env.REACT_APP_AUTH_LOBBY
|
||||
export const BUILD = process.env.REACT_APP_BUILD
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue