Skip to content

Commit

Permalink
HSC-250: Upgrade PostgreSQL image to 13 to support Ozone Analytics (#62)
Browse files Browse the repository at this point in the history
  • Loading branch information
enyachoke authored Apr 29, 2024
1 parent 3899ba9 commit bdfe590
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,8 @@ services:

# Postgreql: Database shared by multiple services
postgresql:
image: postgres:9.6-alpine
command: "postgres -c wal_level=logical -c max_wal_senders=10 -c max_replication_slots=10"
image: postgres:13-alpine
restart: unless-stopped
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
Expand Down
2 changes: 1 addition & 1 deletion sqls/postgresql/create_analytics_db.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ function create_user_and_database() {
local password=$3
echo " Creating '$user' user and '$database' database..."
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" $POSTGRES_DB <<-EOSQL
CREATE USER $user WITH UNENCRYPTED PASSWORD '$password';
CREATE USER $user WITH PASSWORD '$password';
CREATE DATABASE $database;
GRANT ALL PRIVILEGES ON DATABASE $database TO $user;
EOSQL
Expand Down
2 changes: 1 addition & 1 deletion sqls/postgresql/create_metabase_db.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ function create_user_and_database() {
local password=$3
echo " Creating '$user' user and '$database' database..."
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" $POSTGRES_DB <<-EOSQL
CREATE USER $user WITH UNENCRYPTED PASSWORD '$password';
CREATE USER $user WITH PASSWORD '$password';
CREATE DATABASE $database;
GRANT ALL PRIVILEGES ON DATABASE $database TO $user;
EOSQL
Expand Down
2 changes: 1 addition & 1 deletion sqls/postgresql/create_odoo_db.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ function create_user() {
local password=$2
echo " Creating '$user' user..."
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" $POSTGRES_DB <<-EOSQL
CREATE USER $user WITH UNENCRYPTED PASSWORD '$password';
CREATE USER $user WITH PASSWORD '$password';
ALTER USER $user CREATEDB;
EOSQL
}
Expand Down
2 changes: 1 addition & 1 deletion sqls/postgresql/create_openelis_db.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ function create_user_and_database() {
local password=$3
echo " Creating 'OpenELIS' user and database..."
psql -v ON_ERROR_STOP=1 --username postgres postgres <<-EOSQL
CREATE USER $user WITH UNENCRYPTED PASSWORD '$password';
CREATE USER $user WITH PASSWORD '$password';
CREATE DATABASE $database;
GRANT ALL PRIVILEGES ON DATABASE $database TO $user;
EOSQL
Expand Down

0 comments on commit bdfe590

Please sign in to comment.