containers / podman-compose

a script to run docker-compose.yml using podman
GNU General Public License v2.0
5.01k stars 477 forks source link

Error: unknown flag: --env #980

Open rpete3 opened 3 months ago

rpete3 commented 3 months ago

Describe the bug podman-compose is throwing the following error: Error: unknown flag: --env

To Reproduce Steps to reproduce the behavior:

  1. what is the content of the current working directory image
  2. podman-compose build

Expected behavior Build to run. Validated build is working with podman-compose 1.0.6

Actual behavior Error: unknown flag: --env

Output

peterxr3@U-3GxxxxYCN0K9W:~/github/cls-print-rules$ podman-compose build
Error: unknown flag: --env
peterxr3@U-3GxxxxCN0K9W:~/github/cls-print-rules$ podman-compose --version
podman-compose version 1.2.0
podman version 3.4.4
peterxr3@U-3GxxxxCN0K9W:~/github/cls-print-rules$ 

Environment:

Additional context Was working fine until 1.1.0 release, 1.2.0 release does not fix it.

skateman commented 3 months ago

Seems like podman-compose >= 1.1.0 requires a newer version of podman. The issue seems to be with the podman-compose build command forwarding environment variables to the podman build command. I suspect that the installed version of podman is too old and does not support this feature yet.

I am not aware if GH actions allows you to configure the version of podman installed, so you can either: