Skip to content

Commit

Permalink
***
Browse files Browse the repository at this point in the history
  • Loading branch information
anatolicvs committed Aug 20, 2020
1 parent 6fd49b0 commit ecdf064
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
4 changes: 2 additions & 2 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ if [ "$MODE" == "prod" ]; then
sed -i -e "s,IP_ADDRESS,${LOGINSERVER}," ipconfig.txt
sed -i -e "s,DOMAIN$,${DOMAIN}," ipconfig.txt
else
sed -i -e "s/IP_ADDRESS$/0.0.0.0/" ipconfig.txt
sed -i -e "s/DOMAIN$/0.0.0.0/" ipconfig.txt
sed -i -e "s/IP_ADDRESS/0.0.0.0/" ipconfig.txt
sed -i -e "s/DOMAIN/0.0.0.0/" ipconfig.txt
fi

export IN_SYLVA_KEYCLOAK_HOST=$(grep IN_SYLVA_KEYCLOAK_HOST ipconfig.txt| awk '{print $2}')
Expand Down
13 changes: 11 additions & 2 deletions data.sql
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,17 @@ CREATE TABLE IF NOT EXISTS policies (
id serial PRIMARY KEY,
name varchar(50) NOT NULL,
source_id integer,
is_default boolean default false,
user_id integer,

CONSTRAINT policy_user_id_fkey FOREIGN KEY (user_id)
REFERENCES users(id) MATCH SIMPLE
ON UPDATE NO ACTION ON DELETE NO ACTION,

CONSTRAINT policy_source_id_fkey FOREIGN KEY (source_id)
REFERENCES sources(id) MATCH SIMPLE
ON UPDATE NO ACTION ON DELETE NO ACTION,

is_default boolean default false,
createdAt timestamp NOT NULL DEFAULT NOW(),
updatedAt timestamp
);
Expand All @@ -94,8 +99,12 @@ CREATE TABLE IF NOT EXISTS policy_fields(

CREATE TABLE IF NOT EXISTS groups (
id serial PRIMARY KEY,

name varchar(50) NOT NULL,
user_id integer,

CONSTRAINT groups_user_id_fkey FOREIGN KEY (user_id)
REFERENCES users(id) MATCH SIMPLE
ON UPDATE NO ACTION ON DELETE NO ACTION,

createdAt timestamp NOT NULL DEFAULT NOW(),
updatedAt timestamp
Expand Down

0 comments on commit ecdf064

Please sign in to comment.