-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove references to the old datagov-deploy repo #1143
base: main
Are you sure you want to change the base?
Conversation
This reverts commit f67cd55.
For some reason also a linting of that JS file. Also, included the sql file remove/revert on purpose if we want to go that route in the future.
@@ -9,5 +9,5 @@ ARG DATASTORE_READONLY_PASSWORD | |||
|
|||
# Include extra setup scripts (eg datastore) | |||
ADD docker-entrypoint-initdb.d /docker-entrypoint-initdb.d | |||
ADD https://github.com/GSA/datagov-deploy/raw/71936f004be1882a506362670b82c710c64ef796/ansible/roles/software/ec2/ansible/files/locations.sql.gz /docker-entrypoint-initdb.d/locations.sql.gz |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of updating this link, I think referencing a key piece of DB setup (for dev and prod) at a historical git commit to a file that is no longer being tracked isn't good practice. Can we just add the file in the repo similar to the other files in docker-entrypoint-initdb.d folder?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 to that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for rewiring up the links. It would be equally valuable to delete/update outdated instructions.
@@ -9,5 +9,5 @@ ARG DATASTORE_READONLY_PASSWORD | |||
|
|||
# Include extra setup scripts (eg datastore) | |||
ADD docker-entrypoint-initdb.d /docker-entrypoint-initdb.d | |||
ADD https://github.com/GSA/datagov-deploy/raw/71936f004be1882a506362670b82c710c64ef796/ansible/roles/software/ec2/ansible/files/locations.sql.gz /docker-entrypoint-initdb.d/locations.sql.gz |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 to that
The locations table [was defined in 2016](https://github.com/GSA/datagov-deploy/search?q=location+table&type=commits). | ||
This table was deleted from the repo but is still available from old commits: [locations.sql.gz](https://github.com/GSA/datagov-deploy/raw/71936f004be1882a506362670b82c710c64ef796/ansible/roles/software/ec2/ansible/files/locations.sql.gz). | ||
The locations table [was defined in 2016](https://github.com/GSA/data.gov/search?q=location+table&type=commits). | ||
This table was deleted from the repo but is still available from old commits: [locations.sql.gz](https://github.com/GSA/data.gov/raw/71936f004be1882a506362670b82c710c64ef796/ansible/roles/software/ec2/ansible/files/locations.sql.gz). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is outdated now that the table is in the docker-entrypoint dir.
echo "*** USAGE: $(basename "$0") HOST DB_NAME DB_USER PASS" | ||
|
||
DEST_FOLDER=/tmp | ||
# TODO check path on run | ||
SQL_FILE=30_locations.sql.gz |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i'm almost positive the pathing needs to be adjusted
gunzip -c ${SQL_FILE} | PGPASSWORD=${PASS} psql -h "$HOST" -U "$DB_USER" -d "$DB_NAME" -v ON_ERROR_STOP=1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
my understanding was putting the .gzipped file in the docker-entrypoint dir executes it automatically when catalog starts up... is that correct?
and if so, what does this script here do?
What do we need to do to get this merged @robert-bryson? |
@Bagesary here's another one to discuss with @robert-bryson |
@jbrown-xentity could you please talk to Robert on Monday on this ticket? |
As the
datagov-deploy
repo has been removed, all references are now redirected todata.gov
. We should probably just have them point todata.gov
instead of relying on the301
->302
chain that currently happens.This surfaced for me as I was having an issue pulling down the file
postgres/locations.sql.gz
in the postgres Dockerfile. Not sure why only my system was impacted by this, but probably a good fix in any case.