forked from kubeflow/model-registry
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Andrea Lamparelli <[email protected]>
- Loading branch information
Showing
4 changed files
with
67 additions
and
2 deletions.
There are no files selected for viewing
This file contains 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,59 @@ | ||
name: Test container image build and deployment | ||
on: | ||
pull_request: | ||
paths-ignore: | ||
- "LICENSE*" | ||
- "**.gitignore" | ||
- "**.md" | ||
- "**.txt" | ||
- ".github/ISSUE_TEMPLATE/**" | ||
- ".github/dependabot.yml" | ||
- "docs/**" | ||
- "clients/python/docs/**" | ||
env: | ||
IMG_ORG: kubeflow | ||
IMG_REPO: model-registry | ||
PUSH_IMAGE: false | ||
BRANCH: ${{ github.base_ref }} | ||
jobs: | ||
build-and-test-csi-image: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Generate tag | ||
shell: bash | ||
id: tags | ||
run: | | ||
commit_sha=${{ github.event.after }} | ||
tag=main-${commit_sha:0:7} | ||
echo "tag=${tag}" >> $GITHUB_OUTPUT | ||
- name: Build local model registry image | ||
shell: bash | ||
env: | ||
VERSION: ${{ steps.tags.outputs.tag }} | ||
run: ./scripts/build_deploy.sh | ||
|
||
- name: Build local custom storage initializer | ||
working-directory: ./csi | ||
shell: bash | ||
env: | ||
IMG_VERSION: ${{ steps.tags.outputs.tag }} | ||
# TODO: update go.mod to use local model registry library | ||
run: make docker-build | ||
|
||
- name: Start KinD cluster | ||
uses: helm/[email protected] | ||
with: | ||
node_image: "kindest/node:v1.27.11" | ||
|
||
- name: Install kustomize | ||
run: ./csi/scripts/install_kustomize.sh | ||
|
||
- name: Run tests | ||
working-directory: ./csi | ||
shell: bash | ||
env: | ||
MR_IMG: "${{ env.IMG_ORG }}/${{ env.IMG_REPO }}:${{ steps.tags.outputs.tag }}" | ||
MR_CSI_IMG: "${{ env.IMG_ORG }}/${{ env.IMG_REPO }}-storage-initializer:${{ steps.tags.outputs.tag }}" | ||
run: ./test/e2e_test.sh |
This file contains 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
This file contains 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
This file contains 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,6 @@ | ||
#!/bin/bash | ||
set -e | ||
curl --silent --location --remote-name "https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize%2Fv5.2.1/kustomize_v5.2.1_linux_amd64.tar.gz" | ||
tar -xzvf kustomize_v5.2.1_linux_amd64.tar.gz | ||
chmod a+x kustomize | ||
sudo mv kustomize /usr/local/bin/kustomize |