'create a pipeline in bitbucket for building flutter (Android) app
I am very new to CI/CD pipeline. I am seeking some help. I want to create a pipeline in bitbucket for building flutter (Android) app easily. That will handle several things:
- include Chrome driver using docker run by having separate name
- run this separately in another docker image
- by using same cirrusci/flutter image that is used for whole job
- mount the code directly inside the container with -v ${PWD}:/build/ (i.e. this one uses now container directory /build/. but this can be anything)
- use -w /build/ to specify working directory for the command that is run inside docker
- using --network=container:chromedriver to share all networking between chromedriver and flutter container
- command fiven in the end of docker run command will be flutter drive
currently, I am using the following configuration:
#Build configuration for installer-admin-application
image: cirrusci/flutter:stable
options:
docker: true
pipelines:
branches:
test_test:
- step:
name: run test
script:
#- flutter test
#- docker run --name chromedriver -d --network host -e CHROMEDRIVER_WHITELISTED_IPS='' robcherry/docker-chromedriver:latest
- docker run --name chromedriver -d robcherry/docker-chromedriver:latest
- docker run --name flutter_ws -d cirrusci/flutter:stable --network=container:chromedriver
- flutter drive -v --driver=test_driver/app.dart --target=test_driver/app_test.dart -d web-server -web-port=49430
- step:
name: build app
script:
- flutter build web
But I am not sure how can I achieve the above specifications. Any suggestion or help please?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
