generated from ministryofjustice/template-repository
-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DACP: Delete db migration scripts, add dummy data instead (#3767)
- Loading branch information
1 parent
80d8607
commit fd5261e
Showing
9 changed files
with
1,798 additions
and
126 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
provider "aws" { | ||
region = "eu-west-2" | ||
access_key = jsondecode(data.aws_secretsmanager_secret_version.get_tactical_products_rds_credentials.secret_string)["ACCESS_KEY"] | ||
secret_key = jsondecode(data.aws_secretsmanager_secret_version.get_tactical_products_rds_credentials.secret_string)["SECRET_KEY"] | ||
# access_key = jsondecode(data.aws_secretsmanager_secret_version.get_tactical_products_rds_credentials.secret_string)["ACCESS_KEY"] | ||
# secret_key = jsondecode(data.aws_secretsmanager_secret_version.get_tactical_products_rds_credentials.secret_string)["SECRET_KEY"] | ||
alias = "tacticalproducts" | ||
} |
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
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,12 @@ | ||
#!/bin/bash | ||
|
||
export PGPASSWORD=$DACP_DB_PASSWORD; | ||
# if database contains schema dbo then store schema name inside variable. | ||
SCHEMA=$(psql -h ${DB_HOSTNAME} -p 5432 -U $DACP_DB_USERNAME -d $DB_NAME -c "SELECT schema_name FROM information_schema.schemata WHERE schema_name = 'dbo'" | grep -o 'dbo') | ||
echo "Schema = $SCHEMA" | ||
|
||
if [ "$SCHEMA" == "dbo" ]; then | ||
echo "The Schema dbo is already present in the database" | ||
else | ||
psql -h ${DB_HOSTNAME} -p 5432 -U $DACP_DB_USERNAME -d $DB_NAME -c "\i dacp_dummydata.sql;"; | ||
fi |
12 changes: 0 additions & 12 deletions
12
terraform/environments/dacp/setup-security-group-development.sh
This file was deleted.
Oops, something went wrong.
12 changes: 0 additions & 12 deletions
12
terraform/environments/dacp/setup-security-group-preproduction.sh
This file was deleted.
Oops, something went wrong.
12 changes: 0 additions & 12 deletions
12
terraform/environments/dacp/setup-security-group-production.sh
This file was deleted.
Oops, something went wrong.