Skip to content

switch devcontainer build to use devcontainer/ci action #6

switch devcontainer build to use devcontainer/ci action

switch devcontainer build to use devcontainer/ci action #6

Workflow file for this run

name: devcontainer
on:
push:
branches:
- 'ts/devcontainers'
env:
REGISTRY: ghcr.io
jobs:
build-image:
name: Build image
runs-on: ubuntu-latest
# timeout-minutes: 40
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Log into container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Docker meta
uses: docker/metadata-action@v5
id: meta
with:
images: |
${{ env.REGISTRY }}/${{ github.repository }}/devcontainer
tags: |
type=ref,event=branch
type=sha
type=edge
- name: Pre-build dev container image
uses: devcontainers/[email protected]
with:
imageName: ${{ env.REGISTRY }}/${{ github.repository }}/devcontainer:ts-devcontainers
imageTag: ${{ steps.meta.outputs.tags }}
cacheFrom: ${{ env.REGISTRY }}/${{ github.repository }}/devcontainer:ts-devcontainers
push: always
platform: linux/amd64,linux/arm64