octavius64 / Gazelle

Other
0 stars 0 forks source link

secrets: line 7: g3nq4c78: command not found #1

Closed dannymichel closed 1 year ago

dannymichel commented 1 year ago

I'm getting the error secrets: line 7: g3nq4c78: command not found

octavius64 commented 1 year ago

Hey, the docker_compose.sh script simply "sources" the secrets file to read the key-value pairs. Make sure there is no space between the key value pairs because bash doesn't like any spaces. If it still doesn't work, can you please dump the contents of your secrets file here?

dannymichel commented 1 year ago

Just to be sure, I used your secrets file with the defaults and it ran but i got

sudo ./docker_compose.sh build
unknown flag: --project-name
See 'docker --help'.
octavius64 commented 1 year ago

Do you have docker compose installed? What does docker compose --version print?

dannymichel commented 1 year ago

docker compose --version

Docker version 20.10.8, build 3967b7d

octavius64 commented 1 year ago

Can you also please run docker compose --help and make sure --project-name is a valid argument in the help text?

This is the output on my machine:

docker compose --help

Usage:  docker compose [OPTIONS] COMMAND

Docker Compose

Options:
      --ansi string                Control when to print ANSI control characters ("never"|"always"|"auto") (default "auto")
      --compatibility              Run compose in backward compatibility mode
      --env-file string            Specify an alternate environment file.
  -f, --file stringArray           Compose configuration files
      --parallel int               Control max parallelism, -1 for unlimited (default -1)
      --profile stringArray        Specify a profile to enable
      --project-directory string   Specify an alternate working directory
                                   (default: the path of the, first specified, Compose file)
  -p, --project-name string        Project name
dannymichel commented 1 year ago
➜  docker git:(main) docker compose --version
Docker version 20.10.8, build 3967b7d
➜  docker git:(main) docker-compose --version
docker-compose version 1.25.3, build d4d1b42b
➜  docker git:(main) 
octavius64 commented 1 year ago

I see, looks like you have docker-compose on your machine, which is a separate binary. Can you edit the last line of docker_compose.sh?

Old:

exec docker compose --project-name gazelle -f docker-compose.yml "$@"

New:

exec docker-compose --project-name gazelle -f docker-compose.yml "$@"
dannymichel commented 1 year ago

I see, looks like you have docker-compose on your machine, which is a separate binary. Can you edit the last line of docker_compose.sh?

Old:

exec docker compose --project-name gazelle -f docker-compose.yml "$@"

New:

exec docker-compose --project-name gazelle -f docker-compose.yml "$@"

That worked