Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

script acme error false integer expression expected #1017

Closed
genestouxguy opened this issue Mar 27, 2023 · 4 comments
Closed

script acme error false integer expression expected #1017

genestouxguy opened this issue Mar 27, 2023 · 4 comments

Comments

@genestouxguy
Copy link

If your are using the latest image tag and recently updated your image: please make sure you've checked the required read on the project's README.

HTTPS does not work / certificate aren't created : please check in your acme-companion container logs if an authorization or verify error is mentioned, if it is please do the following before opening an issue:

  • check and follow the troubleshooting instructions in the docs.
  • search the existing similar issues, both opened and closed.

Bug description

The certificats generated are ok but in the log of this container, i got many error false: integer expression expected :

...
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 394: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 361: [: false: integer expression expected
/app/acme.sh: line 327: [: false: integer expression expected
...

Am I alone to get these errors ? I don't understand why the DEBUG variable is not an integer ???

acme-companion image version

Please provide the container version that should be printed to the first line of log at container startup:

Info: running acme-companion version v2.2.6

Docker host

  • OS: Ubuntu 22.04
  • Docker version: output of
 - Client: Docker Engine - Community
 Version:           23.0.1
 API version:       1.42
 Go version:        go1.19.5
 Git commit:        a5ee5b1
 Built:             Thu Feb  9 19:47:01 2023
 OS/Arch:           linux/amd64
 Context:           default

Server: Docker Engine - Community
 Engine:
  Version:          23.0.1
  API version:      1.42 (minimum version 1.12)
  Go version:       go1.19.5
  Git commit:       bc3805a
  Built:            Thu Feb  9 19:47:01 2023
  OS/Arch:          linux/amd64
  Experimental:     false
 containerd:
  Version:          1.6.18
  GitCommit:        2456e983eb9e37e47538f59ea18f2043c9a73640
 runc:
  Version:          1.1.4
  GitCommit:        v1.1.4-0-g5fd4c4d
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0

I didn't post all my docker-compose.yml because I don't think a link exist but if you really want it, tell me.

Thanks for your answer!

@buchdag
Copy link
Member

buchdag commented Mar 27, 2023

Hi, could you provide the container configuration (ie full compose file, docker run command, etc) ?

@genestouxguy
Copy link
Author

Hi,

Sure!

version: '3.9'

services:
  portail:
    image: nginx:alpine
    container_name: nginx
    restart: unless-stopped
    logging:
        driver: "json-file"
        options:
            max-size: "4m"
            max-file: "10"
    volumes:
      - porte_conf:/etc/nginx/conf.d:ro
      - porte_htpasswd:/etc/nginx/htpasswd:ro
      - porte_vhost:/etc/nginx/vhost.d:ro
      - porte_html:/usr/share/nginx/html:ro
      - certif_certs:/etc/nginx/certs:ro
    ports:
      - 80:80
      - 443:443
    networks:
      - net-front
      - net-back
    labels:
      com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy: 'true'

  docker-gen:
    image: nginxproxy/docker-gen:0.10.1
    restart: unless-stopped
    logging:
        driver: "json-file"
        options:
            max-size: "200k"
            max-file: "10"
    depends_on:
      - portail
    container_name: reverseproxy_gen
    volumes:
      - /var/run/docker.sock:/tmp/docker.sock:ro
      - certif_certs:/etc/nginx/certs:ro
      - porte_conf:/etc/nginx/conf.d:rw
      - porte_html:/usr/share/nginx/html:rw
      - porte_htpasswd:/etc/nginx/htpasswd:ro
      - porte_templates:/etc/docker-gen/templates:ro
      - porte_vhost:/etc/nginx/vhost.d:ro
    command: -notify-sighup nginx -watch -only-exposed -wait 5s:30s /etc/docker-gen/templates/nginx.tmpl /etc/nginx/conf.d/default.conf
    labels:
      com.github.jrcs.letsencrypt_nginx_proxy_companion.docker_gen: 'true'
    networks:
      - net-back

  certif:
    image: nginxproxy/acme-companion:2.2.6
    container_name: reverseproxy_certif
    restart: unless-stopped
    logging:
        driver: "json-file"
        options:
            max-size: "200k"
            max-file: "10"
    depends_on:
      - docker-gen
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock:ro
      - certif_certs:/etc/nginx/certs:rw
      - porte_conf:/etc/nginx/conf.d:ro
      - porte_html:/usr/share/nginx/html:ro
      - porte_vhost:/etc/nginx/vhost.d:ro
    networks:
      - net-back
    environment:
      NGINX_PROXY_CONTAINER: 'nginx'
      NGINX_DOCKER_GEN_CONTAINER: 'reverseproxy_gen'
      DEBUG: 'false'
  vim:
    image: disp/vim
    tty: true
    command: bash
    volumes:
      - porte_conf:/etc/nginx/conf.d:rw
      - porte_html:/usr/share/nginx/html:rw
      - porte_htpasswd:/etc/nginx/htpasswd:rw
      - porte_templates:/etc/docker-gen/templates:rw
      - porte_vhost:/etc/nginx/vhost.d:rw
    networks:
      - net-front
    

networks:
  net-front:
    external: true
    name: net-reverseproxy
  net-back:
    driver: bridge

volumes:
  certif_certs:
  porte_conf:
  porte_html:
  porte_htpasswd:
  porte_templates:
  porte_vhost:

And I just use docker compose up -d.

@buchdag
Copy link
Member

buchdag commented Mar 31, 2023

Since version 2.0.0, DEBUG: 'false' / DEBUG: 'true' is incorrect. Please use DEBUG: 0 / DEBUG: 1 instead.

More information here and on the relevant doc.

Also a general recommendation about using the latest tag: don't.

General advice about latest

Do not use the latest tag for production setups.

latest is nothing more than a convenient default used by Docker if no specific tag is provided, there isn't any strict convention on what goes into this tag over different projects, and it does not carry any promise of stability.

Using latest will most certainly put you at risk of experiencing uncontrolled updates to non backward compatible versions (or versions with breaking changes) and makes it harder for maintainers to track which exact version of the container you are experiencing an issue with.

This recommendation stands for pretty much every Docker image in existence, not just nginx-proxy's ones.

@buchdag buchdag closed this as completed Mar 31, 2023
@genestouxguy
Copy link
Author

Thanks! And sorry because I didn't see this line.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants