metadata:
  name: abapAddonAssemblyKitCreateTargetVector
  description: This step creates a Target Vector for software lifecycle operations
  longDescription: |
    This step takes the Product Version and the corresponding list of Software Component Versions from the addonDescriptor in the commonPipelineEnvironment.
    With these it creates a Target Vector, which is necessary for executing software lifecylce operations in ABAP Cloud Platform systems.
    The Target Vector describes the software state, which shall be reached in the managed ABAP Cloud Platform system.
    <br />
    For Terminology refer to the [Scenario Description](https://www.project-piper.io/scenarios/abapEnvironmentAddons/).
spec:
  inputs:
    secrets:
      - name: abapAddonAssemblyKitCredentialsId
        description: Credential stored in Jenkins for the Addon Assembly Kit as a Service (AAKaaS) system
        type: jenkins
    params:
      - name: abapAddonAssemblyKitEndpoint
        type: string
        description: Base URL to the Addon Assembly Kit as a Service (AAKaaS) system
        scope:
          - PARAMETERS
          - STAGES
          - STEPS
          - GENERAL
        mandatory: true
        default: https://apps.support.sap.com
      - name: username
        type: string
        description: User for the Addon Assembly Kit as a Service (AAKaaS) system
        scope:
          - PARAMETERS
          - STAGES
          - STEPS
        mandatory: true
        secret: true
      - name: password
        type: string
        description: Password for the Addon Assembly Kit as a Service (AAKaaS) system
        scope:
          - PARAMETERS
        mandatory: true
        secret: true
      - name: addonDescriptor
        type: string
        description: Structure in the commonPipelineEnvironment containing information about the Product Version and corresponding Software Component Versions
        mandatory: true
        scope:
          - PARAMETERS
          - STAGES
          - STEPS
        resourceRef:
          - name: commonPipelineEnvironment
            param: abap/addonDescriptor
  outputs:
    resources:
      - name: commonPipelineEnvironment
        type: piperEnvironment
        params:
          - name: abap/addonDescriptor
