diff --git a/.circleci/config.yml b/.circleci/config.yml index b83452ce6f..ace2f80c51 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -47,7 +47,7 @@ build_docker_image: &build_docker_image ./build.sh jobs: # Build & Deploy against development backend - deployDev: + "build-dev": <<: *defaults steps: # Initialization. @@ -73,8 +73,9 @@ jobs: source awsenvconf source buildenvvar ./master_deploy.sh -d ECS -e DEV -t latest -s dev_communityapp_taskvar -i communityapp + # Build & Deploy against testing backend - deployTest: + "build-test": <<: *defaults steps: # Initialization. @@ -100,8 +101,9 @@ jobs: source awsenvconf source buildenvvar ./master_deploy.sh -d ECS -e DEV -t latest -s test_communityapp_taskvar -i communityapp + # Build & Deploy against testing backend - deployQA: + "build-qa": <<: *defaults steps: # Initialization. @@ -127,8 +129,9 @@ jobs: source awsenvconf source buildenvvar ./master_deploy.sh -d ECS -e DEV -t latest -s qa_communityapp_taskvar -i communityapp + # Build & Deploy against prod api backend - deployBeta: + "build-prod-beta": <<: *defaults steps: # Initialization. @@ -156,7 +159,7 @@ jobs: ./master_deploy.sh -d ECS -e PROD -t latest -s beta_communityapp_taskvar, -i communityapp # Build & Deploy against prod api backend - deployStag: + "build-prod-staging": <<: *defaults steps: # Initialization. @@ -189,7 +192,7 @@ jobs: --data '{"branch":"'"$CIRCLE_BRANCH"'","parameters":{"run_smoketesting":true , "run_performancetesting":false, "run_basedeployment": false}}' # Build & Deploy against production backend - deployProd: + "build-prod": <<: *defaults steps: # Initialization. @@ -220,6 +223,8 @@ jobs: --header "Circle-Token: ${CIRCLE_TOKEN}" \ --header 'content-type: application/json' \ --data '{"branch":"'"$CIRCLE_BRANCH"'","parameters":{"run_smoketesting":true , "run_performancetesting":false, "run_basedeployment": false}}' + + # Automated Smoke Testing against Staging Smoke-Testing-On-Staging: <<: *defaults steps: @@ -244,6 +249,8 @@ jobs: ./automated-smoke-test/smoketest.sh automation-config-staging.json prod - store_artifacts: path: /automated-smoke-test/test-results + + # Automated Smoke Testing against Production Smoke-Testing-On-Production: <<: *defaults steps: @@ -266,6 +273,7 @@ jobs: source awsenvconf source buildenvvar ./automated-smoke-test/smoketest.sh automation-config-prod.json prod + # Test job for the cases when we do not need deployment. It just rapidly # installs (updates) app dependencies, and runs tests (ESLint, Stylelint, # Jest unit-tests). @@ -327,49 +335,49 @@ workflows: when: << pipeline.parameters.run_basedeployment >> jobs: # Development builds are executed on "new-develop" branch only. - - deployDev: + - "build-dev": context : org-global filters: branches: only: - - free + - develop # This is alternate dev env for parallel testing - - deployTest: + - "build-test": context : org-global filters: branches: only: - free # This is alternate dev env for parallel testing - - deployQA: + - "build-qa": context : org-global filters: branches: only: - free # This is beta env for production soft releases - - deployBeta: + - "build-prod-beta": context : org-global filters: branches: only: - thrive-bug-fixes # This is stage env for production QA releases - - deployStag: + - "build-prod-staging": context : org-global - filters: + filters: &filters-staging branches: only: - - free + - develop # Production builds are exectuted # when PR is merged to the master # Don't change anything in this configuration # That might trigger wrong branch to be # deployed on the production # master branch. - - deployProd: + - "build-prod": context : org-global - filters: + filters: &filters-prod branches: only: - master @@ -382,7 +390,9 @@ workflows: - develop Smoke Testing: - when: << pipeline.parameters.run_smoketesting >> + when: + and: + - << pipeline.parameters.run_smoketesting >> jobs: - Hold [Smoke-Testing]: type: approval @@ -391,17 +401,13 @@ workflows: requires: - Hold [Smoke-Testing] filters: - branches: - only: - - develop + <<: *filters-staging - Smoke-Testing-On-Production: context : org-global requires: - Hold [Smoke-Testing] filters: - branches: - only: - - master + <<: *filters-prod Performance Testing: when: << pipeline.parameters.run_performancetesting >>