Skip to content
Open
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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: docker/build-push-action@v2
- uses: docker/build-push-action@v6
with:
file: unit_tests.dockerfile
tags: test-image:latest
Expand Down
26 changes: 13 additions & 13 deletions .github/workflows/end-to-end-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,28 +20,28 @@ jobs:
if: ${{ github.event.label.name == 'ready-to-test' }}
steps:
- name: checkout the repo
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}

- name: Get branch name
id: branch-name
uses: tj-actions/branch-names@v7.0.7
uses: tj-actions/branch-names@v9

- name: Set outputs
id: vars
run: echo "sha_commit=$(git rev-parse HEAD)" >> $GITHUB_OUTPUT

- name: build the kubeslice controller
uses: docker/build-push-action@v3
uses: docker/build-push-action@v6
with:
tags: kubeslice-controller:${{ steps.vars.outputs.sha_commit }}
build-args: |
PLATFORM=amd64
push: false

- name: Scanning image for vulnerablilities
uses: aquasecurity/trivy-action@master
uses: aquasecurity/trivy-action@0.28.0
with:
image-ref: kubeslice-controller:${{ steps.vars.outputs.sha_commit }}
format: 'table'
Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
bash .github/workflows/scripts/binary-image-critical.sh

- name: Upload artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: trivy-scan
path: scan.txt
Expand All @@ -96,15 +96,15 @@ jobs:
bash run.sh kind

- name: Checkout gh-pages repo
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: kubeslice/e2e-allure-reports
path: gh-pages
ref: 'gh-pages'

- name: Get current date
id: date
run: echo "::set-output name=date::$(date +'%Y-%m-%dT%H:%M:%S')"
run: echo "date=$(date +'%Y-%m-%dT%H:%M:%S')" >> $GITHUB_OUTPUT

- name: Allure Report with history
uses: PavanMudigonda/[email protected]
Expand Down Expand Up @@ -135,7 +135,7 @@ jobs:
SSH_AUTH_SOCK: /tmp/ssh_agent.sock

- name: Deploy report to Github Pages
uses: peaceiris/actions-gh-pages@v3
uses: peaceiris/actions-gh-pages@v4
with:
publish_branch: gh-pages
deploy_key: ${{ secrets.E2E_ALLURE_REPORTS_PRIVATE_KEY }}
Expand All @@ -149,10 +149,10 @@ jobs:
echo 'https://kubeslice.github.io/e2e-allure-reports/Kind-${{ github.event.repository.name }}-${{ steps.date.outputs.date }}-${{ github.base_ref }}-${{ github.run_number }}/index.html'

- name: Report link on Pull Request comment
uses: thollander/actions-comment-pull-request@v2
uses: thollander/actions-comment-pull-request@v3
with:
message: |
report link 'https://kubeslice.github.io/e2e-allure-reports/Kind-${{ github.event.repository.name }}-${{ steps.date.outputs.date }}-${{ github.base_ref }}-${{ github.run_number }}/index.html'
report link 'https://kubeslice.github.io/e2e-allure-reports/Kind-${{ github.event.repository.name }}-${{ steps.date.outputs.date }}-${{ github.base_ref }}-${{ github.run_number }}/index.html'
GITHUB_TOKEN: ${{ secrets.TOKEN }}

- name: Run Quality Gate Check
Expand All @@ -164,12 +164,12 @@ jobs:

- name: Send mail
if: always()
uses: dawidd6/action-send-mail@v3
uses: dawidd6/action-send-mail@v6
with:
server_address: smtp.gmail.com
server_port: 465
username: ${{secrets.MAIL_USERNAME}}
password: ${{secrets.MAIL_PASSWORD}}
username: ${{ secrets.MAIL_USERNAME }}
password: ${{ secrets.MAIL_PASSWORD }}
cc: [email protected], [email protected], [email protected]
subject: Kubeslice-controller | controller-end-to-end-test | ${{ steps.date.outputs.date }}
to: [email protected], [email protected]
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/trivy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,27 +11,28 @@ permissions:
contents: read

jobs:
build:
trivy-scan:
permissions:
contents: read # for actions/checkout to fetch code
security-events: write # for github/codeql-action/upload-sarif to upload SARIF results
actions: read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
name: Build
runs-on: ubuntu-20.04
name: Trivy Security Scan
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Run Trivy vulnerability scanner in repo mode
uses: aquasecurity/trivy-action@master
uses: aquasecurity/trivy-action@0.28.0
with:
scan-type: 'repo'
ignore-unfixed: true
format: 'sarif'
output: 'trivy-results.sarif'
severity: 'CRITICAL'
severity: 'CRITICAL,HIGH'
exit-code: '1'

- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v2
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: 'trivy-results.sarif'