From 187811f87924a0b3b15c32b3dd1fa8ee2c1c6d46 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 14:03:05 +0100 Subject: [PATCH 1/8] build community server build login server removed old gradido node push workflow(not working) --- .github/workflows/push.yml | 18 ------ .github/workflows/test.yml | 114 ++++++++++++++++++++++--------------- 2 files changed, 67 insertions(+), 65 deletions(-) delete mode 100644 .github/workflows/push.yml diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml deleted file mode 100644 index 2e5bf99ab..000000000 --- a/.github/workflows/push.yml +++ /dev/null @@ -1,18 +0,0 @@ -name: on-push -on: push -jobs: - test: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Build the stack - run: | - git submodule update --init --recursive - docker-compose up -d - - name: Test - env: - GN_INSTANCE_FOLDER: /tmp/gradio-node-instance - GN_CONTAINER_NAME: gradido-node-build - run: docker run gradido-node-test - timeout-minutes: 2 - diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e8dfbab4e..8879a34bb 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -4,34 +4,13 @@ name: gradido test CI on: [push] jobs: - ############################################################################## - # JOB: PREPARE ##################################################### - ############################################################################## - #prepare: - # name: Prepare - # runs-on: ubuntu-latest - # # needs: [nothing] - # steps: - # ########################################################################## - # # CHECKOUT CODE ########################################################## - # ########################################################################## - # - name: Checkout code - # uses: actions/checkout@v2 - # ########################################################################## - # # TODO: DO STUFF ??? ##################################################### - # ########################################################################## - # - name: Check translation files - # run: | - # scripts/translations/sort.sh - # scripts/translations/missing-keys.sh - ############################################################################## # JOB: DOCKER BUILD TEST FRONTEND ############################################ ############################################################################## build_test_frontend: name: Docker Build Test - Frontend runs-on: ubuntu-latest - #needs: [nothing] # [prepare] + #needs: [nothing] steps: ########################################################################## # CHECKOUT CODE ########################################################## @@ -39,7 +18,7 @@ jobs: - name: Checkout code uses: actions/checkout@v2 ########################################################################## - # NEO4J ################################################################## + # FRONTEND ############################################################### ########################################################################## - name: Frontend | Build `test` image run: | @@ -78,30 +57,56 @@ jobs: # path: /tmp/backend.tar ############################################################################## - # JOB: DOCKER BUILD TEST WEBAPP ############################################## + # JOB: DOCKER BUILD TEST LOGIN SERVER ######################################## ############################################################################## - #build_test_webapp: - # name: Docker Build Test - WebApp - # runs-on: ubuntu-latest - # needs: [prepare] - # steps: - # ########################################################################## - # # CHECKOUT CODE ########################################################## - # ########################################################################## - # - name: Checkout code - # uses: actions/checkout@v2 - # ########################################################################## - # # BUILD WEBAPP DOCKER IMAGE (build) ###################################### - # ########################################################################## - # - name: webapp | Build `test` image - # run: | - # docker build --target test -t "ocelotsocialnetwork/webapp:test" webapp/ - # docker save "ocelotsocialnetwork/webapp:test" > /tmp/webapp.tar - # - name: Upload Artifact - # uses: actions/upload-artifact@v2 - # with: - # name: docker-webapp-test - # path: /tmp/webapp.tar + build_test_login_server: + name: Docker Build Test - Login Server + runs-on: ubuntu-latest + #needs: [nothing] + steps: + ########################################################################## + # CHECKOUT CODE ########################################################## + ########################################################################## + - name: Checkout code + uses: actions/checkout@v2 + ########################################################################## + # BUILD LOGIN SERVER DOCKER IMAGE (build) ################################ + ########################################################################## + - name: login server | Build `test` image + run: | + docker build --target login_server_debug -t "gradido/loginserver:test" login_server/Dockerfile.debug + docker save "gradido/loginserver:test" > /tmp/loginserver.tar + - name: Upload Artifact + uses: actions/upload-artifact@v2 + with: + name: docker-loginserver-test + path: /tmp/loginserver.tar + + ############################################################################## + # JOB: DOCKER BUILD TEST COMMUNITY SERVER #################################### + ############################################################################## + build_test_community_server: + name: Docker Build Test - Community Server + runs-on: ubuntu-latest + #needs: [nothing] + steps: + ########################################################################## + # CHECKOUT CODE ########################################################## + ########################################################################## + - name: Checkout code + uses: actions/checkout@v2 + ########################################################################## + # BUILD COMMUNITY SERVER DOCKER IMAGE (build) ############################ + ########################################################################## + - name: community server | Build `test` image + run: | + docker build -t "gradido/communityserver:test" community_server/ + docker save "gradido/communityserver:test" > /tmp/communityserver.tar + - name: Upload Artifact + uses: actions/upload-artifact@v2 + with: + name: docker-communityserver-test + path: /tmp/communityserver.tar ############################################################################## # JOB: LINT FRONTEND ######################################################### @@ -241,4 +246,19 @@ jobs: # run: docker-compose -f docker-compose.yml -f docker-compose.test.yml up --detach --no-deps webapp # - name: webapp | Unit tests # #run: docker run --rm ocelotsocialnetwork/webapp:build yarn run test - # run: docker-compose exec -T webapp yarn test \ No newline at end of file + # run: docker-compose exec -T webapp yarn test + + #test: + # runs-on: ubuntu-latest + # steps: + # - uses: actions/checkout@v2 + # - name: Build the stack + # run: | + # git submodule update --init --recursive + # docker-compose up -d + # - name: Test + # env: + # GN_INSTANCE_FOLDER: /tmp/gradio-node-instance + # GN_CONTAINER_NAME: gradido-node-build + # run: docker run gradido-node-test + # timeout-minutes: 2 \ No newline at end of file From ea65400de071b17a3e186199e0fe66150ed44ae0 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 17:35:04 +0100 Subject: [PATCH 2/8] fixed docker builds (they work differently - why?) --- .github/workflows/test.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8879a34bb..2248b65dc 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -74,7 +74,7 @@ jobs: ########################################################################## - name: login server | Build `test` image run: | - docker build --target login_server_debug -t "gradido/loginserver:test" login_server/Dockerfile.debug + docker build --target login_server_debug -t "gradido/loginserver:test" -f ./login_server/Dockerfile.debug login_server/ docker save "gradido/loginserver:test" > /tmp/loginserver.tar - name: Upload Artifact uses: actions/upload-artifact@v2 @@ -100,7 +100,7 @@ jobs: ########################################################################## - name: community server | Build `test` image run: | - docker build -t "gradido/communityserver:test" community_server/ + docker build -t "gradido/communityserver:test" -f ./community_server/Dockerfile ./ docker save "gradido/communityserver:test" > /tmp/communityserver.tar - name: Upload Artifact uses: actions/upload-artifact@v2 From bf34acb573b14cdb2f539ec2817c4a8918979765 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 18:17:39 +0100 Subject: [PATCH 3/8] include submodules in checkout for login server --- .github/workflows/test.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2248b65dc..e340b4889 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -69,6 +69,7 @@ jobs: ########################################################################## - name: Checkout code uses: actions/checkout@v2 + submodules: recursive ########################################################################## # BUILD LOGIN SERVER DOCKER IMAGE (build) ################################ ########################################################################## From abb5f1170d1952e00c3583b1bcf261a9bf1fc326 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 18:18:38 +0100 Subject: [PATCH 4/8] corrected syntax --- .github/workflows/test.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e340b4889..d92f167dc 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -69,7 +69,8 @@ jobs: ########################################################################## - name: Checkout code uses: actions/checkout@v2 - submodules: recursive + with: + - submodules: recursive ########################################################################## # BUILD LOGIN SERVER DOCKER IMAGE (build) ################################ ########################################################################## From 7f01a890ae3b9452de7e23310427cb58dc05aa8c Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 18:19:33 +0100 Subject: [PATCH 5/8] more syntax --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d92f167dc..ed55ced01 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -70,7 +70,7 @@ jobs: - name: Checkout code uses: actions/checkout@v2 with: - - submodules: recursive + submodules: recursive ########################################################################## # BUILD LOGIN SERVER DOCKER IMAGE (build) ################################ ########################################################################## From dc63b4ccaff1df140ea5d848ac0cf1a0d0439b63 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 18:24:30 +0100 Subject: [PATCH 6/8] try to correct submodules path --- .gitmodules | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitmodules b/.gitmodules index b867af34b..60b29abc2 100644 --- a/.gitmodules +++ b/.gitmodules @@ -4,10 +4,10 @@ branch = master [submodule "mithril_client"] path = community_server/mithril_client - url = git@github.com:gradido/gradido_mithrilJS_client.git + url = https://github.com/gradido/gradido_mithrilJS_client.git [submodule "src/protobuf"] path = community_server/src/protobuf - url = git@github.com:gradido/gradido_protocol.git + url = https://github.com/gradido/gradido_protocol.git [submodule "dependencies/tinf"] path = login_server/dependencies/tinf url = https://github.com/jibsen/tinf.git From f12a1a40536ed6abf0171bd9a6b1ba7272a44c1a Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 18:25:41 +0100 Subject: [PATCH 7/8] remove mithril client - seems not to work at all --- .gitmodules | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitmodules b/.gitmodules index 60b29abc2..246626547 100644 --- a/.gitmodules +++ b/.gitmodules @@ -2,9 +2,9 @@ path = gn url = https://github.com/gradido/gn.git branch = master -[submodule "mithril_client"] - path = community_server/mithril_client - url = https://github.com/gradido/gradido_mithrilJS_client.git +#[submodule "mithril_client"] +# path = community_server/mithril_client +# url = https://github.com/gradido/gradido_mithrilJS_client.git [submodule "src/protobuf"] path = community_server/src/protobuf url = https://github.com/gradido/gradido_protocol.git From 7ec9fcf9ea172f1bcdb61ab850ac37725c154898 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Fri, 19 Mar 2021 18:27:16 +0100 Subject: [PATCH 8/8] remove mithril client reference --- community_server/mithril_client | 1 - 1 file changed, 1 deletion(-) delete mode 160000 community_server/mithril_client diff --git a/community_server/mithril_client b/community_server/mithril_client deleted file mode 160000 index f0b1d113c..000000000 --- a/community_server/mithril_client +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f0b1d113cee2a76e9dbb098b315f4acaf38410d0