-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update the baseLedgerEndpoint configuration in the Paladin node confi…
…gurations to include the type and local nodeName. Update the build.gradle file for the Paladin operator to include a new task for preparing artifacts. Add a launch.json file for VS Code to include configurations for running the controller, contract generator, template generator, and artifacts generator. Update the chart versions in the Paladin operator and Paladin operator CRD charts to reflect the changes. Signed-off-by: dwertent <[email protected]>
- Loading branch information
Showing
30 changed files
with
9,650 additions
and
182 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,66 @@ | ||
# Workflow Overview | ||
|
||
This repository is equipped with automated workflows that streamline key processes for PRs, changes to the `main` branch, and releases. These workflows ensure smooth development, testing, and deployment cycles. | ||
|
||
## PR Opened 🚦 | ||
When a developer opens a PR, several automated checks are triggered to validate the changes: | ||
|
||
- **[Build the Project](workflows/paladin-PR-build.yml):** | ||
Runs essential tasks to ensure code quality and reliability: | ||
- **Build and Test:** Compiles the code and runs tests for all subdirectories. | ||
- **[Build Docker Images](workflows/build-image.yaml):** Builds Docker images based on PR changes for local validation. | ||
> **Note:** These images are **not published** to a registry. | ||
- **[Template the Helm Chart](workflows/build-chart.yaml):** Rebuilds and validates Helm charts for correctness. | ||
> **Note:** Charts are **not published** but tested locally. | ||
|
||
## Changes Pushed to Main 🌟 | ||
Once changes are merged into the `main` branch, workflows prepare the project for production: | ||
|
||
- **[Build the Project](workflows/paladin-PR-build.yml):** | ||
Similar to PR checks, this ensures the integrity of the main branch: | ||
- **Build and Test:** Compiles code and runs tests for all subdirectories. | ||
|
||
- **[Publish Docker Images](workflows/cross-build-images.yaml):** | ||
Produces production-grade, cross-platform Docker images and publishes them to the container registry: | ||
- **Registry:** `ghcr.io/<repository-owner>` | ||
- **Tagging:** Images are tagged with `main`. | ||
|
||
- **[Update Documentation](workflows/docs.yaml):** | ||
Detects documentation updates and publishes the latest content to the documentation site. | ||
|
||
|
||
## Release Time 🚀 | ||
Releases deliver artifacts and resources to users and deployment targets through these workflows: | ||
|
||
- **[Release Orchestrator](workflows/release.yaml):** | ||
Triggered by a version tag (e.g., `v1.2.3`), this workflow coordinates all release activities: | ||
- **[Release Docker Images](workflows/release-images.yaml):** | ||
Builds and **publishes Docker images** tagged with the release version (e.g., `v1.2.3`) and `latest`. | ||
- **Registries:** | ||
- `ghcr.io/<repository-owner>`. | ||
- `docker.io/<repository-owner>`. | ||
> `latest` is configurable | ||
- **[Release Helm Chart](workflows/release-charts.yaml):** | ||
Packages and **publishes Helm charts** to the chart repository tagged with the release version (e.g., `v1.2.3`) and `latest`. | ||
> `latest` is configurable | ||
- **[Release TypeScript SDK](workflows/release-typescript-sdk.yaml):** | ||
Updates and **publishes the TypeScript SDK** to its registry: | ||
- **Version:** Defined in [package.json](../sdk/typescript/package.json). | ||
|
||
### Releasing Options: | ||
1. **Automatic:** Push a Git tag in the format `vX.Y.Z` (e.g., `v1.2.3`), and the workflows handle the release, marking it as the latest. | ||
2. **Manual:** Trigger the [release workflow](https://github.com/LF-Decentralized-Trust-labs/paladin/actions/workflows/release.yaml) via the GitHub Actions interface, specifying the version and selecting the "latest" option if needed. | ||
|
||
|
||
## Manual Actions 🛠️ | ||
Workflows can also be triggered manually when needed. Available options include: | ||
|
||
- **[Release Orchestrator](workflows/release.yaml)** | ||
- **[Release Docker Images](workflows/release-images.yaml)** | ||
- **[Release Helm Chart](workflows/release-charts.yaml)** | ||
- **[Release TypeScript SDK](workflows/release-typescript-sdk.yaml)** | ||
- **[Build Helm Chart](workflows/build-chart.yaml)** | ||
- **[Build Docker Images](workflows/build-image.yaml)** | ||
- **[Cross-Platform Docker Image Build](workflows/cross-build-images.yaml)** | ||
|
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 |
---|---|---|
@@ -1,5 +1,10 @@ | ||
name: Helm Chart release | ||
|
||
permissions: | ||
contents: write | ||
packages: write | ||
id-token: write | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
|
@@ -135,8 +140,23 @@ jobs: | |
- name: Run chart-releaser | ||
uses: helm/[email protected] | ||
with: | ||
mark_as_latest: ${{ inputs.latest }} | ||
mark_as_latest: false # the release is marked as latest in the next step | ||
charts_dir: "operator/charts" | ||
skip_existing: true | ||
env: | ||
CR_TOKEN: "${{ env.CR_TOKEN }}" | ||
|
||
- name: Prepare CRs artifacts | ||
run: ./gradlew prepareArtifacts -PartifactDir=${{ github.workspace }}/artifacts | ||
- name: Release | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
tag_name: ${{ inputs.chart_tag }} | ||
body: "Release ${{ inputs.chart_tag }}" | ||
generate_release_notes: true | ||
make_latest: ${{ inputs.latest }} | ||
files: | | ||
${{ github.workspace }}/artifacts/basenet.yaml | ||
${{ github.workspace }}/artifacts/devnet.yaml | ||
${{ github.workspace }}/artifacts/artifacts.tar.gz | ||
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
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,55 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "Run Controller", | ||
"type": "go", | ||
"preLaunchTask": "check-running-on-kind", | ||
"request": "launch", | ||
"mode": "debug", | ||
"program": "${workspaceFolder}/cmd/main.go", | ||
"env": { | ||
"KUBE_LOCAL": "true", | ||
"WATCH_NAMESPACE": "default" | ||
}, | ||
"presentation": { | ||
"hidden": false | ||
} | ||
}, | ||
{ | ||
"name": "Run Contract Generator", | ||
"type": "go", | ||
"request": "launch", | ||
"mode": "auto", | ||
"program": "${workspaceFolder}/contractpkg", | ||
"args": [ | ||
"generate", | ||
"contract_map.json" | ||
] | ||
}, | ||
{ | ||
"name": "Run Temaplte Generator", | ||
"type": "go", | ||
"request": "launch", | ||
"mode": "auto", | ||
"program": "${workspaceFolder}/contractpkg", | ||
"args": [ | ||
"template", | ||
"../config/samples", | ||
"../charts/paladin-operator/templates/samples" | ||
] | ||
}, | ||
{ | ||
"name": "Run Artifacts Generator", | ||
"type": "go", | ||
"request": "launch", | ||
"mode": "auto", | ||
"program": "${workspaceFolder}/contractpkg", | ||
"args": [ | ||
"combine", | ||
"../config/samples", | ||
"generated-crs" | ||
] | ||
} | ||
] | ||
} |
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
Oops, something went wrong.