Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Docker Build & Publish and add ARM image #89

Open
PlugFox opened this issue Feb 15, 2024 · 0 comments
Open

Update Docker Build & Publish and add ARM image #89

PlugFox opened this issue Feb 15, 2024 · 0 comments

Comments

@PlugFox
Copy link

PlugFox commented Feb 15, 2024

Example
Result

name: Build & Push Docker Images

on:
  workflow_dispatch:
    inputs:
      version:
        description: "Version"
        required: true

jobs:
  build_and_push:
    name: "Build & Push"
    runs-on: ubuntu-latest
    defaults:
      run:
        working-directory: ./
    timeout-minutes: 60
    steps:
      - name: Checkout repository
        uses: actions/checkout@v4

      - name: Set up Docker Buildx
        uses: docker/setup-buildx-action@v2

      - name: Log in to Docker Hub
        uses: docker/login-action@v2
        with:
          username: ${{ secrets.DOCKER_HUB_USERNAME }}
          password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}

      - name: Build and push image
        uses: docker/build-push-action@v4
        with:
          context: .
          file: ./Dockerfile
          platforms: linux/arm64, linux/amd64
          push: true
          tags: ${{ secrets.DOCKER_HUB_USERNAME }}/tg-captcha-bot:latest, ${{ secrets.DOCKER_HUB_USERNAME }}/tg-captcha-bot:${{ github.event.inputs.version }}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant