Skip to content

Commit

Permalink
Switch to github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
trnubo committed Mar 22, 2023
1 parent 515c131 commit 01dac58
Show file tree
Hide file tree
Showing 2 changed files with 92 additions and 15 deletions.
80 changes: 80 additions & 0 deletions .github/workflows/build-push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
name: build and push on main and tags

on:
push:
branches:
- main
tags:
- v[0-9]+.[0-9]+.[0-9]+
- v[0-9]+.[0-9]+.[0-9]+-[0-9]+
pull_request:

env:
IMAGE_NAME: panubo/rundeck

jobs:
build_and_push:

runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
# list of Docker images to use as base name for tags
images: |
quay.io/${{ env.IMAGE_NAME }}
# generate Docker tags based on the following events/attributes
tags: |
# type=schedule
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
# type=sha
- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2

- name: Login to Quay.io
if: github.event_name != 'pull_request'
uses: docker/login-action@v2
with:
registry: quay.io
username: ${{ secrets.PANUBUILD_QUAYIO_USERNAME }}
password: ${{ secrets.PANUBUILD_QUAYIO_TOKEN }}

# - name: Setup BATS
# uses: mig4/setup-bats@v1
# with:
# bats-version: 1.7.0

- name: Build and export to Docker
uses: docker/build-push-action@v4
with:
builder: ${{ steps.buildx.outputs.name }}
cache-from: type=gha
load: true
tags: ${{ env.IMAGE_NAME }}:test

# - name: Test
# run: |
# make _ci_test

- name: Build and Push
uses: docker/build-push-action@v3
with:
builder: ${{ steps.buildx.outputs.name }}
push: ${{ github.event_name != 'pull_request' }}
cache-from: type=gha
cache-to: type=gha,mode=max
platforms: linux/amd64
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
27 changes: 12 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,23 +108,20 @@ The following tools are pre-installed in the image
The directory structure looks like:

```
/opt/
/opt
├── argo-3.1
│   └── bin
│   └── argo
├── argo-3.4
│   └── bin
│   └── argo
├── bin
│   ├── lego
│   └── sops
├── helm-3.2
│   └── bin
│   └── helm
├── helm-3.3
│   └── bin
│   └── helm
├── helm-3.4
├── helm-3.10
│   └── bin
│   └── helm
├── helm-3.5
├── helm-3.11
│   └── bin
│   └── helm
├── helm-3.6
Expand All @@ -139,22 +136,22 @@ The directory structure looks like:
├── helm-3.9
│   └── bin
│   └── helm
├── kubectl-1.18
├── kubectl-1.21
│   └── bin
│   └── kubectl
├── kubectl-1.19
├── kubectl-1.22
│   └── bin
│   └── kubectl
├── kubectl-1.20
├── kubectl-1.23
│   └── bin
│   └── kubectl
├── kubectl-1.21
├── kubectl-1.24
│   └── bin
│   └── kubectl
├── kubectl-1.22
├── kubectl-1.25
│   └── bin
│   └── kubectl
├── kubectl-1.23
├── kubectl-1.26
│   └── bin
│   └── kubectl
└── rundeck-plugins
Expand Down

0 comments on commit 01dac58

Please sign in to comment.