Skip to content

Commit e1b1e49

Browse files
committed
update doc on how to run ezid in docker
1 parent bbe22ac commit e1b1e49

1 file changed

Lines changed: 8 additions & 3 deletions

File tree

how_to_run_ezid_in_docker.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,15 @@ It defines and manages multiple Docker containers (services) in one file.
1616

1717
**The .env file***
1818
The `.env` file is located in the root directory of the `EZID-OPS-SCRIPTS` repo.
19-
It stores environment variables, which can be used in both docker-compose.yml and Dockerfiles.
19+
It stores environment variables, which can be used in both `docker-compose.yml` and `Dockerfile`.
2020

2121
**Services defined in the `docker-compose.yml` file**
2222
* selenium - a standalone-chromium
2323
* test-runner-ui - a sesrvice runs the `ezid_ui_tests_docker.py` script
2424
* test-runner-ezid-status- a service runs the `verify_ezid_status.py` script
2525

26+
Note: the `docker-compose.yml` was updated later with a single container combining both the UI and EZID status tests.
27+
2628
## Docker compose commands
2729

2830
Remove existing container by name:
@@ -75,7 +77,6 @@ Run the test script
7577
python ezid_ui_tests_docker.py -e stg -u apitest -p apitest_password -n ezid_test_email@ucop.edu
7678
```
7779

78-
7980
## Precedence Order for environment variables in Docker Compose
8081

8182
When using Docker Compose, environment variables can be set in various ways. The precedence order for these variables is as follows:
@@ -87,7 +88,7 @@ When using Docker Compose, environment variables can be set in various ways. The
8788
|4 | Hardcoded in docker-compose.yml | MY_SECRET_TOKEN: fallback_value |
8889

8990
## Run EZID tests using GitHub action
90-
A GitHub action `Run EZID UI and functional tests in Docker` is defined in the `.github/workflow/ezid-tests.yml` file. The action is triggered by content changes to the `.env` file. It runs the `docker compose up --build` command to build the images, start the containers and then run the tests defined in the test scripts.
91+
A GitHub action `Run EZID UI and functional tests in Docker` is defined in the `.github/workflow/ezid-tests.yml` file. The action is triggered by content changes to the `.env` file. It runs the `docker compose up --build` command to build the images, start the containers and then run the test suites.
9192

9293
Sample `.github/workflow/ezid-tests.yml`:
9394
```
@@ -164,3 +165,7 @@ Pass the API password in command line:
164165
```
165166
APITEST_PASSWORD=xxx docker compose up --build
166167
```
168+
169+
4. To run the script through GitHub action
170+
171+
Update the `.env` file then push the changes to GitHub. This will trigger a GitHub action to run the tests.

0 commit comments

Comments
 (0)