HodorNV / ALOps

ALOps
59 stars 24 forks source link

ALOps Extension API: Cant find artifact filter #582

Closed NAVFreak closed 2 years ago

NAVFreak commented 2 years ago

Describe the bug I have done a release pipeline with ALOps Extension API but the problem is that it tries to deploy all my apps from pipeline, even my testapps which isn't ok. When I read the manual it says there exist artifact filter:

        - task: ALOpsExtensionAPI@1
        displayName: 'ALOps Extension API'
      inputs:
        usedocker: False                      # Run task in Docker container. $(usedocker)
        fixed_tag:                            # Allows recycling of docker containers. $(fixed_tag)
        ...
        artifact_path: $(System.ArtifactsDirectory)# Path for App Artifact. $(artifact_path)
        **artifact_filter: *.app                # Filter used for locating App file relative to $(path_to_publish). $(artifact_filter)**

But I can't find/see the artifact filter in the GUI (taskversion 1.*): image

the used yaml please provide the yaml that you used. It helps you put the yaml like this:

steps:
- task: Hodor.hodor-alops.ALOpsExtensionAPI.ALOpsExtensionAPI@1
  displayName: 'ALOps Extension API'
  inputs:
    interaction: batch
    api_endpoint: 'https://api-XXXXX.com:7048/BC200/api'
    authentication: XXXX
    azure_tenant_id: default
    username: XXX
    password: 'XXX

Expected behavior Be able to specify artifact filter in the configuraton of the release pipeline

waldo1001 commented 2 years ago

A batch publish doesn't take the artifact filter into account. The problem with that parameter is the intent and how powershell works :(. We can't really do it properly. The artifact-filter is to publish one app out of a list, and the filter will make sure you take the right app..

Here's how to delete all test-apps before the publish: https://github.com/HodorNV/ALOps/issues/289

waldo1001 commented 2 years ago

ONe other tip.

It might make sense to put apps in different folders, and in the batch deploy, refer to a certain folder to exclude the apps in the other folders.. .

We'll close this issue for now.