janus-idp / backstage-plugins

Plugins for Backstage
https://janus-idp.io
Apache License 2.0
125 stars 127 forks source link

fix(argocd): hide commit section for helm based applications #1834

Closed karthikjeeyar closed 1 week ago

karthikjeeyar commented 1 week ago

Fixes:

https://issues.redhat.com/browse/RHIDP-2746

Description:

Do not show Commit section for non-gitops application (helm based).

How to test

  1. Create a namespace called test

  2. Create a application using helm charts

    apiVersion: argoproj.io/v1alpha1
    kind: Application
    metadata:
    name: quarkus-app
    labels:
     rht-gitops.com/janus-argocd: quarkus-app
    spec:
    destination:
    namespace: test
    server: https://kubernetes.default.svc
    project: default
    source:
    helm:
      parameters:
        - name: build.enabled
          value: "false"
        - name: deploy.route.enabled
          value: "false"
        - name: image.name
          value: quay.io/redhatworkshops/gitops-helm-quarkus
    chart: quarkus
    repoURL: https://redhat-developer.github.io/redhat-helm-charts
    targetRevision: 0.0.3
    syncPolicy:
    retry:
      backoff:
        duration: 5s
        factor: 2
        maxDuration: 3m0s
      limit: 5
    automated:
      prune: true
      selfHeal: true
    syncOptions:
    - CreateNamespace=true
  3. Add this argocd selector in catalog.info.yaml.

    'argocd/app-selector': rht-gitops.com/janus-argocd=quarkus-app-bootstrap
Screenshot 2024-06-21 at 12 27 00 PM

cc: @rohitkrai03 @invincibleJai

invincibleJai commented 1 week ago

/approve

openshift-ci[bot] commented 1 week ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: invincibleJai, rohitkrai03

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/janus-idp/backstage-plugins/blob/main/OWNERS)~~ [invincibleJai] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment