BAYSHORE_NIX
This commit is contained in:
parent
393bbf6490
commit
53f64b5276
@ -26,7 +26,7 @@
|
|||||||
in rec {
|
in rec {
|
||||||
packages.bayshore = pkgs.buildNpmPackage {
|
packages.bayshore = pkgs.buildNpmPackage {
|
||||||
pname = "bayshore";
|
pname = "bayshore";
|
||||||
version = "1.0.0";
|
version = "1.0.1";
|
||||||
src = ./.;
|
src = ./.;
|
||||||
npmDepsHash = "sha256-7iVoTJv5rvdiUWyhrDOGEboOo1sdQ7YvZOqbgvz/mF8=";
|
npmDepsHash = "sha256-7iVoTJv5rvdiUWyhrDOGEboOo1sdQ7YvZOqbgvz/mF8=";
|
||||||
|
|
||||||
@ -111,6 +111,8 @@
|
|||||||
|
|
||||||
preStart = ''
|
preStart = ''
|
||||||
export DATABASE_URL="${cfg.postgresUrl}"
|
export DATABASE_URL="${cfg.postgresUrl}"
|
||||||
|
export POSTGRES_URL="${cfg.postgresUrl}"
|
||||||
|
export BAYSHORE_NIX="true"
|
||||||
${pkg}/bin/prisma migrate deploy --schema=${pkg}/prisma/schema.prisma
|
${pkg}/bin/prisma migrate deploy --schema=${pkg}/prisma/schema.prisma
|
||||||
'';
|
'';
|
||||||
|
|
||||||
@ -122,6 +124,7 @@
|
|||||||
export DATABASE_URL="${cfg.postgresUrl}"
|
export DATABASE_URL="${cfg.postgresUrl}"
|
||||||
export POSTGRES_URL="${cfg.postgresUrl}"
|
export POSTGRES_URL="${cfg.postgresUrl}"
|
||||||
export BAYSHORE_CONFIG_PATH="${cfg.configFile}"
|
export BAYSHORE_CONFIG_PATH="${cfg.configFile}"
|
||||||
|
export BAYSHORE_NIX="true"
|
||||||
|
|
||||||
# The ports will always be on default
|
# The ports will always be on default
|
||||||
# because they're set through env-vars here.
|
# because they're set through env-vars here.
|
||||||
|
@ -3,7 +3,11 @@
|
|||||||
|
|
||||||
import process from 'process';
|
import process from 'process';
|
||||||
import * as dotenv from "dotenv";
|
import * as dotenv from "dotenv";
|
||||||
dotenv.config({path: __dirname + '/.env'});
|
|
||||||
|
if (!process.env.BAYSHORE_NIX)
|
||||||
|
{
|
||||||
|
dotenv.config({path: __dirname + '/.env'});
|
||||||
|
}
|
||||||
|
|
||||||
let tracing: any = {};
|
let tracing: any = {};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user