HodorNV / ALOps

ALOps
56 stars 24 forks source link

Filter nav_artifact_app_filter on ALOps App Publish not working? #653

Closed peterz84 closed 1 year ago

peterz84 commented 1 year ago

Describe the bug We have a filter on the apps to publish in our yaml, but it seems to be ignored. Is the filter incorrect?

the used yaml

        - task: ALOpsAppPublish@1
          displayName: 'ALOps App Publish'
          inputs:
            nav_serverinstance: 'BC220'
            nav_artifact_app_filter: 'X Solutions_DMA *.app'
            batch_publish_folder: '$(Pipeline.Workspace)/Products'

part of the output

name                                                                                                              value
----                                                                                                              -----
usedocker                                                                                                         False
fixed_tag                                                                                                              
installpublishedapps                                                                                               True
installaltesttool                                                                                                 False
install_al_app_names                                                                             Tests-TestLibraries...
strictappnames                                                                                                    False
nav_serverinstance                                                                                                BC220
artifact_path                                                                                                          
nav_artifact_app_filter                                                                           X Solutions_DMA *.app
skip_verification                                                                                                  True
forceinstall                                                                                                      False
forcesync                                                                                                         False
publish_scope                                                                                                    Global
tenant                                                                                                          default
batch_publish_folder                                                                     C:\azagent\A1\_work\1/Products
publisherazureactivedirectorytenantid                                                                                  
blocksymbolsonly                                                                                                  False

*** For documentation, please visit   : https://www.alops.be/documentation

*** ALOps License:
  * Licensed To: X Solutions (Collection License)

*** Importing required PS-Functions
*** Start Batch App-Publish.
*** Import NAV/BC Management DLL's [False]
*** Loading assemblies for ServiceTier [BC220].
*** Loading assemblies from: [C:\program files\microsoft dynamics 365 business central\220\service]
*** Selected module: [C:\program files\microsoft dynamics 365 business central\220\service\Management\Microsoft.Dynamics.Nav.Management.dll]
*** Loading module: [C:\program files\microsoft dynamics 365 business central\220\service\Management\Microsoft.Dynamics.Nav.Management.dll]
*** Selected module: [C:\program files\microsoft dynamics 365 business central\220\service\Management\Microsoft.Dynamics.Nav.Apps.Management.dll]
*** Loading module: [C:\program files\microsoft dynamics 365 business central\220\service\Management\Microsoft.Dynamics.Nav.Apps.Management.dll]
*** Get Available Applications from [C:\azagent\A1\_work\1/Products].
*** Get [*.app] files recursive from [C:\azagent\A1\_work\1/Products]
*** Found [31] files.
*** Extract App detail from [C:\azagent\A1\_work\1\Products\X Solutions_DEV Tools_22.1.0.43052.app]
*** Extract App detail from [C:\azagent\A1\_work\1\Products\X Solutions_DEV Upgrade_22.1.0.43052.app]
*** Extract App detail from [C:\azagent\A1\_work\1\Products\X Solutions_DMA Declaration-Medical Device_22.1.0.43052.app]
*** Extract App detail from [C:\azagent\A1\_work\1\Products\X Solutions_DMA Declaration-Stockings_22.1.0.43052.app]
*** Extract App detail from [C:\azagent\A1\_work\1\Products\X Solutions_DMA Declaration-Usage Item_22.1.0.43052.app]

Expected behavior I expect the _DEV Tools and _DEV Upgrade app not to be published

waldo1001 commented 1 year ago

Same answer as you posed here, I'm afraid: https://github.com/HodorNV/ALOps/issues/489

If you don't want to publish all apps, it's best you create folders, copy your apps into the folders and publish all apps from that folder. It gives you all flexibility you need!

peterz84 commented 1 year ago

Arghhh, totally forgot about that one. Different company, same problem. So the solution is to put the apps in different folders in the build proces right?

waldo1001 commented 1 year ago

Yeah, I'm afraid so. We gave it multiple tries, but ultimately always roll back to the "folder" solution, as this gives all the flexibility every single scenario...