forked from okteto/okteto
-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (45 loc) · 1.63 KB
/
release-bin.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# https://docs.github.com/en/actions
# This is a basic workflow that is manually triggered
name: Release okteto/bin
# Controls when the action will run. Workflow runs when manually triggered using the UI
# or API.
on:
workflow_dispatch:
# Inputs the workflow accepts.
inputs:
tag:
# Friendly description to be shown in the UI instead of 'tag'
description: 'tag'
# Input has to be provided for the workflow to run
required: true
permissions: # added using https://github.com/step-security/secure-workflows
contents: read
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
- uses: azure/docker-login@v1
with:
username: '${{ secrets.DOCKER_USER }}'
password: '${{ secrets.DOCKER_PASS }}'
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
id: buildx
- name: Inspect builder
run: |
echo "Name: ${{ steps.buildx.outputs.name }}"
echo "Endpoint: ${{ steps.buildx.outputs.endpoint }}"
echo "Status: ${{ steps.buildx.outputs.status }}"
echo "Flags: ${{ steps.buildx.outputs.flags }}"
echo "Platforms: ${{ steps.buildx.outputs.platforms }}"
- name: Push
working-directory: images/bin
run: |
docker buildx build \
--platform linux/amd64,linux/arm64 \
--output "type=image,push=true" \
--build-arg COMMIT_SHA=${{ github.sha }} -t okteto/bin:${{ github.event.inputs.tag }} .