Skip to content

Commit

Permalink
Updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
Ubuntu committed Jan 13, 2025
1 parent acbc703 commit c5b3543
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ORCID middleware to enable our researchers to designate GW as a trusted partner
- If using SSL, see the additional instructions below for configuring the Nginx Docker container.
- If not using SSL, comment out the volume mapping in the `docker-compose.yml` file under the `nginx-proxy` service.
6. Bring up the Docker container(s): `docker-compose up -d`. This will install all necessary dependencies and launch the Flask app with gunicorn on port `8080`, and it will start an Nginx server to proxy port `8080` to `80`/`443`.
- For development, comment out the first three lines under the `volumes` section of the `flask-app` service and uncomment the line `.:/opt/orcid_integration`. This will use the local copy of the Python code.
- For development, comment out the first three lines under the `volumes` section of the `flask-app` service and uncomment the line `.:/opt/orcid-integration`. This will use the local copy of the Python code.
6. When the Flask app starts up, it will check for the presence of a database encryption key file (as specified in `example.env`). If the file is not present, it will create a new database encryption key. **Be careful with this key.** Once the data has been encrypted using it, the key is necessary to decrypt the data again. Loss of the key means loss of the data.
7. The postgres container will store data outside of the container, in the `./data` directory.
- When first run, postgres will set the permissions on this directory to a system user.
Expand All @@ -40,7 +40,9 @@ ORCID middleware to enable our researchers to designate GW as a trusted partner
### Serializing the database
To quickly serialize the database as a JSON file, you can run the following command (if outside the container), providing the path to a file in a mounted volume:
To quickly serialize the database as a JSON file, you can run the following commands (if outside the container):
```
docker exec -it orcid-integration_flask-app_1 flask serialize-db ./data/token-dump.json
docker exec -it orcid-integration-flask-app-1 flask serialize-db /tmp/token-dump.json
docker cp orcid-integration-flask-app-1:/tmp/token-dump.json ./
```

0 comments on commit c5b3543

Please sign in to comment.