Skip to content

Add wg-easy applicaiton example with helmfile and taskfile flow #39

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

Merged
merged 37 commits into from
Apr 17, 2025

Conversation

chris-sanders
Copy link
Member

@chris-sanders chris-sanders commented Mar 18, 2025

This is not currently ready for merge, but it does demonstrate the folder layout and uses taskfile and helmfile as a pattern separate from umbrella charts.

Issues to address before merge:

  • There are some hard coded values in the taskfile that makes assumptions about application name
  • Reimplement the expose functionality for CMX to at least test/demonstrate TLS working
  • Re-add the SDK as a stand alone chart
    • Test a replicated release on CMX (so the SDK can be used)
  • Look to address duplicate additionalNamesapce in Application with the per-chart settings
  • Look to address duplicate version numbers where HelmChart must match Chart.yaml
  • Add a readme and explain
    • Folder structure
    • Development/test flow
    • Helmfile pattern
    • Taskfile pattern
    • local charts/template pattern
    • Diagrams?

There's more integration to be done with Replicated platform but the above were at least my intentions with this chart before merge. I want to explore this pattern and how the development/release flow works including using CMX to incrementally test with the smallest possible feedback loops.

@chris-sanders chris-sanders requested a review from Copilot March 18, 2025 19:52
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a wg-easy application example along with the necessary helmfile and taskfile flows to demonstrate a development and release pattern. The changes introduce multiple task definitions for cluster management and GCP VM operations, helm chart configurations for cert-manager, traefik, and wg-easy, and a replicated application configuration.

Reviewed Changes

Copilot reviewed 28 out of 29 changed files in this pull request and generated no comments.

Show a summary per file
File Description
applications/wg-easy/taskfiles/utils.yml Adds utility tasks for waiting on cluster status, managing Traefik, exposing ports, and performing GCP operations.
applications/wg-easy/cert-manager/apps/cert-manager.yaml Defines an ArgoCD Application for deploying cert-manager.
applications/wg-easy/cert-manager/replicated/helmChart-cert-manager.yaml Introduces a HelmChart resource for cert-manager.
applications/wg-easy/Taskfile.yaml Implements multiple tasks for creating clusters, managing dependencies, exposing ports, deploying helm charts, and release preparation.
applications/wg-easy/helmfile.yaml Configures helmfile releases with dependencies among cert-manager, traefik, and wg-easy charts.
applications/wg-easy/charts/templates/templates/traefik-routes.yaml Provides IngressRoute and Middleware definitions for Traefik routing.
applications/wg-easy/replicated/application.yaml Adds a replicated application configuration for wg-easy.
Other files Include additional helm charts, values, and configuration files supporting the overall example.
Files not reviewed (1)
  • applications/wg-easy/cert-manager-issuers/templates/issuers.yaml: Language not supported
Comments suppressed due to low confidence (2)

applications/wg-easy/replicated/application.yaml:4

  • The release name 'wgeasy' is inconsistent with the application title 'wg-easy', which may lead to confusion. Align the naming between these fields.
  name: wgeasy

applications/wg-easy/helmfile.yaml:27

  • The dependency reference 'cert-manager/cert-manager' in the 'needs' field for the cert-manager-issuers release does not clearly correspond to an existing release name, leading to potential misconfiguration. Verify that dependency names match the intended release identifiers.
    needs:

@chris-sanders
Copy link
Member Author

Added a GDoc with higher level notes: https://docs.google.com/document/d/1MzmO-e4KvucU5Nu6JPBSRYmkkn12fTV918nfOXkIoIU

@chris-sanders
Copy link
Member Author

@diamonwiggins there have been a few contributions to this branch care to give it a review to see if we're ready to merge this to main and continue working on it from there?

The major issues from the initial intention have been addressed curious if you see anything else that should be mandatory before it's easily discoverable.

feat(wg-easy): add list cluster and Verify kubeconfig for taskfile
@diamonwiggins diamonwiggins marked this pull request as ready for review April 17, 2025 12:25
@@ -0,0 +1,10 @@
name: replicated-sdk
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the primary thing I question is the SDK being a separate chart. What will it actually do if its separate? It'll be there to serve the license API if you want to integrate with it in the future, but you don't get any of the benefit of the monitoring since it can't auto-discover other objects being deployed from the helmrelease.

It's possible to setup statusinformers manually, and actually required in workflows where helm template and kubectl apply is used, but feels like if you're going to take that path, there should be some documentation or a small example on how this application is actually going to integrate with the SDK.

Not saying that has to be on this PR, but yeah.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup it's definitely a to-do for this application. There's really two reason I separated it from this PR.

  1. The upstream chart uses the deprecated Replicated Library Chart, the sdk chart has name conflicts and can't be used as a sub-chart of it.
  2. It was unclear how to deploy and test the SDK without a license so it's just been disabled for now.

I do want to continue with a pattern that doesn't use the SDK as a subchart. I think it's a pattern that should exist to support multi-service applications. I feel like if I have 3+ services deployed having 1 'automatic' and 2 that I manually configure is actually more confusing than just configuring everything.

Copy link
Member

@diamonwiggins diamonwiggins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approval, with a comment

@chris-sanders chris-sanders merged commit 7e9345b into main Apr 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants