-
Notifications
You must be signed in to change notification settings - Fork 58
nightly v2 #757
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
nightly v2 #757
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
03e4d45
nightly v2
scaliby 349aecf
build: cluster workload
scaliby f9ea41a
add kjob
scaliby d45ddb4
build: add cluster args
scaliby 6d2d76e
build: abstract integration test setup
scaliby bc4874e
build: docker configure
scaliby 4f5b000
build: reusable kueue action
scaliby File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| name: "Install kueue" | ||
| description: "Installs kueue" | ||
|
|
||
| inputs: | ||
| version: | ||
| description: 'The version to install" | ||
| required: false | ||
| default: '0.14.2' | ||
|
|
||
| runs: | ||
| using: composite | ||
| steps: | ||
| - name: Install kubectl-kueue | ||
| run: | | ||
| curl -Lo ./kubectl-kueue https://github.com/kubernetes-sigs/kueue/releases/download/v${{inputs.version}}/kubectl-kueue-linux-amd64 | ||
| chmod +x ./kubectl-kueue | ||
| mv ./kubectl-kueue /usr/local/bin/kubectl-kueue |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,64 @@ | ||
| # Copyright 2025 Google LLC | ||
| # | ||
| # Licensed under the Apache License, Version 2.0 (the "License"); | ||
| # you may not use this file except in compliance with the License. | ||
| # You may obtain a copy of the License at | ||
| # | ||
| # https://www.apache.org/licenses/LICENSE-2.0 | ||
| # | ||
| # Unless required by applicable law or agreed to in writing, software | ||
| # distributed under the License is distributed on an "AS IS" BASIS, | ||
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| # See the License for the specific language governing permissions and | ||
| # limitations under the License | ||
|
|
||
| on: | ||
| pull_request: | ||
|
|
||
| jobs: | ||
| build: | ||
| uses: ./.github/workflows/reusable_build_wheel.yaml | ||
| secrets: inherit | ||
| cpu-cluster: | ||
| runs-on: [ubuntu-22.04] | ||
| needs: [build] | ||
| env: | ||
| NAME: xpk-test-${{github.run_id}} | ||
| ZONE: us-central1-a | ||
| WORKLOAD: test-workload | ||
| steps: | ||
| - uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: '3.10' | ||
| - uses: actions/download-artifact@v4 | ||
| with: | ||
| name: python-package-distributions | ||
| path: dist/ | ||
| - uses: 'google-github-actions/auth@v2' | ||
| with: | ||
| credentials_json: '${{ secrets.GCP_SA_KEY }}' | ||
| - uses: google-github-actions/setup-gcloud@v2 | ||
| with: | ||
| version: '>= 363.0.0' | ||
| install_components: 'beta,gke-gcloud-auth-plugin' | ||
| - name: Authenticate Docker | ||
| run: gcloud auth configure-docker --quiet | ||
| - uses: ./.github/actions/install-kueue | ||
| - name: Install kubectl-kjob | ||
| run: | | ||
| curl -Lo ./kubectl-kjob https://github.com/kubernetes-sigs/kjob/releases/download/v0.1.0/kubectl-kjob-linux-amd64 | ||
| chmod +x ./kubectl-kjob | ||
| mv ./kubectl-kjob /usr/local/bin/kubectl-kjob | ||
| - name: Install XPK | ||
| run: pip install dist/xpk-*.whl | ||
| - name: XPK version | ||
| run: xpk version | ||
| - name: Create cluster | ||
| run: xpk cluster create --cluster=${NAME} --zone=${ZONE} --device-type=n2-standard-32-1 --on-demand --custom-cluster-arguments='${{ secrets.CLUSTER_ARGUMENTS }}' | ||
| - name: Create workload | ||
| run: xpk workload create --cluster=${NAME} --zone=${ZONE} --device-type=n2-standard-32-1 --workload=${WORKLOAD} --command "echo hello" | ||
| - name: List workloads | ||
| run: xpk workload list --cluster=${NAME} --zone=${ZONE} | ||
| - name: Delete cluster | ||
| if: always() | ||
| run: xpk cluster delete --cluster=${NAME} --zone=${ZONE} --force | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| # Copyright 2025 Google LLC | ||
| # | ||
| # Licensed under the Apache License, Version 2.0 (the "License"); | ||
| # you may not use this file except in compliance with the License. | ||
| # You may obtain a copy of the License at | ||
| # | ||
| # https://www.apache.org/licenses/LICENSE-2.0 | ||
| # | ||
| # Unless required by applicable law or agreed to in writing, software | ||
| # distributed under the License is distributed on an "AS IS" BASIS, | ||
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| # See the License for the specific language governing permissions and | ||
| # limitations under the License | ||
|
|
||
| name: Build Wheel | ||
|
|
||
| on: | ||
| workflow_call: | ||
|
|
||
| jobs: | ||
| build: | ||
| name: Build distribution | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| persist-credentials: false | ||
| - name: Set up Python | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.x" | ||
| - name: Install pypa/build | ||
| run: >- | ||
| python3 -m | ||
| pip install | ||
| build | ||
| --user | ||
| - name: Build a binary wheel and a source tarball | ||
| run: python3 -m build | ||
| - name: Store the distribution packages | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: python-package-distributions | ||
| path: dist/ | ||
|
Comment on lines
+22
to
+44
Check warningCode scanning / CodeQL Workflow does not contain permissions Medium
Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| name: "Integration test setup" | ||
|
|
||
| on: | ||
| workflow_call: | ||
|
|
||
| jobs: | ||
| setup-environment: | ||
| runs-on: [ubuntu-22.04] | ||
| steps: | ||
| - uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: '3.10' | ||
| - uses: actions/download-artifact@v4 | ||
| with: | ||
| name: python-package-distributions | ||
| path: dist/ | ||
| - uses: 'google-github-actions/auth@v2' | ||
| with: | ||
| credentials_json: '${{ secrets.GCP_SA_KEY }}' | ||
| - uses: google-github-actions/setup-gcloud@v2 | ||
| with: | ||
| version: '>= 363.0.0' | ||
| install_components: 'beta,gke-gcloud-auth-plugin' | ||
| - name: Install kubectl-kueue | ||
| run: | | ||
| curl -Lo ./kubectl-kueue https://github.com/kubernetes-sigs/kueue/releases/download/v0.14.2/kubectl-kueue-linux-amd64 | ||
| chmod +x ./kubectl-kueue | ||
| mv ./kubectl-kueue /usr/local/bin/kubectl-kueue | ||
| - name: Install kubectl-kjob | ||
| run: | | ||
| curl -Lo ./kubectl-kjob https://github.com/kubernetes-sigs/kjob/releases/download/v0.1.0/kubectl-kjob-linux-amd64 | ||
| chmod +x ./kubectl-kjob | ||
| mv ./kubectl-kjob /usr/local/bin/kubectl-kjob | ||
| - name: Install XPK | ||
| run: pip install dist/xpk-*.whl | ||
| - name: XPK version | ||
| run: xpk version |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium