Skip to content
Snippets Groups Projects
Commit 656bd496 authored by Alexander König's avatar Alexander König
Browse files

utils db was not picking up the correct user for its tables. This is now

fixed.
parent 2f64d5cf
No related branches found
No related tags found
No related merge requests found
......@@ -3,6 +3,7 @@
git clone https://github.com/commul/clarin-dspace.git -b commul-custom /tmp/dspace
cp /tmp/dspace/utilities/utilities.sql /tmp/sql/
cp /tmp/dspace/utilities/license_definition.txt /tmp/sql/
chmod -R a+w /tmp/sql/
perl -pi -e "s#afile :utildir '/license_definition.txt'#afile '/tmp/sql/license_definition.txt'#;" /tmp/sql/utilities.sql
#perl -pi -e 's/\$DSPACE_USER/$ENV{DSPACE_USER}/g;' /tmp/sql/utilities.sql
rm -rf /tmp/dspace
......@@ -12,13 +12,3 @@ psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" <<-EOSQL
EOSQL
psql --username "$POSTGRES_USER" --set=utildir="/tmp/sql/" -p 5432 $DSPACE_UTILSDBNAME < /tmp/sql/utilities.sql
# this is a better version using kubernetes environment variables
##!/bin/bash
#set -xe
#
#psql --username "$POSTGRES_USER" -c "CREATE USER $dspaceuser WITH PASSWORD '$dspacepassword'";
#psql --username "$POSTGRES_USER" -c "CREATE DATABASE "$dspacedbname" OWNER $dspaceuser ENCODING \"UTF-8\" TEMPLATE template0;"
#psql --username "$POSTGRES_USER" -c "CREATE DATABASE "$dspaceutilsdbname" OWNER $dspaceuser ENCODING \"UTF-8\" TEMPLATE template0;"
#
#psql --username "$POSTGRES_USER" --set=utildir="/tmp/sql/" -p 5432 $secretdspaceutilsdbname < /tmp/sql/utilities.sql
......@@ -50,7 +50,7 @@ spec:
secretKeyRef:
key: mail.pass
name: dspace-secrets
image: gitlab.scientificnet.org:4567/commul/dspace/dspace-image:1.1.3
image: gitlab.scientificnet.org:4567/commul/dspace/dspace-image:1.1.7
name: clarin-dspace
imagePullPolicy: Always
ports:
......
......@@ -20,7 +20,7 @@ spec:
io.kompose.service: nginx
spec:
containers:
- image: gitlab.scientificnet.org:4567/commul/dspace/nginx-image:1.1.3
- image: gitlab.scientificnet.org:4567/commul/dspace/nginx-image:1.1.7
imagePullPolicy: Always
name: clarin-nginx
ports:
......
......@@ -48,7 +48,7 @@ spec:
secretKeyRef:
key: dspace.utils.name
name: dspace-secrets
image: gitlab.scientificnet.org:4567/commul/dspace/postgres-image:1.1.3
image: gitlab.scientificnet.org:4567/commul/dspace/postgres-image:1.1.7
imagePullPolicy: Always
name: clarin-postgres
resources: {}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment