40 lines
1.1 KiB
YAML
40 lines
1.1 KiB
YAML
name: Build'n'Push
|
|
run-name: ${{ gitea.actor }} building and deploying images
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: catthehacker/ubuntu:act-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0 # all history for all branches and tags
|
|
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v2
|
|
|
|
- name: Login to registry
|
|
uses: docker/login-action@v2
|
|
with:
|
|
registry: git.arrowlab.ru
|
|
username: ${{ secrets.USER }}
|
|
password: ${{ secrets.PASSWORD }}
|
|
|
|
- name: Build and push
|
|
uses: docker/build-push-action@v4
|
|
env:
|
|
ACTIONS_RUNTIME_TOKEN: '' # See https://gitea.com/gitea/act_runner/issues/119
|
|
with:
|
|
context: .
|
|
file: ./Dockerfile
|
|
platforms: |
|
|
linux/amd64
|
|
push: true
|
|
# tags: git.arrowlab.ru/${{ gitea.repository }}:${{ gitea.ref_name }}
|
|
tags: git.arrowlab.ru/ratelok/docker_task2_2:main |