Hi all. This is regarding the "process of using a ...
# pactflow
p
Hi all. This is regarding the "process of using a dockerfile to bake the lic file into the pactflow image". I was able to do it in my local, but now I want to automate the whole process. I have written a job in gitlab. (See attached ss) I am facing 2 issues here. 1. docker tag command (2nd line in script section of job) 2. docker build command (5nd line in script section of job) For 1. I am able to run this command locally and push to harbor. But when I am doing that from gitlab, I am getting error saying "docker tag requires exactly 2 arguments" For 2. I commented the first three lines, and directly pulled existing image from Harbor (one without lic file) and tried to bake in the file and push it back to harbor with tag = baselic But when I do that, in Harbor I am not seeing the lic file which I was seeing when I did it from local. (See harbor ss) Image marked as 1 = via cicd (no folder icon next to it) Image marked as 2 = via local (shows folder icon next to it denoting that lic file baked in successfully)
m
Hi Prakhar, this is a bit harder for us to help I’m afraid. If it works in local, but not in CI that is likely to indicate differences between the setups, and that will be hard for us to diagnose without access to your Gitlab environment.
“docker tag requires exactly 2 arguments”
this can happen if you’re using variables as argument, but those variables aren’t set on the runner. It can also happen due to incorrect escaping
and tried to bake in the file and push it back to harbor with tag = baselic
But when I do that, in Harbor I am not seeing the lic file which I was seeing when I did it from local. (See harbor ss)
This sounds like you might not be properly mounting the license file into the right place for it to be available in the script
I think it best you pair with somebody on your team who has done similar work before so that you can get their advice/knowledge of the particular challenges in your CI environment
👍 1
p
@Matt (pactflow.io / pact-js / pact-go) Valid point. I will check with someone within my org
👍 1