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

Development #24

Merged
merged 12 commits into from
Mar 7, 2024
4 changes: 3 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@ PORT=3333
HOST=0.0.0.0
NODE_ENV=production
APP_KEY=NZu-mbqukZjV_65cT3ckDB21exh17-ws
DRIVE_DISK=local
DRIVE_DISK=local
NMRIUM_DEV_URL=https://nmriumdev.nmrxiv.org
NMRIUM_PROD_URL=https://nmrium.nmrxiv.org/
2 changes: 2 additions & 0 deletions .env.test
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
NODE_ENV=test
NMRIUM_DEV_URL=https://nmriumdev.nmrxiv.org
NMRIUM_PROD_URL=https://nmrium.nmrxiv.org/
2 changes: 1 addition & 1 deletion .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@ jobs:
release-type: node
package-name: release-please-action
token: ${{ secrets.GITHUB_TOKEN }}
prerelease: true
prerelease: false
4 changes: 2 additions & 2 deletions app/Controllers/Http/SpectraController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ export default class SpectraController {
private generateNMRiumURL() {
const baseURL =
Env.get('NODE_ENV') === 'development'
? 'https://nmriumdev.nmrxiv.org'
: 'https://nmrium.nmrxiv.org/'
? Env.get('NMRIUM_DEV_URL')
: Env.get('NMRIUM_PROD_URL')

const url = new URL(baseURL)
const preferences = JSON.stringify({
Expand Down
2 changes: 2 additions & 0 deletions env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,6 @@ export default Env.rules({
APP_NAME: Env.schema.string(),
DRIVE_DISK: Env.schema.enum(['local'] as const),
NODE_ENV: Env.schema.enum(['development', 'production', 'test'] as const),
NMRIUM_DEV_URL: Env.schema.string(),
NMRIUM_PROD_URL: Env.schema.string(),
})
Loading
Loading