From a3ea9cb840bc8dbc9e5e0940ec72a36712e13a2a Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Tue, 11 May 2021 10:47:51 +0300 Subject: workflows: main.yml: Update container image --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a36abc0a..64c0fdb2 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -11,7 +11,7 @@ on: jobs: unittest: runs-on: ubuntu-latest - container: bonfacekilz/python3-genenetwork2:ad741c1 + container: bonfacekilz/python3-genenetwork2:00ba1f8 steps: # First start with mariadb set then checkout. The checkout gives -- cgit v1.2.3 From 5e3e8e5847fe994652e3c6675ce96312fd9dc16a Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Tue, 11 May 2021 11:09:36 +0300 Subject: workflows: main.yml: Remove hard-coded path --- .github/workflows/main.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 64c0fdb2..2b7c3b16 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -57,10 +57,10 @@ jobs: - name: Test for Broken Links run: | - env GN2_PROFILE=/gn2-profile \ TMPDIR=/tmp\ WEBSERVER_MODE=DEBUG LOG_LEVEL=DEBUG \ GENENETWORK_FILES=/genotype_files/ bin/genenetwork2 \ - etc/default_settings.py -c /__w/genenetwork2/genenetwork2/test/requests/links_scraper/genelinks.py + etc/default_settings.py -c \ + $PWD/test/requests/links_scraper/genelinks.py -- cgit v1.2.3 From 232148b1304ae531df6d9157f6d574d5c944830e Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Tue, 11 May 2021 11:30:53 +0300 Subject: workflows: main.yml: Use screen to run gn2 --- .github/workflows/main.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2b7c3b16..f9a3fa13 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -49,11 +49,11 @@ jobs: - name: Start Genenetwork as a Background Task run: | - env GN2_PROFILE=/gn2-profile \ + /gn2-profile/bin/screen -dmL bash -c "env GN2_PROFILE=/gn2-profile \ TMPDIR=/tmp SERVER_PORT=5004 \ WEBSERVER_MODE=DEBUG LOG_LEVEL=DEBUG \ GENENETWORK_FILES=/genotype_files/ bin/genenetwork2 \ - etc/default_settings.py& + etc/default_settings.py" - name: Test for Broken Links run: | -- cgit v1.2.3 From 4538c0ad693ae94ebda5f0bf39678d776c0c8297 Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Tue, 11 May 2021 11:47:20 +0300 Subject: workflows: main.yml: Set up gn2 before running the unit tests --- .github/workflows/main.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f9a3fa13..b09f2f1d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -39,21 +39,21 @@ jobs: mysql -u root -e "CREATE USER 'gn2'@'localhost' IDENTIFIED BY 'mysql_password';" mysql -u root -e "GRANT ALL PRIVILEGES ON *.* TO 'gn2'@'localhost';FLUSH PRIVILEGES;" - - name: Run the unit tests + - name: Start Genenetwork as a Background Task run: | - env GN2_PROFILE=/gn2-profile \ + /gn2-profile/bin/screen -dmL bash -c "env GN2_PROFILE=/gn2-profile \ TMPDIR=/tmp SERVER_PORT=5004 \ WEBSERVER_MODE=DEBUG LOG_LEVEL=DEBUG \ GENENETWORK_FILES=/genotype_files/ bin/genenetwork2 \ - etc/default_settings.py -c -m unittest discover -v + etc/default_settings.py" - - name: Start Genenetwork as a Background Task + - name: Run the unit tests run: | - /gn2-profile/bin/screen -dmL bash -c "env GN2_PROFILE=/gn2-profile \ + env GN2_PROFILE=/gn2-profile \ TMPDIR=/tmp SERVER_PORT=5004 \ WEBSERVER_MODE=DEBUG LOG_LEVEL=DEBUG \ GENENETWORK_FILES=/genotype_files/ bin/genenetwork2 \ - etc/default_settings.py" + etc/default_settings.py -c -m unittest discover -v - name: Test for Broken Links run: | -- cgit v1.2.3 From 75b378f757979af1d6fdaff3f3abde0599c5f744 Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Tue, 11 May 2021 12:10:37 +0300 Subject: workflows: main.yml: Use mariadb as a service --- .github/workflows/main.yml | 30 +++++++++++++----------------- 1 file changed, 13 insertions(+), 17 deletions(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b09f2f1d..a2925e08 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -12,16 +12,19 @@ jobs: unittest: runs-on: ubuntu-latest container: bonfacekilz/python3-genenetwork2:00ba1f8 + services: + mysql: + image: mariadb:15.1 + env: + MYSQL_ALLOW_EMPTY_PASSWORD: yes + MYSQL_USER: gn2 + MYSQL_PASSWORD: mysql_password + MYSQL_DATABASE: db_webqtl_s + ports: + - 3306:3306 + options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 steps: - # First start with mariadb set then checkout. The checkout gives - # the mysqld enough time to start - - name: Set up mariadb - run: | - mysql_install_db --user=mysql --datadir=/usr/local/mysql - # Wait for the mysqld_safe process to start - mysqld_safe --user=mysql --datadir=/usr/local/mysql & - # Use v1 of checkout since v2 fails - name: Checkout Project uses: actions/checkout@v1 @@ -31,17 +34,10 @@ jobs: run: | /gn2-profile/bin/screen -dmLS redisconn /gn2-profile/bin/redis-server - # Redis is required by some of the tests 6379 - - name: Bootstrap tables - run: | - mysql -u root -e "SHOW DATABASES;" - mysql -u root -e "CREATE DATABASE db_webqtl_s;" - mysql -u root -e "CREATE USER 'gn2'@'localhost' IDENTIFIED BY 'mysql_password';" - mysql -u root -e "GRANT ALL PRIVILEGES ON *.* TO 'gn2'@'localhost';FLUSH PRIVILEGES;" - - name: Start Genenetwork as a Background Task run: | - /gn2-profile/bin/screen -dmL bash -c "env GN2_PROFILE=/gn2-profile \ + /gn2-profile/bin/screen -dmLS gn2conn + bash -c "env GN2_PROFILE=/gn2-profile \ TMPDIR=/tmp SERVER_PORT=5004 \ WEBSERVER_MODE=DEBUG LOG_LEVEL=DEBUG \ GENENETWORK_FILES=/genotype_files/ bin/genenetwork2 \ -- cgit v1.2.3 From c4ec08c1b544c05cce1c1247b8bc1afb741643e4 Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Tue, 11 May 2021 13:38:47 +0300 Subject: workflows: main.yml: Remove mysql service and update gn2 b/g task --- .github/workflows/main.yml | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a2925e08..c6b56a81 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -12,19 +12,16 @@ jobs: unittest: runs-on: ubuntu-latest container: bonfacekilz/python3-genenetwork2:00ba1f8 - services: - mysql: - image: mariadb:15.1 - env: - MYSQL_ALLOW_EMPTY_PASSWORD: yes - MYSQL_USER: gn2 - MYSQL_PASSWORD: mysql_password - MYSQL_DATABASE: db_webqtl_s - ports: - - 3306:3306 - options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 steps: + # First start with mariadb set then checkout. The checkout gives + # the mysqld enough time to start + - name: Set up mariadb + run: | + mysql_install_db --user=mysql --datadir=/usr/local/mysql + # Wait for the mysqld_safe process to start + mysqld_safe --user=mysql --datadir=/usr/local/mysql & + # Use v1 of checkout since v2 fails - name: Checkout Project uses: actions/checkout@v1 @@ -34,10 +31,17 @@ jobs: run: | /gn2-profile/bin/screen -dmLS redisconn /gn2-profile/bin/redis-server + # Initialise the tables + - name: Bootstrap tables + run: | + mysql -u root -e "SHOW DATABASES;" + mysql -u root -e "CREATE DATABASE db_webqtl_s;" + mysql -u root -e "CREATE USER 'gn2'@'localhost' IDENTIFIED BY 'mysql_password';" + mysql -u root -e "GRANT ALL PRIVILEGES ON *.* TO 'gn2'@'localhost';FLUSH PRIVILEGES;" + - name: Start Genenetwork as a Background Task run: | - /gn2-profile/bin/screen -dmLS gn2conn - bash -c "env GN2_PROFILE=/gn2-profile \ + /gn2-profile/bin/screen -dm bash -c "env GN2_PROFILE=/gn2-profile \ TMPDIR=/tmp SERVER_PORT=5004 \ WEBSERVER_MODE=DEBUG LOG_LEVEL=DEBUG \ GENENETWORK_FILES=/genotype_files/ bin/genenetwork2 \ @@ -59,4 +63,3 @@ jobs: GENENETWORK_FILES=/genotype_files/ bin/genenetwork2 \ etc/default_settings.py -c \ $PWD/test/requests/links_scraper/genelinks.py - -- cgit v1.2.3 From 43d4e9b42f9ebcb9012bc791aa4ac34a15f290a7 Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Wed, 26 May 2021 18:31:40 +0300 Subject: workflows: main: Use "bonfacekilz/genenetwork2:latest" docker image --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c6b56a81..f279a7e5 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -11,7 +11,7 @@ on: jobs: unittest: runs-on: ubuntu-latest - container: bonfacekilz/python3-genenetwork2:00ba1f8 + container: bonfacekilz/genenetwork2:latest steps: # First start with mariadb set then checkout. The checkout gives -- cgit v1.2.3