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