Copy of a Gitlab folder when provisioning

Is there a possibility during the deployment of a Windows VM to copy a specific folder of an existing Gitlab integration via Morpheus to the new system or to download it via Morpheus? We deliberately do not want to use the “Deploy” function, because this is still about the configuration of the VM and not about the installation of an application that should be displayed in the overview via a version or something similar.

Hi Marvin
You would have to do this via a provisioning workflow and task in Morpheus. The task would need to call the gitlab API to do the copy from your gitlab project to the VM during provisioning.

However, looking at the gitlab API documentation, you only seem to be able to copy a single file via the API - Repository files API | GitLab. So you would need to run an API call to copy each file in the directory.

From within Morpheus, once you have integrated a gitlab repo, you can view the contents of a gitlab repo via Provisioning - Code - Repositories. If you click on the drop down next to one of your gitlab files, you can create a TF spec template, shell task or PowerShell task. But you’re not able to copy or download a specific folder from the repo to a VM during provisioning.

Pete

Could you do a sparse checkout of the repo (just for the required folder) to somewhere temporarily, then move that folder to the destination and clean up the local temporary git repo after?

Thanks for the suggestions and ideas so far!

Currently we are taking the approach of uploading files we need during deployment to the Morpheus archive and downloading them in a provisioning task. However, with this approach we have to re-upload files every time we make a change.
As storage target for the Morpheus archive we use a SMB share. Is there an easy way to synchronize the content of the share with the archive? I noticed that files that are manually copied to the share do not show up in the Morpheus archive.
We could easily keep the share in sync with the gitlab project.

Many greetings
Marvin