Skip to content

Commit

Permalink
chore: release unicorn flavor
Browse files Browse the repository at this point in the history
  • Loading branch information
ritika-du committed Oct 28, 2024
1 parent afe1f5f commit 8c4ae35
Show file tree
Hide file tree
Showing 21 changed files with 141 additions and 159 deletions.
19 changes: 10 additions & 9 deletions .github/workflows/ci-docs-shim.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

name: CI Docs Shim

on:
Expand All @@ -6,15 +9,13 @@ on:
types: [milestoned, opened, synchronize]

jobs:
run-test:
name: ${{ matrix.type }} ${{ matrix.flavor }}
runs-on: "ubuntu-latest"
timeout-minutes: 20
validate:
strategy:
matrix:
flavor: [upstream, registry1, unicorn]
type: [install, upgrade]
steps:
- name: Shim for ${{ matrix.type }} ${{ matrix.flavor }}
run: |
echo "Documentation-only change detected; marking ${{ matrix.type }} ${{ matrix.flavor }} as successful."
flavor: [upstream, unicorn]
uses: defenseunicorns/uds-common/.github/workflows/callable-ci-docs-shim.yaml@f0164622ffc2007e96a0e1deaa3f5064db04b148 # v1.1.0
with:
flavor: ${{ matrix.flavor }}
type: ${{ matrix.type }}
secrets: inherit # Inherits all secrets from the parent workflow.
6 changes: 4 additions & 2 deletions .github/workflows/commitlint.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

name: Metadata

on:
Expand All @@ -11,5 +14,4 @@ on:

jobs:
validate:
name: Validate
uses: defenseunicorns/uds-common/.github/workflows/commitlint.yaml@24c8a2a48eeb33773b76b3587c489cb17496c9e0 # v0.12.0
uses: uses: defenseunicorns/uds-common/.github/workflows/callable-commitlint.yaml@f0164622ffc2007e96a0e1deaa3f5064db04b148 # v1.1.0
33 changes: 6 additions & 27 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -1,35 +1,14 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

name: Scan

on:
# This workflow is triggered on pull requests to the main branch.
pull_request:
branches: [main]
types: [milestoned, opened, synchronize]
types: [milestoned, opened, reopened, synchronize]

jobs:
validate:
runs-on: ubuntu-latest
name: Lint
permissions:
contents: read # Allows reading the repo contents

steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
fetch-depth: 0

- name: Environment setup
uses: defenseunicorns/uds-common/.github/actions/setup@24c8a2a48eeb33773b76b3587c489cb17496c9e0 # v0.12.0
with:
registry1Username: ${{ secrets.IRON_BANK_ROBOT_USERNAME }}
registry1Password: ${{ secrets.IRON_BANK_ROBOT_PASSWORD }}
ghToken: ${{ secrets.GITHUB_TOKEN }}

- name: Install lint deps
run: |
uds run lint:deps
- name: Lint the repository
run: |
uds run lint:yaml
uses: defenseunicorns/uds-common/.github/workflows/callable-lint.yaml@f0164622ffc2007e96a0e1deaa3f5064db04b148 # v1.1.0
secrets: inherit

Check failure on line 14 in .github/workflows/lint.yaml

View workflow job for this annotation

GitHub Actions / validate / run

14:21 [new-line-at-end-of-file] no new line character at the end of file
15 changes: 7 additions & 8 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

name: Release

on:
Expand All @@ -14,7 +17,7 @@ permissions:
jobs:
tag-new-version:
permissions: write-all
runs-on: uds-marketplace-ubuntu-big-boy-4-core
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release-flag.outputs.release_created }}
steps:
Expand All @@ -34,13 +37,9 @@ jobs:
strategy:
matrix:
flavor: [upstream, unicorn]
architecture: [amd64, arm64]
exclude:
- flavor: registry1
architecture: arm64
architecture: [amd64]
uses: defenseunicorns/uds-common/.github/workflows/callable-publish.yaml@f0164622ffc2007e96a0e1deaa3f5064db04b148 # v1.1.0
with:
flavor: ${{ matrix.flavor }}
runsOn: ${{ matrix.architecture == 'arm64' && 'uds-marketplace-ubuntu-arm64-4-core' || 'uds-marketplace-ubuntu-big-boy-4-core' }}
reports-path: "tests/.playwright/reports/"
secrets: inherit # Inherits all secrets from the parent workflow.
runsOn: uds-marketplace-ubuntu-big-boy-4-core
secrets: inherit # Inherits all secrets from the parent workflow.

Check failure on line 45 in .github/workflows/release.yaml

View workflow job for this annotation

GitHub Actions / validate / run

45:70 [new-line-at-end-of-file] no new line character at the end of file
3 changes: 3 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

name: Test

# This workflow is triggered on pull requests to the main branch.
Expand Down
3 changes: 3 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
Expand Down
3 changes: 3 additions & 0 deletions bundle/uds-bundle.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

kind: UDSBundle
metadata:
name: jenkins-test
Expand Down
2 changes: 2 additions & 0 deletions bundle/uds-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

Check failure on line 2 in bundle/uds-config.yaml

View workflow job for this annotation

GitHub Actions / validate / run

2:87 [new-line-at-end-of-file] no new line character at the end of file
3 changes: 3 additions & 0 deletions chart/templates/uds-package.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

apiVersion: uds.dev/v1alpha1
kind: Package
metadata:
Expand Down
3 changes: 3 additions & 0 deletions src/namespace/jenkins-ns.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

kind: Namespace
apiVersion: v1
metadata:
Expand Down
3 changes: 3 additions & 0 deletions src/namespace/zarf.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

kind: ZarfPackageConfig
metadata:
name: dev-namespace
Expand Down
115 changes: 55 additions & 60 deletions tasks.yaml
Original file line number Diff line number Diff line change
@@ -1,97 +1,92 @@
includes:
- cleanup: ./tasks/cleanup.yaml
- test: ./tasks/test.yaml
- create: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.12.0/tasks/create.yaml
- lint: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.12.0/tasks/lint.yaml
- pull: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.12.0/tasks/pull.yaml
- deploy: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.12.0/tasks/deploy.yaml
- upgrade: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.12.0/tasks/upgrade.yaml
- setup: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.12.0/tasks/setup.yaml
- dependencies: ./tasks/dependencies.yaml
- create: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/create.yaml
- lint: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/lint.yaml
- pull: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/pull.yaml
- deploy: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/deploy.yaml
- setup: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/setup.yaml
- actions: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/actions.yaml
- badge: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/badge.yaml
- upgrade: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/upgrade.yaml
- compliance: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/compliance.yaml
- publish: https://raw.githubusercontent.com/defenseunicorns/uds-common/v1.1.0/tasks/publish.yaml

tasks:
- name: default
description: Create K3D Cluster with UDS-Core + Jenkins
description: Create K3D Cluster with lite UDS-Core + Jenkins
actions:
- task: create-jenkins-test-bundle
- task: setup:k3d-test-cluster
# TODO: Remove pinned version after uds-common releases 0.12.1 or later
with:
version: 0.26.1
- task: deploy:test-bundle

- task: create-dev-package
- task: setup:k3d-full-cluster
- task: create-deploy-test-bundle

Check failure on line 22 in tasks.yaml

View workflow job for this annotation

GitHub Actions / validate / run

22:1 [trailing-spaces] trailing spaces
- name: default-full
description: Create K3D Cluster with UDS-Core + Jenkins
description: Create K3D Cluster with full UDS-Core + Jenkins
actions:
- task: create-jenkins-test-bundle
- task: create-dev-package
- task: setup:k3d-full-cluster
# TODO: Remove pinned version after uds-common releases 0.12.1 or later
with:
version: 0.26.1
- task: deploy:test-bundle
- task: create-deploy-test-bundle

- name: create-jenkins-package
- name: create-dev-package
description: Create UDS Jenkins Package
actions:
- task: create:package
with:
options: "--skip-sbom"

- name: create-jenkins-test-bundle
description: Create a local UDS Jenkins bundle
actions:
- task: create-jenkins-package
- task: create:test-bundle

- name: create-jenkins-latest-release-bundle
description: Create UDS Jenkins bundle based on the latest release
- name: create-deploy-test-bundle
description: Test and validate cluster is deployed with Jenkins
actions:
- task: pull:latest-package-release
with:
spoof_release: "true"
- task: dependencies:create
- task: create:test-bundle

- name: setup-cluster
description: Setup a K3D cluster with UDS-Core-Slim
actions:
- task: setup:k3d-test-cluster
# TODO: Remove pinned version after uds-common releases 0.12.1 or later
with:
version: 0.26.1
- task: deploy:test-bundle
- task: setup:create-doug-user
- task: test:all

- name: dev
description: Create then deploy local jenkins bundle
description: Create and deploy the bundle on an existing cluster (for iteration/dev speed)
actions:
- task: create-jenkins-test-bundle
- task: create-dev-package
- task: create:test-bundle
- task: deploy:test-bundle

# CI will execute the following (via uds-common/.github/actions/test) so they need to be here with these names

- name: test-package
description: Test the Jenkins package from the current branch
actions:
- task: create-jenkins-test-bundle
- task: dependencies:create
- task: create-dev-package
- task: setup:k3d-test-cluster
# TODO: Remove pinned version after uds-common releases 0.12.1 or later
with:
version: 0.26.1
- task: deploy:test-bundle
- task: setup:create-doug-user
- task: test:health-check
- task: test:ingress
- task: create-deploy-test-bundle
- task: test:ui

- name: test-upgrade
description: Test an upgrade from the latest released package to the current branch
actions:
- task: dependencies:create
- task: upgrade:create-latest-tag-bundle
- task: setup:k3d-test-cluster
# TODO: Remove pinned version after uds-common releases 0.12.1 or later
with:
version: 0.26.1
- task: deploy:test-bundle
- task: create-jenkins-test-bundle
- task: deploy:test-bundle
- task: setup:create-doug-user
- task: test:health-check
- task: test:ingress
- task: test:ui
- task: create-dev-package
- task: create-deploy-test-bundle


Check failure on line 74 in tasks.yaml

View workflow job for this annotation

GitHub Actions / validate / run

74:1 [trailing-spaces] trailing spaces
- name: publish-package
description: Build and publish the packages
actions:
- description: Create the package
task: create:package

- description: Setup the cluster
task: setup:k3d-test-cluster

- description: Create deploy and test the bundle
task: create-deploy-test-bundle

- description: Publish the packages
task: publish:package
with:
# x-release-please-start-version
version: 3.72.0-uds.0
# x-release-please-end
10 changes: 0 additions & 10 deletions tasks/cleanup.yaml

This file was deleted.

15 changes: 15 additions & 0 deletions tasks/dependencies.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Copyright 2024 Defense Unicorns
# SPDX-License-Identifier: AGPL-3.0-or-later OR LicenseRef-Defense-Unicorns-Commercial

tasks:
- name: create
description: Create the Dev-Secrets Dependency Zarf Package
inputs:
options:
description: For setting create time variables and flags
architecture:
description: The architecture of the package to create
default: ${UDS_ARCH}
actions:
- cmd: ./uds zarf package create src/dev-secrets/ --confirm --no-progress --architecture=${{ .inputs.architecture }} --skip-sbom ${{ .inputs.options }}
- cmd: ./uds zarf package create src/namespace/ --confirm --no-progress --architecture=${{ .inputs.architecture }} --skip-sbom ${{ .inputs.options }}

Check failure on line 15 in tasks/dependencies.yaml

View workflow job for this annotation

GitHub Actions / validate / run

15:156 [new-line-at-end-of-file] no new line character at the end of file
40 changes: 0 additions & 40 deletions tasks/publish.yaml

This file was deleted.

Loading

0 comments on commit 8c4ae35

Please sign in to comment.