-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#67 adapt compose dev to get image from github and quay
- Loading branch information
1 parent
19e1064
commit db3d84a
Showing
2 changed files
with
22 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
|
||
# Initialize the database | ||
echo "Initializing the database..." | ||
|
||
# Define password for user | ||
psql -U postgres -c "ALTER USER $POSTGRESQL_USER WITH PASSWORD '$POSTGRESQL_PASSWORD';" | ||
# Give all privileges to the user on the database | ||
psql -U postgres -c "GRANT ALL PRIVILEGES ON DATABASE $POSTGRESQL_DATABASE TO $POSTGRESQL_USER;" | ||
# Initialize the database | ||
psql -U $POSTGRESQL_USER -d $POSTGRESQL_DATABASE -f /usr/share/container-scripts/postgresql/start/init.sql | ||
|
||
echo "Database initialization complete." |