Skip to main content
Version: Early Access

FluxCD Delete Application

This workflow completely removes an application managed by FluxCD. It includes removing the application's manifests from the Git repository and deleting its resources from the Kubernetes cluster.

Step 1: Get configuration details

  • Task type: Script Task
  • Description: Retrieves details about the application to be deleted, such as its name, namespace, and associated FluxCD server. These details are often derived from a LiveDeployment CI in Release if the deletion is triggered from there.
  • Properties:
    • Live Deployment ID: ID of the live deployment instance in Release.

Step 2: Application details

  • Task type: User Input Task
  • Description: Confirms or requests the Git repository CI that holds the manifests for the application to be deleted.
  • Properties:
    • Git Repository: Reference to the fluxcd.GitConfig CI.

Step 3: Get application information

  • Task type: FluxCD: Get Application Details
  • Description: Fetches the source and deployment manifest filenames and other application details from FluxCD and Git.
  • Properties:
    • Server: The fluxcd.APIServer CI.
    • Application Name: Name of the application to delete.
    • Namespace: Namespace of the application.

Step 4: Fill application information

  • Task type: Script Task
  • Description: Parses the fetched details (source manifest name, deployment manifest name, and so on) into release variables for use in subsequent deletion tasks.

Step 5: Delete deployment manifest

  • Task type: FluxCD: Delete Application Manifest
  • Description: Deletes the application manifest (such as Kustomization or HelmRelease) from the Git repository and instructs FluxCD to remove the application from the cluster.
  • Properties:
    • Server: The fluxcd.APIServer CI.
    • Git Repository: The fluxcd.GitConfig CI.
    • Manifest Filename: Name of the deployment manifest file to delete from Git.
    • Resource Name: Name of the FluxCD application resource to delete (for example, the application name).
    • Namespace: Namespace of the FluxCD application resource.
    • Kind: Kind of the deployment being deleted (Kustomization or HelmRelease).

Step 6: Delete source manifest

  • Task type: FluxCD: Delete Source Manifest
  • Description: Deletes the source manifest (such as GitRepository or HelmRepository) from the Git repository and instructs FluxCD to remove the source definition.
  • Properties:
    • Server: The fluxcd.APIServer CI.
    • Git Repository: The fluxcd.GitConfig CI.
    • Manifest Filename: Name of the source manifest file to delete from Git.
    • Resource Name: Name of the FluxCD source resource to delete.
    • Namespace: Namespace of the FluxCD source resource.
    • Kind: Kind of the source being deleted.

Step 7: Delete namespace manifest

  • Task type: FluxCD: Delete Namespace Manifest File
  • Description: Deletes the Kubernetes Namespace manifest from the Git repository, if applicable.
note

This task typically does not delete the namespace from the cluster itself unless FluxCD is configured for pruning and the namespace becomes orphaned.

  • Properties:
    • Server: The fluxcd.APIServer CI.
    • Git Repository: The fluxcd.GitConfig CI.
    • Namespace: The namespace whose manifest file is to be deleted.

Step 8: Delete configuration

  • Task type: Script Task
  • Description: Removes any associated fluxcd.DeploymentConfig CI from Digital.ai Release that was monitoring the now-deleted application.