apiVersion: core.oam.dev/v1beta1
kind: Application
metadata:
  name: addon-fluxcd
  namespace: TEST_NAMESPACE
spec:
  components:
    - name: flux-system-namespace
      properties:
        apiVersion: v1
        kind: Namespace
        metadata:
          name: test-addon-namespace
      type: raw
    - name: service
      properties:
        apiVersion: v1
        kind: Service
        metadata:
          name: addon-fluxcd-service
          namespace: test-addon-namespace
        spec:
          ports:
            - name: http
              port: 80
              protocol: TCP
              targetPort: http-webhook
          selector:
            app: notification-controller
          type: ClusterIP
      type: raw
  workflow:
    steps:
      - name: deploy-control-plane
        type: apply-application
      - name: deploy-runtime
        type: deploy2runtime