mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-06-28 17:19:44 +00:00
Fix the GitHub workflows
This commit is contained in:
parent
0eb7883a47
commit
223e7379c4
10
.github/workflows/acceptance_tests.yml
vendored
10
.github/workflows/acceptance_tests.yml
vendored
@ -1,12 +1,6 @@
|
|||||||
name: acceptance tests
|
on: [push, pull_request]
|
||||||
|
|
||||||
on:
|
name: Acceptance tests
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- 'main'
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- 'develop'
|
|
||||||
|
|
||||||
env:
|
env:
|
||||||
KUBESHARK_CI_IMAGE: kubeshark/ci:0.0
|
KUBESHARK_CI_IMAGE: kubeshark/ci:0.0
|
||||||
|
54
.github/workflows/acceptance_tests_on_pr.yml
vendored
54
.github/workflows/acceptance_tests_on_pr.yml
vendored
@ -1,54 +0,0 @@
|
|||||||
name: Acceptance tests on PR
|
|
||||||
|
|
||||||
on: push
|
|
||||||
|
|
||||||
env:
|
|
||||||
KUBESHARK_CI_IMAGE: kubeshark/ci:0.0
|
|
||||||
|
|
||||||
concurrency:
|
|
||||||
group: acceptance-tests-on-pr-${{ github.ref }}
|
|
||||||
cancel-in-progress: true
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
run-tests:
|
|
||||||
name: Run tests
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
if: ${{ contains(github.event.head_commit.message, '#run_acceptance_tests') }}
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Set up Go 1.17
|
|
||||||
uses: actions/setup-go@v2
|
|
||||||
with:
|
|
||||||
go-version: '^1.17'
|
|
||||||
|
|
||||||
- name: Check out code into the Go module directory
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
|
||||||
uses: docker/setup-buildx-action@v1
|
|
||||||
|
|
||||||
- name: Build
|
|
||||||
uses: docker/build-push-action@v2
|
|
||||||
with:
|
|
||||||
context: .
|
|
||||||
push: false
|
|
||||||
load: true
|
|
||||||
tags: ${{ env.KUBESHARK_CI_IMAGE }}
|
|
||||||
cache-from: type=gha
|
|
||||||
cache-to: type=gha,mode=max
|
|
||||||
|
|
||||||
- name: Setup acceptance test
|
|
||||||
run: ./acceptanceTests/setup.sh
|
|
||||||
|
|
||||||
- name: Create k8s users and change context
|
|
||||||
env:
|
|
||||||
USERNAME_UNRESTRICTED: user-with-clusterwide-access
|
|
||||||
USERNAME_RESTRICTED: user-with-restricted-access
|
|
||||||
run: |
|
|
||||||
./acceptanceTests/create_user.sh "${USERNAME_UNRESTRICTED}"
|
|
||||||
./acceptanceTests/create_user.sh "${USERNAME_RESTRICTED}"
|
|
||||||
kubectl apply -f cli/cmd/permissionFiles/permissions-all-namespaces-tap.yaml
|
|
||||||
kubectl config use-context ${USERNAME_UNRESTRICTED}
|
|
||||||
|
|
||||||
- name: Test
|
|
||||||
run: make acceptance-test
|
|
16
.github/workflows/build.yml
vendored
16
.github/workflows/build.yml
vendored
@ -1,10 +1,10 @@
|
|||||||
name: Build
|
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
push:
|
||||||
branches:
|
# Sequence of patterns matched against refs/tags
|
||||||
- 'develop'
|
tags:
|
||||||
- 'main'
|
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
|
||||||
|
|
||||||
|
name: Build
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: kubeshark-pr-validation-${{ github.ref }}
|
group: kubeshark-pr-validation-${{ github.ref }}
|
||||||
@ -19,7 +19,7 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
fetch-depth: 2
|
fetch-depth: 2
|
||||||
|
|
||||||
- name: Check modified files
|
- name: Check modified files
|
||||||
id: modified_files
|
id: modified_files
|
||||||
run: devops/check_modified_files.sh cli/
|
run: devops/check_modified_files.sh cli/
|
||||||
@ -42,7 +42,7 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
fetch-depth: 2
|
fetch-depth: 2
|
||||||
|
|
||||||
- name: Check modified files
|
- name: Check modified files
|
||||||
id: modified_files
|
id: modified_files
|
||||||
run: devops/check_modified_files.sh agent/ shared/ tap/ ui/ ui-common/ Dockerfile
|
run: devops/check_modified_files.sh agent/ shared/ tap/ ui/ ui-common/ Dockerfile
|
||||||
|
23
.github/workflows/inactive-issues-close.yaml
vendored
23
.github/workflows/inactive-issues-close.yaml
vendored
@ -1,23 +0,0 @@
|
|||||||
name: Close inactive issues
|
|
||||||
on:
|
|
||||||
schedule:
|
|
||||||
- cron: "0 0 * * *"
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
close-issues:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
permissions:
|
|
||||||
issues: write
|
|
||||||
pull-requests: write
|
|
||||||
steps:
|
|
||||||
- uses: actions/stale@v3
|
|
||||||
with:
|
|
||||||
days-before-issue-stale: 30
|
|
||||||
days-before-issue-close: -1
|
|
||||||
exempt-issue-labels: "enhancement"
|
|
||||||
stale-issue-label: "stale"
|
|
||||||
stale-issue-message: "This issue is stale because it has been open for 30 days with no activity."
|
|
||||||
close-issue-message: ""
|
|
||||||
days-before-pr-stale: -1
|
|
||||||
days-before-pr-close: -1
|
|
||||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
|
10
.github/workflows/release.yml
vendored
10
.github/workflows/release.yml
vendored
@ -1,10 +1,10 @@
|
|||||||
name: Release
|
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
# Sequence of patterns matched against refs/tags
|
||||||
- 'develop'
|
tags:
|
||||||
- 'main'
|
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
|
||||||
|
|
||||||
|
name: Release
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: kubeshark-publish-${{ github.ref }}
|
group: kubeshark-publish-${{ github.ref }}
|
||||||
|
18
.github/workflows/static_code_analysis.yml
vendored
18
.github/workflows/static_code_analysis.yml
vendored
@ -1,10 +1,6 @@
|
|||||||
name: Static code analysis
|
on: [push, pull_request]
|
||||||
|
|
||||||
on:
|
name: Static code analysis
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- 'develop'
|
|
||||||
- 'main'
|
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
@ -113,7 +109,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
version: latest
|
version: latest
|
||||||
working-directory: tap/extensions/amqp
|
working-directory: tap/extensions/amqp
|
||||||
|
|
||||||
- name: Check tap/extensions/http modified files
|
- name: Check tap/extensions/http modified files
|
||||||
id: tap_http_modified_files
|
id: tap_http_modified_files
|
||||||
run: devops/check_modified_files.sh tap/extensions/http/
|
run: devops/check_modified_files.sh tap/extensions/http/
|
||||||
@ -169,11 +165,11 @@ jobs:
|
|||||||
- uses: actions/setup-node@v2
|
- uses: actions/setup-node@v2
|
||||||
with:
|
with:
|
||||||
node-version: 16
|
node-version: 16
|
||||||
|
|
||||||
- name: Check modified UI files
|
- name: Check modified UI files
|
||||||
id: ui_modified_files
|
id: ui_modified_files
|
||||||
run: devops/check_modified_files.sh ui/
|
run: devops/check_modified_files.sh ui/
|
||||||
|
|
||||||
- name: ESLint prerequisites ui
|
- name: ESLint prerequisites ui
|
||||||
if: steps.ui_modified_files.outputs.matched == 'true'
|
if: steps.ui_modified_files.outputs.matched == 'true'
|
||||||
run: |
|
run: |
|
||||||
@ -187,11 +183,11 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
cd ui
|
cd ui
|
||||||
npm run eslint
|
npm run eslint
|
||||||
|
|
||||||
- name: Check modified ui-common files
|
- name: Check modified ui-common files
|
||||||
id: ui_common_modified_files
|
id: ui_common_modified_files
|
||||||
run: devops/check_modified_files.sh ui-common/
|
run: devops/check_modified_files.sh ui-common/
|
||||||
|
|
||||||
- name: ESLint prerequisites ui-common
|
- name: ESLint prerequisites ui-common
|
||||||
if: steps.ui_common_modified_files.outputs.matched == 'true'
|
if: steps.ui_common_modified_files.outputs.matched == 'true'
|
||||||
run: |
|
run: |
|
||||||
|
14
.github/workflows/test.yml
vendored
14
.github/workflows/test.yml
vendored
@ -1,14 +1,6 @@
|
|||||||
name: Test
|
on: [push, pull_request]
|
||||||
|
|
||||||
on:
|
name: Test
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- 'develop'
|
|
||||||
- 'main'
|
|
||||||
push: # needed to upload test coverage report to codecov
|
|
||||||
branches:
|
|
||||||
- 'develop'
|
|
||||||
- 'main'
|
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: kubeshark-tests-validation-${{ github.ref }}
|
group: kubeshark-tests-validation-${{ github.ref }}
|
||||||
@ -62,7 +54,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Shared Test
|
- name: Shared Test
|
||||||
run: make test-shared
|
run: make test-shared
|
||||||
|
|
||||||
- name: Check extensions modified files
|
- name: Check extensions modified files
|
||||||
id: ext_modified_files
|
id: ext_modified_files
|
||||||
run: devops/check_modified_files.sh tap/extensions/ tap/api/
|
run: devops/check_modified_files.sh tap/extensions/ tap/api/
|
||||||
|
Loading…
Reference in New Issue
Block a user