add: add a development environment #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker build and execute tests | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the code | |
uses: actions/checkout@v2 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v1 | |
- name: Set metadata | |
id: metadata | |
uses: docker/metadata-action@v5 | |
with: | |
images: asia-northeast1-docker.pkg.dev | |
tags: | | |
type=semver,pattern={{raw}} # tag γε©η¨ | |
type=sha,format=short # sha γε©η¨ | |
- name: Build | |
uses: docker/build-push-action@v5 | |
with: | |
context: github-actions/docker-build-cache | |
push: false | |
tags: ${{ steps.metadata.outputs.tags }} | |
cache-from: type=gha | |
cache-to: type=gha,mode=max # ε ¨γ¬γ€γ€γΌγγ£γγ·γ₯ |