podman-compose
podman-compose copied to clipboard
git URLs in context in docker-compose.yml
Hello,
Not sure if this is meant to work yet, or not, but one can apparently include git urls in context: in docker compose files:
Either a path to a directory containing a Dockerfile, or a url to a git repository.
https://docs.docker.com/compose/compose-file/compose-file-v2/#build
This isn't working for me. I get:
Traceback (most recent call last):
File "/usr/bin/podman-compose", line 11, in <module>
load_entry_point('podman-compose==0.1.6.dev0', 'console_scripts', 'podman-compose')()
File "/usr/lib/python3.8/site-packages/podman_compose.py", line 1267, in main
podman_compose.run()
File "/usr/lib/python3.8/site-packages/podman_compose.py", line 755, in run
cmd(self, args)
File "/usr/lib/python3.8/site-packages/podman_compose.py", line 939, in wrapped
return func(*args, **kw)
File "/usr/lib/python3.8/site-packages/podman_compose.py", line 1012, in compose_build
build_one(compose, args, cnt)
File "/usr/lib/python3.8/site-packages/podman_compose.py", line 996, in build_one
raise OSError("Dockerfile not found in "+ctx)
OSError: Dockerfile not found in git://github.com/SilverLabUCL/docker-redmine-osb.git
Even if I use https://, it still gives the same error.
my podman version says
The build context directory can be specified as the http(s) URL of an archive, git repository or Containerfile.
would you please try using podman build ... and tell me if the problem is in podman or podman-compose
Sure, I'll have a look and report back. Cheers.
I am getting a similar error message.
Error: error getting image "sundae_server": unable to find a name and tag match for sundae_server in repotags: no such image
Traceback (most recent call last):
File "/usr/bin/podman-compose", line 11, in <module>
load_entry_point('podman-compose==0.1.6.dev0', 'console_scripts', 'podman-compose')()
File "/usr/lib/python3.7/site-packages/podman_compose.py", line 1267, in main
podman_compose.run()
File "/usr/lib/python3.7/site-packages/podman_compose.py", line 755, in run
cmd(self, args)
File "/usr/lib/python3.7/site-packages/podman_compose.py", line 939, in wrapped
return func(*args, **kw)
File "/usr/lib/python3.7/site-packages/podman_compose.py", line 1046, in compose_up
compose.commands['build'](compose, build_args)
File "/usr/lib/python3.7/site-packages/podman_compose.py", line 939, in wrapped
return func(*args, **kw)
File "/usr/lib/python3.7/site-packages/podman_compose.py", line 1012, in compose_build
build_one(compose, args, cnt)
File "/usr/lib/python3.7/site-packages/podman_compose.py", line 996, in build_one
raise OSError("Dockerfile not found in "+ctx)
OSError: Dockerfile not found in https://github.com/prk3/sundae-collab-server.git
My docker-compose.yml contains:
server:
build: https://github.com/prk3/sundae-collab-server.git
podman build works fine:
podman build --tag thingabc:0.1 https://github.com/prk3/sundae-collab-server.git
Same issue here. Looks like local file access is hardcoded.
I'm noticing that this still hasnt been fixed yet in the latest version of docker compose. Is there a PR to fix this yet?