From c6f4c17339cb0ca9e3459b76e68ec9174f5048e6 Mon Sep 17 00:00:00 2001 From: Joel Davies Date: Mon, 15 Apr 2024 15:07:51 +0000 Subject: [PATCH] Test #499 --- .github/workflows/ci-build.yml | 40 +++++++++++++++------------------- 1 file changed, 18 insertions(+), 22 deletions(-) diff --git a/.github/workflows/ci-build.yml b/.github/workflows/ci-build.yml index 3e4205b47..3c6dd6257 100644 --- a/.github/workflows/ci-build.yml +++ b/.github/workflows/ci-build.yml @@ -72,28 +72,6 @@ jobs: name: End-to-End (with api) Tests runs-on: ubuntu-latest - services: - ims-api: - image: harbor.stfc.ac.uk/inventory-management-system/ims-api:develop - ports: - - 8000:8000 - env: - AUTHENTICATION__ENABLED: false - API__TITLE: Inventory Management System API - API__DESCRIPTION: This is the API for the Inventory Management System - API__ROOT_PATH: /inventory-management-system-api - DATABASE__PROTOCOL: mongodb - DATABASE__USERNAME: root - DATABASE__PASSWORD: example - DATABASE__HOSTNAME: mongodb - DATABASE__PORT: 27017 - DATABASE__NAME: ims - API__ALLOWED_CORS_HEADERS: '["*"]' - API__ALLOWED_CORS_ORIGINS: '["*"]' - API__ALLOWED_CORS_METHODS: '["*"]' - - options: --name inventory-management-system-api - steps: - name: Clone api repo uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 @@ -125,6 +103,24 @@ jobs: python ./scripts/dev_cli.py db-init --replicaSetMemberHost localhost python ./scripts/dev_cli.py db-import + - name: Start inventory-management-system-api + run: | + docker run -p 8000:8000 --name inventory_management_system_api \ + --env AUTHENTICATION__ENABLED=false \ + --env API__TITLE="Inventory Management System API" \ + --env API__DESCRIPTION="This is the API for the Inventory Management System" \ + --env API__ROOT_PATH="/inventory-management-system-api" \ + --env DATABASE__PROTOCOL="mongodb" \ + --env DATABASE__USERNAME="root" \ + --env DATABASE__PASSWORD="example" \ + --env DATABASE__HOSTNAME="mongodb" \ + --env DATABASE__PORT=27017 \ + --env DATABASE__NAME="ims" \ + --env API__ALLOWED_CORS_HEADERS='["*"]' \ + --env API__ALLOWED_CORS_ORIGINS='["*"]' \ + --env API__ALLOWED_CORS_METHODS='["*"]' \ + harbor.stfc.ac.uk/inventory-management-system/ims-api:develop + - name: Checkout repo uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4