2020-12-23 19:15:23 +00:00
2020-10-08 00:52:52 +02:00
2020-12-23 19:15:23 +00:00
2020-12-23 19:15:23 +00:00
2020-12-23 19:15:23 +00:00
2020-10-08 01:00:09 +02:00
2020-12-19 03:21:31 +01:00
2020-10-08 00:52:52 +02:00
2020-10-08 00:52:52 +02:00
2020-12-19 03:24:28 +01:00
2020-10-08 00:52:52 +02:00
2020-10-08 00:58:59 +02:00
2020-12-19 03:21:31 +01:00
2020-12-19 03:21:31 +01:00
2020-10-08 00:52:52 +02:00
2020-10-08 00:52:52 +02:00
2020-12-23 19:15:23 +00:00
2020-10-08 00:52:52 +02:00

GitHub release GitHub marketplace Test workflow Codecov Become a sponsor Paypal Donate

About

GitHub Action to use Docker Buildx Bake as a high-level build command.

If you are interested, check out my other :octocat: GitHub Actions!


Usage

name: ci
on:
  pull_request:
    branches: master
  push:
    branches: master
    tags:

jobs:
  bake:
    runs-on: ubuntu-latest
    steps:
      -
        name: Checkout
        uses: actions/checkout@v2
      -
        name: Set up QEMU
        uses: docker/setup-qemu-action@v1
      -
        name: Set up Docker Buildx
        uses: docker/setup-buildx-action@v1
      -
        name: Login to DockerHub
        uses: docker/login-action@v1 
        with:
          username: ${{ secrets.DOCKERHUB_USERNAME }}
          password: ${{ secrets.DOCKERHUB_TOKEN }}
      -
        name: Build and push
        uses: crazy-max/ghaction-docker-buildx-bake@v1
        with:
          files: |
            ./config.hcl
          targets: |
            release
          push: true

Customizing

inputs

Following inputs can be used as step.with keys

Name Type Description
builder String Builder instance (see setup-buildx action)
files List List of bake definition files
targets List List of bake targets
no-cache Bool Do not use cache when building the image (default false)
pull Bool Always attempt to pull a newer version of the image (default false)
load Bool Load is a shorthand for --set=*.output=type=docker (default false)
push Bool Push is a shorthand for --set=*.output=type=registry (default false)
set CSV List of targets values to override (eg: targetpattern.key=value)

List type can be a comma or newline-delimited string

targets: default,release
targets: |
  default
  release

CSV type must be a newline-delimited string

set: target.args.mybuildarg=value
set: |
  target.args.mybuildarg=value
  foo*.args.mybuildarg=value

Keep up-to-date with GitHub Dependabot

Since Dependabot has native GitHub Actions support, to enable it on your GitHub repo all you need to do is add the .github/dependabot.yml file:

version: 2
updates:
  # Maintain dependencies for GitHub Actions
  - package-ecosystem: "github-actions"
    directory: "/"
    schedule:
      interval: "daily"

Limitation

This action is only available for Linux virtual environments.

How can I help?

All kinds of contributions are welcome 🙌! The most basic way to show your support is to star 🌟 the project, or to raise issues 💬 You can also support this project by becoming a sponsor on GitHub 👏 or by making a Paypal donation to ensure this journey continues indefinitely! 🚀

Thanks again for your support, it is much appreciated! 🙏

License

MIT. See LICENSE for more details.

Description
GitHub Action to use Docker Buildx Bake as a high-level build command
Readme 166 MiB
Languages
TypeScript 84.2%
HCL 8.5%
Dockerfile 6.9%
Go 0.4%