acl setup error #72

Closed
opened 2025-12-29 09:22:36 +01:00 by adam · 13 comments
Owner

Originally created by @gilbrotheraway on GitHub (May 12, 2025).

I'm getting this when trying to set up geoblocking

05-12 15:20 PNC config load error
                  • slice conversion errors
                    • string to acl.Matcher: unsupported conversion
                    • string to acl.Matcher: unsupported conversion
                    • string to acl.Matcher: unsupported conversion
                  • slice conversion errors
                    • string to acl.Matcher: unsupported conversion
                    • string to acl.Matcher: unsupported conversion
                    • string to acl.Matcher: unsupported conversion
                    • string to acl.Matcher: unsupported conversion
                  • docker: unknown field
                    • Do you mean accesslog?
                
panic: slice conversion errors
	  • string to acl.Matcher: unsupported conversion
	  • string to acl.Matcher: unsupported conversion
	  • string to acl.Matcher: unsupported conversion
	slice conversion errors
	  • string to acl.Matcher: unsupported conversion
	  • string to acl.Matcher: unsupported conversion
	  • string to acl.Matcher: unsupported conversion
	  • string to acl.Matcher: unsupported conversion
	docker: unknown field
	  • Do you mean accesslog?
	
Container stopped

config

acl:
  default: allow # or deny (default: allow)
  allow_local: true # or false (default: true)
  allow:
    - ip:1.2.3.4
    - cidr:1.2.3.4/32
    - country:BR
    - tz:America/SaoPaulo 
  deny:
    - ip:1.2.3.4
    - cidr:1.2.3.4/32
    - country:US
    - tz:Asia/Shanghai
  log: # warning: logging ACL can be slow based on the number of inc>
    buffer_size: 65536 # (default: 64KB)
    path: /app/logs/acl.log # (default: none)
    stdout: false # (default: false)
    keep: last 10 # (default: none)
providers:
  maxmind:
    account_id: ****
    license_key: ****
    database: geolite
Originally created by @gilbrotheraway on GitHub (May 12, 2025). I'm getting this when trying to set up geoblocking ``` 05-12 15:20 PNC config load error • slice conversion errors • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • slice conversion errors • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • docker: unknown field • Do you mean accesslog? panic: slice conversion errors • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion slice conversion errors • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion • string to acl.Matcher: unsupported conversion docker: unknown field • Do you mean accesslog? Container stopped ``` config ``` acl: default: allow # or deny (default: allow) allow_local: true # or false (default: true) allow: - ip:1.2.3.4 - cidr:1.2.3.4/32 - country:BR - tz:America/SaoPaulo deny: - ip:1.2.3.4 - cidr:1.2.3.4/32 - country:US - tz:Asia/Shanghai log: # warning: logging ACL can be slow based on the number of inc> buffer_size: 65536 # (default: 64KB) path: /app/logs/acl.log # (default: none) stdout: false # (default: false) keep: last 10 # (default: none) providers: maxmind: account_id: **** license_key: **** database: geolite ```
adam closed this issue 2025-12-29 09:22:36 +01:00
Author
Owner

@yusing commented on GitHub (May 13, 2025):

The config you posted doesn't match the errors listed above. Could you show me the full config (with secrets redacted)?

@yusing commented on GitHub (May 13, 2025): The config you posted doesn't match the errors listed above. Could you show me the full config (with secrets redacted)?
Author
Owner

@SuperSuave commented on GitHub (May 13, 2025):

I actually have the same exact issue. It pops up as soon as I try adding the "allow" key underneath "default: deny/allow"

Here's my full config

autocert:
  provider: cloudflare
  email: email@domain.com
  domains:
    - "*.domain.com"
    - domain.com
    - "*.inside.domain.com"
  options:
    auth_token: supersecrettoken
entrypoint:
  middlewares:
    - use: real_ip
      header: X-Real-IP
      from:
        - 127.0.0.1
        - 192.168.0.0/16
        - 10.0.0.0/8
      recursive: true
providers:
  docker:
    local!: $DOCKER_HOST
  include:
    - nextcloud.yml
    - privacy-terms.yml
  maxmind:
    account_id: 123456
    license_key: supersecretkey
    database: geolite
match_domains:
  - domain.com
homepage:
  use_default_categories: true
timeout_shutdown: 5
acl:
  default: deny
  allow:
    - country:US
@SuperSuave commented on GitHub (May 13, 2025): I actually have the same exact issue. It pops up as soon as I try adding the "allow" key underneath "default: deny/allow" Here's my full config ```yaml autocert: provider: cloudflare email: email@domain.com domains: - "*.domain.com" - domain.com - "*.inside.domain.com" options: auth_token: supersecrettoken entrypoint: middlewares: - use: real_ip header: X-Real-IP from: - 127.0.0.1 - 192.168.0.0/16 - 10.0.0.0/8 recursive: true providers: docker: local!: $DOCKER_HOST include: - nextcloud.yml - privacy-terms.yml maxmind: account_id: 123456 license_key: supersecretkey database: geolite match_domains: - domain.com homepage: use_default_categories: true timeout_shutdown: 5 acl: default: deny allow: - country:US ```
Author
Owner

@yusing commented on GitHub (May 13, 2025):

Hi, I'll test for this when I'm off work today

@yusing commented on GitHub (May 13, 2025): Hi, I'll test for this when I'm off work today
Author
Owner

@yusing commented on GitHub (May 13, 2025):

@SuperSuave @Fuckingnameless Fixed

@yusing commented on GitHub (May 13, 2025): @SuperSuave @Fuckingnameless Fixed
Author
Owner

@SuperSuave commented on GitHub (May 13, 2025):

Hi @yusing, that specific problem is fixed, but now when I add in the allow key, I get an error that MaxMind isn't configured:

godoxy | 05-13 09:12 FTL config load error
godoxy | • acl > allow > [0]: MaxMind not configured
godoxy |
godoxy exited with code 1

However, once I remove that key, the logs show that maxmind is working:

godoxy | 05-13 09:10 INF MaxMind DB is up to date database=geolite
godoxy | 05-13 09:10 INF server started addr=127.0.0.1:8888 proto=http server=api

@SuperSuave commented on GitHub (May 13, 2025): Hi @yusing, that specific problem is fixed, but now when I add in the allow key, I get an error that MaxMind isn't configured: godoxy | 05-13 09:12 FTL config load error godoxy | • acl > allow > [0]: MaxMind not configured godoxy | godoxy exited with code 1 However, once I remove that key, the logs show that maxmind is working: godoxy | 05-13 09:10 INF MaxMind DB is up to date database=geolite godoxy | 05-13 09:10 INF server started addr=127.0.0.1:8888 proto=http server=api
Author
Owner

@gilbrotheraway commented on GitHub (May 14, 2025):

same here

Hi @yusing, that specific problem is fixed, but now when I add in the allow key, I get an error that MaxMind isn't configured:

godoxy | 05-13 09:12 FTL config load error godoxy | • acl > allow > [0]: MaxMind not configured godoxy | godoxy exited with code 1

However, once I remove that key, the logs show that maxmind is working:

godoxy | 05-13 09:10 INF MaxMind DB is up to date database=geolite godoxy | 05-13 09:10 INF server started addr=127.0.0.1:8888 proto=http server=api

panic: acl > allow > [0]: MaxMind not configured
entrypoint > docker: unknown field
• Do you mean accesslog?

@gilbrotheraway commented on GitHub (May 14, 2025): same here > Hi [@yusing](https://github.com/yusing), that specific problem is fixed, but now when I add in the allow key, I get an error that MaxMind isn't configured: > > godoxy | 05-13 09:12 FTL config load error godoxy | • acl > allow > [0]: MaxMind not configured godoxy | godoxy exited with code 1 > > However, once I remove that key, the logs show that maxmind is working: > > godoxy | 05-13 09:10 INF MaxMind DB is up to date database=geolite godoxy | 05-13 09:10 INF server started addr=127.0.0.1:8888 proto=http server=api panic: acl > allow > [0]: MaxMind not configured entrypoint > docker: unknown field • Do you mean accesslog?
Author
Owner

@yusing commented on GitHub (May 14, 2025):

Maxmind credentials are required for "country" and "city" matching 😅.

@Fuckingnameless "docker" is under providers, not entrypoint

@yusing commented on GitHub (May 14, 2025): Maxmind credentials are required for "country" and "city" matching 😅. @Fuckingnameless "docker" is under providers, not entrypoint
Author
Owner

@yusing commented on GitHub (May 14, 2025):

https://docs.godoxy.dev/Access-Control

@yusing commented on GitHub (May 14, 2025): https://docs.godoxy.dev/Access-Control
Author
Owner

@SuperSuave commented on GitHub (May 14, 2025):

Maxmind credentials are required for "country" and "city" matching 😅.

@yusing I have MaxMind credentials in my config under the "Providers" key(see in my config above), are they supposed to go somewhere else too?

@SuperSuave commented on GitHub (May 14, 2025): > Maxmind credentials are required for "country" and "city" matching 😅. > @yusing I have MaxMind credentials in my config under the "Providers" key(see in my config above), are they supposed to go somewhere else too?
Author
Owner

@yusing commented on GitHub (May 14, 2025):

@SuperSuave @Fuckingnameless fixed too, please pull and try again

@yusing commented on GitHub (May 14, 2025): @SuperSuave @Fuckingnameless fixed too, please pull and try again
Author
Owner

@gilbrotheraway commented on GitHub (May 15, 2025):

@SuperSuave @Fuckingnameless fixed too, please pull and try again

now i get:

05-15 00:32 PNC config load error
                  • entrypoint > docker: unknown field
                    • Do you mean accesslog?
                
panic: entrypoint > docker: unknown field
	  • Do you mean accesslog?
	
Container stopped
@gilbrotheraway commented on GitHub (May 15, 2025): > [@SuperSuave](https://github.com/SuperSuave) [@Fuckingnameless](https://github.com/Fuckingnameless) fixed too, please pull and try again now i get: ``` 05-15 00:32 PNC config load error • entrypoint > docker: unknown field • Do you mean accesslog? panic: entrypoint > docker: unknown field • Do you mean accesslog? Container stopped ```
Author
Owner

@yusing commented on GitHub (May 15, 2025):

Maxmind credentials are required for "country" and "city" matching 😅.

@Fuckingnameless "docker" is under providers, not entrypoint

@Fuckingnameless

@yusing commented on GitHub (May 15, 2025): > Maxmind credentials are required for "country" and "city" matching 😅. > > @Fuckingnameless "docker" is under providers, not entrypoint @Fuckingnameless
Author
Owner

@gilbrotheraway commented on GitHub (May 15, 2025):

Maxmind credentials are required for "country" and "city" matching 😅.
@Fuckingnameless "docker" is under providers, not entrypoint

@Fuckingnameless

it was under providers but i had 2 providers directives because i just copied the ACL example from docs, now I'm able to get the container running, only issue remaining is https://github.com/yusing/godoxy/issues/108

@gilbrotheraway commented on GitHub (May 15, 2025): > > Maxmind credentials are required for "country" and "city" matching 😅. > > [@Fuckingnameless](https://github.com/Fuckingnameless) "docker" is under providers, not entrypoint > > [@Fuckingnameless](https://github.com/Fuckingnameless) it was under providers but i had 2 providers directives because i just copied the ACL example from docs, now I'm able to get the container running, only issue remaining is https://github.com/yusing/godoxy/issues/108
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/godoxy#72