Skip to content
This repository has been archived by the owner on Oct 10, 2023. It is now read-only.

Commit

Permalink
Implement packages installation APIs for cluster essential
Browse files Browse the repository at this point in the history
Signed-off-by: Vandana Pathak <[email protected]>
  • Loading branch information
Vandana Pathak committed May 4, 2023
1 parent 42deddd commit 82e5c83
Show file tree
Hide file tree
Showing 3,864 changed files with 3,228 additions and 693,380 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
5 changes: 0 additions & 5 deletions .codecov.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,4 @@ coverage:
only_pulls: false
changes: false
ignore:
- "vendor"
- "pinniped/**/*"
- "provider-bundle"
- "providers.zip"
- "providers.tar.gz"
- "**/zz_generated.deepcopy.go"
2 changes: 2 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@ hack/
packages/
docs/
test/
build/
bin/
48 changes: 0 additions & 48 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,56 +14,8 @@ updates:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "gomod"
directory: "addons/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "gomod"
directory: "pinniped-components/post-deploy/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "gomod"
directory: "/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "gomod"
directory: "hack/packages/kbld-image-replace/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "gomod"
directory: "hack/tools/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "gomod"
directory: "pkg/v1/providers/tests/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "npm"
directory: "tkg/web/e2e/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "npm"
directory: "tkg/web/node-server/"
schedule:
interval: "daily"
open-pull-requests-limit: 0

- package-ecosystem: "npm"
directory: "tkg/web/"
schedule:
interval: "daily"
open-pull-requests-limit: 0
118 changes: 31 additions & 87 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -1,94 +1,38 @@
name: Build

on:
pull_request:
branches: [ main, release-* ]

on: [pull_request]
jobs:
build:
name: build
runs-on: ubuntu-latest
steps:
- name: Free some disk space on runner
run: |
echo "free space before cleanup:"
df -h
sudo rm -rf /usr/share/dotnet /opt/ghc /usr/local/share/boost /usr/lib/jvm /usr/lib/firefox /opt/microsoft/powershell /opt/hostedtoolcache
echo "free space after cleanup:"
df -h
- name: Set up Go 1.x
uses: actions/setup-go@v3
with:
go-version: 1.18
id: go

- name: Use Node 16.x
uses: actions/setup-node@v3
with:
node-version: 16.x

- name: Check out code into the Go module directory
uses: actions/checkout@v1

- name: go cache
uses: actions/cache@v3
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Get npm cache directory
id: npm-cache-dir
run: |
echo "::set-output name=dir::$(npm config get cache)"
- name: npm cache
uses: actions/cache@v3
id: npm-cache # use this to check for `cache-hit` ==> if: steps.npm-cache.outputs.cache-hit != 'true'
with:
path: ${{ steps.npm-cache-dir.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Get dependencies
run: go mod download

- name: Extract PR Number
uses: Dovyski/payload-info-action@master
id: get_pr_num
with:
# when event is a pull request, obtaining the PR number is obvious
filter_pull_request: '.number'
# when event is a push (merge of PR), since we require linear history,
# we are not even generating a merge commit that can help identify the
# PR number, so don't even try. Instead we just hard-code to a dummy
# value.
filter_push: 1009

- name: Find Comment
uses: peter-evans/find-comment@v1
id: findcomment
with:
issue-number: ${{ steps.get_pr_num.outputs.value }}
body-includes: //usebom
direction: last

- name: Extract Alternate BOM
shell: bash
run: |
export BOMCOMMENT=$(echo -e "${{ steps.findcomment.outputs.comment-body }}" | tr -d "[:space:]")
echo "##[set-output name=bompath;]$(echo "$BOMCOMMENT" | awk -F : '{print $2}')"
id: extract_bom

- name: run make all
run: |
if [[ ! -z "${{ steps.extract_bom.outputs.bompath }}" ]]; then
export TKG_DEFAULT_COMPATIBILITY_IMAGE_PATH=${{ steps.extract_bom.outputs.bompath }}
fi
env | sort
make configure-bom
make all ENVS=linux-amd64
- name: Free some disk space on runner
run: |
echo "free space before cleanup:"
df -h
sudo rm -rf /usr/share/dotnet /opt/ghc /usr/local/share/boost /usr/lib/jvm /usr/lib/firefox /opt/microsoft/powershell /opt/hostedtoolcache
echo "free space after cleanup:"
df -h
- name: Set up Go 1.x
uses: actions/setup-go@v3
with:
go-version: 1.18
id: go

- name: Check out code into the Go module directory
uses: actions/checkout@v1

- name: go cache
uses: actions/cache@v3
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: run make docker-build-all
run: |
make docker-build-all
63 changes: 0 additions & 63 deletions .github/workflows/cherry-pick.yaml

This file was deleted.

39 changes: 0 additions & 39 deletions .github/workflows/cli_core_e2e_test.yaml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ jobs:
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
pull-requests: write # Required for adding comment on PR
name: Trivy Scan
runs-on: "ubuntu-latest"
steps:
Expand All @@ -30,19 +29,7 @@ jobs:
limit-severities-for-sarif: true

- name: Upload Trivy scan results to GitHub Security tab
id: upload-report
uses: github/codeql-action/upload-sarif@v2
if: always()
with:
sarif_file: 'trivy-results.sarif'

# **The URL in comment message is formulated specifically for pull-requests.**
# If this workflow is enhanced for push/scheduled events,
# please update the message contents accordingly.
- name: Comment on PR with results URL
uses: mshick/add-pr-comment@v2
if: ${{ steps.upload-report.outputs.sarif-id }} # Run only if report uploaded successfully
with:
message: |
CVE Scan results for this PR can be viewed from
${{ github.server_url }}/${{ github.repository }}/security/code-scanning?query=pr%3A${{ github.event.number }}
Loading

0 comments on commit 82e5c83

Please sign in to comment.