Skip to content

Commit

Permalink
chore: add tasks for deploying published oci and update task versions (
Browse files Browse the repository at this point in the history
…#152)

* Update versions in tasks and add tasks for deploying published OCIs instead of locally built bundles

* release please for deploy tasks file
  • Loading branch information
jacobbmay committed Jul 30, 2024
1 parent b3a4f56 commit ad96a6b
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 4 deletions.
3 changes: 2 additions & 1 deletion release-please-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
],
"versioning": "always-bump-patch",
"extra-files": [
"bundles/uds-core-swf/uds-bundle.yaml"
"bundles/uds-core-swf/uds-bundle.yaml",
"tasks/deploy.yaml"
]
}
}
Expand Down
12 changes: 12 additions & 0 deletions tasks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,18 @@ tasks:
with:
config-dir: ./scratch/configs/test

- name: deploy-published-dev
description: Deploy published oci bundle to dev cluster
actions:
- task: deploy:deploy-published

- name: deploy-published-test
description: Deploy published oci bundle to test cluster
actions:
- task: deploy:deploy-published
with:
config-dir: ./scratch/configs/test

#### Clean ####
- name: clean
actions:
Expand Down
16 changes: 13 additions & 3 deletions tasks/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@ variables:
default: "amd64"
- name: DEPLOY_IMAGE
description: "Container image to use to run uds deploy in"
default: "ghcr.io/defenseunicorns/build-harness/build-harness:2.0.28"
default: "ghcr.io/defenseunicorns/build-harness/build-harness:2.0.34"
- name: BUNDLE_VERSION
description: "Version of the bundle to deploy"
# TODO - add release-please support
default: "0.2.16"
# x-release-please-start-version
default: "0.3.0"
# x-release-please-end

tasks:
- name: uds-version
Expand All @@ -27,3 +28,12 @@ tasks:
description: Input for the path to the directory containing the uds-config.yaml to use for deploying the bundle
actions:
- cmd: docker run --rm -e ARCH=${ARCH} -e BUNDLE_VERSION=${BUNDLE_VERSION} -e UDS_CONFIG=/configs/uds-config.yaml -e KUBECONFIG=/configs/kubeconfig -v /tmp:/tmp -v ${INPUT_CONFIG_DIR}:/configs -v ${INPUT_BUILD_DIR}:/build ${DEPLOY_IMAGE} bash -c 'uds deploy /build/uds-bundle-software-factory-nutanix-${ARCH}-${BUNDLE_VERSION}.tar.zst --confirm'

- name: deploy-published
description: Deploy published oci of bundle from ghcr
inputs:
config-dir:
default: ./scratch/configs/dev
description: Input for the path to the directory containing the uds-config.yaml to use for deploying the bundle
actions:
- cmd: docker run --rm -e BUNDLE_VERSION=${BUNDLE_VERSION} -e UDS_CONFIG=/configs/uds-config.yaml -e KUBECONFIG=/configs/kubeconfig -v /tmp:/tmp -v ${INPUT_CONFIG_DIR}:/configs ${DEPLOY_IMAGE} bash -c 'uds deploy oci://ghcr.io/defenseunicorns/uds-bundle/software-factory-nutanix:${BUNDLE_VERSION} --confirm'

0 comments on commit ad96a6b

Please sign in to comment.