Skip to content

Commit

Permalink
Trying to fix caching issue
Browse files Browse the repository at this point in the history
Explicitly calling image to test
Restructuring the service startup to be separate from tests
  • Loading branch information
constantinius committed Apr 27, 2023
1 parent e7a5988 commit 5b9f03d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ jobs:
- uses: actions/checkout@v3
- name: Build the eoxserver docker image
run: |
docker pull eoxa/eoxserver:latest || true
docker build --cache-from eoxa/eoxserver:latest -t eoxserver .
docker save eoxserver | gzip > eoxserver.tar.gz
- uses: actions/upload-artifact@v3
Expand Down Expand Up @@ -59,16 +60,18 @@ jobs:
- name: Import docker image and name it autotest
run: |
docker load --input eoxserver.tar.gz
docker tag eoxserver autotest
- name: Run the tests
env:
COMPOSE_INTERACTIVE_NO_CLI: 1
docker tag eoxserver:latest eoxserver:autotest
- name: Start the services and install test dependencies
run: |
echo "DB=spatialite" >> sample.env
docker-compose config
docker-compose up -d
docker-compose ps
docker exec -i eoxserver_autotest_1 pip3 install scipy
- name: Run the tests
env:
COMPOSE_INTERACTIVE_NO_CLI: 1
run: |
docker exec -i eoxserver_autotest_1 python3 ${{ matrix.command }}
- name: Upload logs and outputs of failed tests
uses: 'actions/upload-artifact@v2'
Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ services:
POSTGRES_DB: "dbms"

autotest:
image: eoxserver:autotest
build: .
env_file:
- ./sample.env
Expand Down

0 comments on commit 5b9f03d

Please sign in to comment.