Closed nikola-rados closed 3 years ago
I see what you're doing, and it seems reasonable enough, but maybe unnecessary?
What are your concerns with the gitpython
solution? My own would be:
But a bigger question is:
docker-publish
action pulls the repo, so there is a .git
directory in the larger context. And the original way this was done was that git_commitish
was a shell script (so with access to .git
, right?) whose value is passed in to the docker build as a build arg. You set something equivalent up in Plan2Adapt. I see that it's a trifle tricky, but obvious enough. Is that not an option here?Asides:
gitpython
as a dependency in setup.py.
Was that intentional? Perhaps it would be a bit circular, or at least cart-before-horse there?@nikola-rados : Not a big deal, but I have an interest in PDP: What do you make of the alternative (maybe cleaner) method that I noted is used in P2A and elsewehere?
@nikola-rados , it looks like this PR was never merged. I think whatever else is done we still need a .dockerignore
, but we don't have one in the master branch.
Oh sorry, I lost your comments in my ocean of emails.
I think the alternative is the way to go. I'll restore the branch and see if I can get things working.
There is a small issue with
get_commitish()
when we apply a.dockerignore
file. Since we remove the.git
from the build context there is no git info for the method to pull. I have put a bandaid on it for the moment, but I would like to discuss other options.Resolves #185.