Hi,
I have a GitHub repository containing a DataMiner Automation Script solution, where the customer also contributes through DIS in Visual Studio. Once a development branch gets merged into the main branch with a pull request, i.e. our development work has completed, tested and functionally approved, the GitHub actions that we have configured on the code repo run some tests in the CI pipeline and, if successful, deploy the full codebase to the dataminer.services-connected DataMiner Agent. It ensures that we have the latest stable and fully tested code on that server.
Unfortunately, there is currently an error occurring during deployment to the server, as shown in the attached screenshot. Could anyone possibly suggest potential reasons for this issue? Any items that I could be checking, as it was successfully working before?
Thanks!
Hi Leander,
When running the build/upload separate from the deploy step, you need to provide the Artifact id that's set as an output parameter from the upload step. There is an example in the documentation on how to do this here. The parts to watch out for here is the setting of the output variable:
Where Build_and_upload_artifact_step is the id of the step where you build and upload the artifact, and then referencing it in the for the deploy step:
Hope this helps!
I’ve made progress with the configuration, and your instructions make complete sense for a public repository. However, since I’m working with a private repo, the workflows have some variations.
The details are described on the following page in the DataMiner docs:
https://docs.dataminer.services/develop/CICD/GitHub/GitHub_Starter_Workflows.html
Another important point is to ensure that a tag is added to the release that corresponds to the workflow. Otherwise, only the CI part of the pipeline will be executed for all validations. The artifact upload and deployment will only take place when the release is tagged.
But all is working fine now. The latest code gets validated and only if all quality gates show green, the artifacts are created and it gets deployed onto the system.
Thanks for the answer, Ruben. I notice that the current main.yml looks quite different, with still references to SonarCloud, etc. Not sure if this is outdated.
I’ll give a try with the upload and deploy actions that you mentioned.