Skip to content

Commit

Permalink
Add CI
Browse files Browse the repository at this point in the history
Signed-off-by: Phil Dibowitz <[email protected]>
  • Loading branch information
jaymzh committed Mar 4, 2024
1 parent 9078895 commit 620687e
Show file tree
Hide file tree
Showing 4 changed files with 72 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Build

on:
push:
branches: [main]
pull_request:
branches: [main]

permissions:
contents: read

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.21'
cache: false
- name: build
run: |
go mod download
go build -o kubectl-d
21 changes: 21 additions & 0 deletions .github/workflows/dco.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: DCO Check
on: [pull_request]

permissions:
contents: read
pull-requests: read

jobs:
dco_check_job:
runs-on: ubuntu-latest
name: DCO Check
steps:
- name: Get PR Commits
uses: tim-actions/get-pr-commits@master
id: 'get-pr-commits'
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: DCO Check
uses: tim-actions/dco@master
with:
commits: ${{ steps.get-pr-commits.outputs.commits }}
25 changes: 25 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Lint

on:
push:
branches: [main]
pull_request:
branches: [main]

permissions:
contents: read

jobs:
golangci:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.21'
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v4
with:
version: latest
args: --timeout=5m
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# kubectl-daemons

[![Lint](https://github.com/jaymzh/kubectl-daemons/workflows/Lint/badge.svg)](https://github.com/jaymzh/kubectl-daemons/actions?query=workflow%3ALint) [![Build](https://github.com/jaymzh/kubectl-daemons/workflows/Build/badge.svg)](https://github.com/jaymzh/kubectl-daemons/actions?query=workflow%3ABuild) [![DCO](https://github.com/jaymzh/kubectl-daemons/workflows/DCO%20Check/badge.svg)](https://github.com/jaymzh/kubectl-daemons/actions?query=workflow%3A%22DCO+Check%22)

## Intro

kubectl-daemons is a kubectl plugin to help with daemonset work. When running
Expand Down

0 comments on commit 620687e

Please sign in to comment.