Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move builder and cleanup #1

Merged
merged 6 commits into from
Jun 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
3 changes: 2 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
*.img
./.dapper
./.cache
30 changes: 0 additions & 30 deletions .github/release-drafter.yml

This file was deleted.

71 changes: 0 additions & 71 deletions .github/workflows/codeql-analysis.yml

This file was deleted.

14 changes: 14 additions & 0 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Dev Build and Publish

on:
push:
branches:
- master

jobs:
build-for-dev:
uses: ./.github/workflows/factory.yml
with:
tag: ${{ github.ref_name }}-head
push: true
secrets: inherit
116 changes: 0 additions & 116 deletions .github/workflows/docker.yaml

This file was deleted.

67 changes: 67 additions & 0 deletions .github/workflows/factory.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
on:
workflow_call:
inputs:
tag:
required: true
type: string
push:
required: true
type: boolean

env:
repo: "rancher"
provisionerImageName: "harvester-lvm-provisioner"
pluginImageName: "harvester-lvm-csi-plugin"

jobs:
dapper-build:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
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: Run dapper
run: make ci

- name: Read some Secrets
uses: rancher-eio/read-vault-secrets@main
if: ${{ inputs.push == true }}
with:
secrets: |
secret/data/github/repo/${{ github.repository }}/csi-driver-lvm credentials username | DOCKER_USERNAME ;
secret/data/github/repo/${{ github.repository }}/csi-driver-lvm credentials password | DOCKER_PASSWORD
- name: Login to Docker Hub
Vicente-Cheng marked this conversation as resolved.
Show resolved Hide resolved
uses: docker/login-action@v3
if: ${{ inputs.push == true }}
with:
username: ${{ env.DOCKER_USERNAME }}
password: ${{ env.DOCKER_PASSWORD }}

- name: Docker Build (CSI Plugin)
uses: docker/build-push-action@v5
with:
provenance: false
context: .
platforms: linux/amd64,linux/arm64
file: package/Dockerfile
push: ${{ inputs.push }}
tags: ${{ env.repo }}/${{ env.pluginImageName }}:${{ inputs.tag }}

- name: Docker Build (LVM Provisioner)
uses: docker/build-push-action@v5
with:
provenance: false
context: .
platforms: linux/amd64,linux/arm64
file: package/Dockerfile.provisioner
push: ${{ inputs.push }}
tags: ${{ env.repo }}/${{ env.provisionerImageName }}:${{ inputs.tag }}
13 changes: 13 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Pull Request Build

on:
pull_request:
types: [opened, reopened, synchronize]

jobs:
build-for-PR:
uses: ./.github/workflows/factory.yml
with:
tag: pr-${{ github.event.number }}
push: false
secrets: inherit
15 changes: 0 additions & 15 deletions .github/workflows/release-drafter.yaml

This file was deleted.

14 changes: 14 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Release Build and Publish

on:
push:
tags:
- v**

jobs:
build-for-release:
uses: ./.github/workflows/factory.yml
with:
tag: ${{ github.ref_name }}
push: true
secrets: inherit
12 changes: 5 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
bin
loop*
.kubeconfig

# editor specific files
.idea
.vscode
/.dapper
/.cache
/bin
*.swp
.idea
1 change: 0 additions & 1 deletion CODEOWNERS

This file was deleted.

3 changes: 0 additions & 3 deletions CONTRIBUTING.md

This file was deleted.

14 changes: 0 additions & 14 deletions Dockerfile

This file was deleted.

Loading