openbooks icon indicating copy to clipboard operation
openbooks copied to clipboard

Running Docker image missing --name flag

Open GeorgelPreput opened this issue 2 years ago • 7 comments

When deploying and running the Docker image, the application fails and complains about not being given the --name parameter, as in the screenshot below. The Dockerfile indeed runs the application without that parameter:

ENTRYPOINT ["./openbooks", "server", "--dir", "/books", "--port", "80"]

In certain scenarios, such as cloud deployment directly from Docker Hub, it becomes rather convoluted to change this. Two suggestions for mitigation would be:

In the main app:

  • Either also read the name from the environment variables and only throw an error if the env var has also not been set
  • Or provide a default for the --name flag (such as "openbooks", or even generate one on the fly)

Thanks!

image

GeorgelPreput avatar Feb 21 '23 20:02 GeorgelPreput

Same issue here, never happened before though

Kr1sDarnok avatar Mar 01 '23 08:03 Kr1sDarnok

add the flag --name and invent any name and it will connect. Something like this:docker run -p 8080:80 evanbuss/openbooks --name randomcoolnickname

However, as of today I can't figure out what's blocking the connection and preventing the search function to work. I believe it has to do with the TLS or something of sorts.

alfdav avatar Mar 02 '23 15:03 alfdav

Same - using unraid can't push a post-argument, only port path variable label or device...none of which are picked up by the container.

frollard avatar Mar 28 '23 18:03 frollard

I got the same problem, docker run -p 8080:80 evanbuss/openbooks --name randomcoolnickname doesn't help.

Unrepentant-Atheist avatar Jul 23 '23 08:07 Unrepentant-Atheist

same here image didn't help

canedje avatar Dec 24 '23 17:12 canedje

I did find the answer for unraid:

You need to add: image At Post arguments in advanced mode

canedje avatar Dec 24 '23 19:12 canedje

And if anyone is using a Docker Compose file the fix is to add a "command" attribute.

version: "3"
services:
  openbooks:
    container_name: openbooks
    image: evanbuss/openbooks:latest
    environment:
      TZ: America/New_York
    ports:
      - 8071:80
    volumes:
      - /path/to/openbooks:/books    
    command: --name CoolName --persist

etuck avatar Jan 03 '24 15:01 etuck