Some checks are pending
Build Flutter SDK Docker Image / build (push) Has started running
43 lines
1.1 KiB
YAML
43 lines
1.1 KiB
YAML
name: Build Flutter SDK Docker Image
|
|
on:
|
|
schedule:
|
|
- cron: '* * * * *'
|
|
push:
|
|
branches:
|
|
- main
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
|
|
### Setup
|
|
|
|
- name: Install docker
|
|
uses: papodaca/install-docker-action@main
|
|
|
|
- name: Install dependencies
|
|
run: apt update && apt install -y curl
|
|
|
|
- name: Check out repository code
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
|
|
- name: Login to Docker Registry
|
|
uses: docker/login-action@v3
|
|
with:
|
|
registry: ${{ vars.DOCKER_REGISTRY_HOST }}
|
|
username: ${{ secrets.DOCKER_REGISTRY_USERNAME }}
|
|
password: ${{ secrets.DOCKER_REGISTRY_PASSWORD }}
|
|
|
|
### Build and push docker image
|
|
|
|
- name: Build and push, channel 'stable'
|
|
run: |
|
|
export CHANNEL=stable
|
|
export IMAGE_WITH_TAG=${{ vars.DOCKER_REGISTRY_HOST }}/${{ vars.DOCKER_REPO_AND_IMAGE }}:web.$CHANNEL
|
|
docker buildx build . --build-arg CHANNEL=$CHANNEL -t $IMAGE_WITH_TAG --no-cache --push
|