Skip to content

Commit

Permalink
[Cherry-pick for 1.13.6] (#370)
Browse files Browse the repository at this point in the history
* Refactor CI/CD scripts, remove vendor directory and migrate circleci to github workflow (#353)

* remove vendor directory

Signed-off-by: Raj Das <[email protected]>

* remove vendor directory

Signed-off-by: Raj Das <[email protected]>

* refactoring dockerfile

Signed-off-by: Raj Das <[email protected]>

* Refactor docker file

Signed-off-by: Raj Das <[email protected]>

* Adding entry point

Signed-off-by: Raj Das <[email protected]>

* fix typo

Signed-off-by: Raj Das <[email protected]>

* test

Signed-off-by: Raj Das <[email protected]>

* go fmt

Signed-off-by: Raj Das <[email protected]>

* Removing trivy scan from the build pipeline

Signed-off-by: Raj Das <[email protected]>

* chore(probe): Adding stop-on-failure field inside probe (#365)

Signed-off-by: shubhamchaudhary <[email protected]>

Co-authored-by: Raj Babu Das <[email protected]>

* chore(chaosresult): updating verdict and status in chaosengine and chaosresult (#366)

Signed-off-by: shubhamchaudhary <[email protected]>

* Bug(crd): Fix Chaos Experiment crds for securityContext field (#367)

* Bug(crd): Fix Chaos Experiment crds for securityContext field

Signed-off-by: uditgaurav <[email protected]>

* update chaosengine types.go

Signed-off-by: udit <[email protected]>

* update chaosengine types.go

Signed-off-by: udit <[email protected]>

Co-authored-by: Shubham Chaudhary <[email protected]>

* chore(targets): Renaming the target name in chaosresults (#369)

Signed-off-by: shubhamchaudhary <[email protected]>

* (chore)workflow: update branch in build workflow

Signed-off-by: ksatchit <[email protected]>

Co-authored-by: Raj Babu Das <[email protected]>
Co-authored-by: Shubham Chaudhary <[email protected]>
Co-authored-by: Raj Babu Das <[email protected]>
Co-authored-by: Udit Gaurav <[email protected]>
  • Loading branch information
5 people authored Jun 15, 2021
1 parent 4b0afaf commit 2f8c3c0
Show file tree
Hide file tree
Showing 2,753 changed files with 659 additions and 1,014,183 deletions.
180 changes: 0 additions & 180 deletions .circleci/config.yml

This file was deleted.

85 changes: 85 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
name: build-pipeline
on:
pull_request:
branches: [v1.13.x]
types: [opened, synchronize, reopened]

jobs:
pre-checks:
runs-on: ubuntu-latest
steps:
# Install golang
- uses: actions/setup-go@v2
with:
go-version: 1.14

# Checkout to the latest commit
# On specific directory/path
- name: Checkout
uses: actions/checkout@v2

- name: gofmt check
run: make gofmt-check

- name: golangci-lint
uses: reviewdog/action-golangci-lint@v1

- name: unused-package check
run: make unused-package-check

image-build:
runs-on: ubuntu-latest
needs: pre-checks
steps:
# Checkout to the latest commit
# On specific directory/path
- name: Checkout
uses: actions/checkout@v2

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
with:
version: latest

- name: Build Docker Image
env:
DOCKER_REPO: litmuschaos
DOCKER_IMAGE: chaos-operator
DOCKER_TAG: ci
run: |
make build-chaos-operator
tests:
runs-on: ubuntu-latest
needs: pre-checks
steps:
# Install golang
- uses: actions/setup-go@v2
with:
go-version: 1.14

# Checkout to the latest commit
# On specific directory/path
- name: Checkout
uses: actions/checkout@v2

#Install and configure a kind cluster
- name: Installing Prerequisites (KinD Cluster)
uses: engineerd/[email protected]
with:
version: "v0.7.0"

- name: Configuring and testing the Installation
run: |
kubectl cluster-info --context kind-kind
kind get kubeconfig --internal >$HOME/.kube/config
kubectl get nodes
- name: Dependency checks
run: |
make deps
- name: Running Go BDD Test
run: |
make test
2 changes: 1 addition & 1 deletion .github/workflows/main.yml → .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: ChaosOperator-E2E
name: ChaosOperator-E2E-pipeline
on:
issue_comment:
types: [created]
Expand Down
96 changes: 96 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
name: push-pipeline
on:
push:
branches:
- master
tags-ignore:
- '**'

jobs:
pre-checks:
runs-on: ubuntu-latest
steps:
# Install golang
- uses: actions/setup-go@v2
with:
go-version: 1.14

# Checkout to the latest commit
# On specific directory/path
- name: Checkout
uses: actions/checkout@v2

- name: gofmt check
run: make gofmt-check

- name: golangci-lint
uses: reviewdog/action-golangci-lint@v1

- name: unused-package check
run: make unused-package-check

image-build:
runs-on: ubuntu-latest
needs: pre-checks
steps:
# Checkout to the latest commit
# On specific directory/path
- name: Checkout
uses: actions/checkout@v2

- name: Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: all

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
with:
version: latest

- name: login to GitHub Container Registry
run: echo ${{ secrets.DPASS }} | docker login -u ${{ secrets.DNAME }} --password-stdin

- name: Build & Push Docker Image
env:
DOCKER_REPO: ${{ secrets.DOCKER_REPO }}
DOCKER_IMAGE: ${{ secrets.DOCKER_IMAGE }}
DOCKER_TAG: ci
DNAME: ${{ secrets.DNAME }}
DPASS: ${{ secrets.DPASS }}
run: make push-chaos-operator

tests:
needs: pre-checks
runs-on: ubuntu-latest
steps:
# Checkout to the latest commit
# On specific directory/path
- name: Checkout
uses: actions/checkout@v2

# Install golang
- uses: actions/setup-go@v2
with:
go-version: 1.14

#Install and configure a kind cluster
- name: Installing Prerequisites (KinD Cluster)
uses: engineerd/[email protected]
with:
version: "v0.7.0"

- name: Configuring and testing the Installation
run: |
kubectl cluster-info --context kind-kind
kind get kubeconfig --internal >$HOME/.kube/config
kubectl get nodes
- name: Dependency checks
run: |
make deps
- name: Running Go BDD Test
run: |
make test
Loading

0 comments on commit 2f8c3c0

Please sign in to comment.