From a4e1c830937e5dbda11c219ee7d6ee6eb6728b84 Mon Sep 17 00:00:00 2001 From: Fran Slot Date: Tue, 28 Nov 2023 15:15:15 +0100 Subject: [PATCH 1/2] #333 Changed path --- .github/workflows/RAP.yml | 7 ++++--- .github/workflows/RAPUsers.yml | 4 ++-- RAP4/Dockerfile | 1 - 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/RAP.yml b/.github/workflows/RAP.yml index 0d63e084..4f949c83 100644 --- a/.github/workflows/RAP.yml +++ b/.github/workflows/RAP.yml @@ -3,13 +3,14 @@ name: RAP pipeline on: push: branches: - - "main" + - main + - "feature/**" paths: - - "./RAP4/" + - "RAP4/**" jobs: Staging: - if: github.ref_name == 'main' + # if: github.ref_name == 'main' uses: ./.github/workflows/Deploy_workflow.yml with: environmentName: staging diff --git a/.github/workflows/RAPUsers.yml b/.github/workflows/RAPUsers.yml index 74ddac72..953bf2ff 100644 --- a/.github/workflows/RAPUsers.yml +++ b/.github/workflows/RAPUsers.yml @@ -3,9 +3,9 @@ name: RAP User pipeline on: push: branches: - - "main" + - main paths: - - "./RAP4USER/" + - "RAP4USER/**" jobs: Staging: diff --git a/RAP4/Dockerfile b/RAP4/Dockerfile index eccfecf9..206a7e0b 100644 --- a/RAP4/Dockerfile +++ b/RAP4/Dockerfile @@ -49,7 +49,6 @@ COPY customizations /var/www/ RUN chown -R www-data:www-data /var/www/data /var/www/generics RUN composer install --prefer-dist --no-dev --profile --optimize-autoloader RUN npm update -#RUN npm audit fix RUN npm install RUN gulp build-ampersand RUN gulp build-project From 1ec13249d5b52c26aea0600c1c12608c95990007 Mon Sep 17 00:00:00 2001 From: Fran Slot Date: Tue, 28 Nov 2023 15:18:33 +0100 Subject: [PATCH 2/2] #333 Clean up read me to trigger run --- .github/workflows/RAP.yml | 3 +-- RAP4USER/README.md | 11 +++++++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/.github/workflows/RAP.yml b/.github/workflows/RAP.yml index 4f949c83..95116017 100644 --- a/.github/workflows/RAP.yml +++ b/.github/workflows/RAP.yml @@ -4,13 +4,12 @@ on: push: branches: - main - - "feature/**" paths: - "RAP4/**" jobs: Staging: - # if: github.ref_name == 'main' + if: github.ref_name == 'main' uses: ./.github/workflows/Deploy_workflow.yml with: environmentName: staging diff --git a/RAP4USER/README.md b/RAP4USER/README.md index 49093a31..c9d08d9e 100644 --- a/RAP4USER/README.md +++ b/RAP4USER/README.md @@ -1,22 +1,29 @@ ## Build rap4-student-prototype image + > `docker build -t ampersandtarski/rap4-student-prototype: .` ## Opstarten container using rap4-student-prototype + NOTE! Backticks need to be escaped when used in windows powershell. Therefore double backticks `` are used in command argument below. A single backtick is needed in the Host() argument. -``` + +```txt cat test.adl | docker run --name student123 --rm -i -a stdin --network proxy -e AMPERSAND_DBHOST=db -e AMPERSAND_DBNAME=student123 -l traefik.enable=true -l traefik.http.routers.student123-insecure.rule="Host(``student123.rap.cs.ou.nl``) || Host(``student123.localhost``)" -l student-prototype rap4-student-prototype ``` + Also run the following command to attach the new container to the database network. Unfortunately we cannot attach to two networks in docker run command at the same time. -``` + +```txt docker network connect rap_db student123 ``` ## Stop container for specific student + If no container exists with name=student123, docker gives an error. This is not a problem. Just ignore. > `docker container stop $(docker container ls -q --filter name=student123)` or > `docker rm -f student123` ## Stop student prototype containers + > `docker container stop $(docker container ls -q --filter label=student-prototype)` \ No newline at end of file