Skip to content

Commit

Permalink
Add files for trying to use GitHub Container Registry
Browse files Browse the repository at this point in the history
  • Loading branch information
matsuo committed Aug 11, 2024
1 parent 7cef356 commit 9ccfbcb
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Publish Image

on:
push:
workflow_dispatch:

jobs:
publish:
name: Publish Image
runs-on: ubuntu-latest
steps:
- name: Checkout
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: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GHCR_TOKEN_202506 }}
- name: Push to GitHub Container Registry
uses: docker/build-push-action@v6
with:
push: true
tags: matsuo/goss:latest
secrets: |
GIT_AUTH_TOKEN=${{ secrets.GHCR_TOKEN_202506 }}
12 changes: 12 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
FROM golang:1.22

RUN apt update && apt install curl tar make bash git

WORKDIR /go/src/github.com/goss-org

ARG GOSS_VERSION="0.4.8"
ARG GOSS_COMMIT_HASH="aed56336c3e8ff683e9540065b502f423dd6760d"

RUN curl -L https://github.com/goss-org/goss/archive/${GOSS_COMMIT_HASH}.tar.gz | tar -xzvf -

RUN mv goss-${GOSS_COMMIT_HASH} goss && cd goss && TRAVIS_TAG=${GOSS_VERSION} make build

0 comments on commit 9ccfbcb

Please sign in to comment.