mirror of
https://github.com/roleypoly/roleypoly.git
synced 2025-06-16 17:49:09 +00:00
setup dev containers again
This commit is contained in:
parent
c23b84c4fa
commit
80db505a11
3 changed files with 95 additions and 0 deletions
53
.github/workflows/dev-container.yml
vendored
Normal file
53
.github/workflows/dev-container.yml
vendored
Normal file
|
@ -0,0 +1,53 @@
|
|||
name: Dev Container
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- hack/dockerfiles/dev-container.Dockerfile
|
||||
- .github/workflows/dev-container.yml
|
||||
schedule:
|
||||
- cron: '0 12 * * 2' # 12 noon every tuesday
|
||||
jobs:
|
||||
docker_build:
|
||||
name: Docker Build & Publish
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@master
|
||||
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: /tmp/.buildx-cache
|
||||
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-buildx-
|
||||
|
||||
- name: Docker meta
|
||||
id: docker_meta
|
||||
uses: crazy-max/ghaction-docker-meta@v1
|
||||
with:
|
||||
images: ghcr.io/roleypoly/dev-container
|
||||
tag-sha: true
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
id: buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
with:
|
||||
install: true
|
||||
|
||||
- name: Login to GitHub Packages Docker Registry
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: roleypoly
|
||||
password: ${{ secrets.GHCR_PAT }}
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
context: .
|
||||
file: ./hack/dockerfiles/dev-container.Dockerfile
|
||||
push: true
|
||||
cache-from: type=local,src=/tmp/.buildx-cache
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache
|
||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
Loading…
Add table
Add a link
Reference in a new issue