Draft: Feat/mutli environment build support - CU-863gevuu9
The following PR allows mobile ios builds/deploys with support for multiple backends.
Configuration
The backend url for mobile apps are defined in the following files:
./app-deploy/values.yaml (dev)
Triggers:
- ./app-release/dev-build.yaml
- Build Type: debug
- ./app-release/dev-deploy.yaml
- Build Type: release
- Deploy To: beta
./app-deploy/values-stage.yaml (stage)
Triggers:
- ./app-release/stage-build.yaml
- Build Type: debug
- ./app-release/stage-deploy.yaml
- Build Type: release
- Deploy To: beta
./app-deploy/values-uat.yaml (uat)
Triggers:
- ./app-release/uat-build.yaml
- Build Type: release
- ./app-release/uat-deploy.yaml
- Build Type: release
- Deploy To: beta, prod
./app-deploy/values-prod.yaml
Triggers:
- ./app-release/prod-build.yaml
- Build Type: release
- ./app-release/prod-deploy.yaml
- Build Type: release
- Deploy To: beta, prod
When building/deploying the mobile app, the value from the extended config is harvested and compiled into the app itself using the REACT_APP_API_PATH value.
CI/CD Workflows/Triggers
In order to trigger builds or deploys for various environments, this PR proposes the creation of new environment files which contain a tag reference to control which version of the app is deployed. If the tag is invalid, the logic will default to the latest on the master branch. The proposed files are as follows:
./app-release/dev-build.yaml
Triggers:
- increment version
- build env dev
- build ios debug [arm/intel]
./app-release/dev-deploy.yaml
Triggers:
- increment version
- deploy env dev
- build ios debug [arm/intel]
- upload debug mobile apps to s3
- ios beta store
./app-release/stage-build.yaml
Triggers:
- increment version
- build env stage
- build ios debug [arm/intel]
./app-release/stage-deploy.yaml
Triggers:
- increment version
- deploy env stage
- build ios debug [arm/intel]
- upload debug mobile apps to s3
- ios beta store
./app-release/uat-build.yaml
Triggers:
- increment version
- build env uat
- build ios debug [arm/intel]
- build ios release [arm/intel]
./app-release/uat-deploy.yaml
Triggers:
- increment version
- deploy env uat
- build ios debug [arm/intel]
- build ios release [arm/intel]
- upload debug mobile apps to s3
- upload release mobile apps to s3
- ios beta store
- ios production store
./app-release/prod-build.yaml
Triggers:
- increment version
- build env uat
- build ios debug [arm/intel]
- build ios release [arm/intel]
./app-release/prod-deploy.yaml
Triggers:
- increment version
- deploy env uat
- build ios debug [arm/intel]
- build ios release [arm/intel]
- upload debug mobile apps to s3
- upload release mobile apps to s3
- ios beta store
- ios production store
File Contents
The contents of each file are as follows:
tag: 0.0.62
When a user commits a new tag number in each of the respective files, this will trigger a build/deployment for the respective environment whilst harvesting the correct REACT_APP_API_PATH value.