dokku-mongo: mongo:create - MongoServerError: Authentication failed
Description of problem
Fresh Dokku install in Docker container. Just try to create new app and new service. It gives this:
ubuntu@arm1:~/traefik-proxy/apps/dokku$ dokku mongo:create mern-boilerplate-database
Waiting for container to be ready
MongoServerError: Authentication failed.
# container logs
t={"$date":"2023-03-05T08:27:58.138+00:00"} s=I c=ACCESS id=20249 ctx=conn3 msg=Authentication failed attr={"mechanism":"SCRAM-SHA-256","speculative":true,"principalName":"admin","authenticationDatabase":"admin","remote":"127.0.0.1:45700","extraInfo":{},"error":"AuthenticationFailed: SCRAM authentication failed, storedKey mismatch"}
Later I get exact same error when app tries to connect to mongo service.
How reproducible
Steps to Reproduce
dokku network:set --global initial-network dokku-external
dokku apps:create mern-boilerplate
dokku mongo:create mern-boilerplate-database
Waiting for container to be ready
MongoServerError: Authentication failed.
Actual Results
Auth error.
Expected Results
Should connect to database. No error output on service creation.
Environment Information
dokku report APP_NAME
output
App is not needed, it happens on service creation even without any apps.
ubuntu@arm1:~/traefik-proxy/apps/dokku$ dokku report mern-boilerplate
-----> uname: Linux fc7fea5c9a9d 5.15.0-1029-oracle #35-Ubuntu SMP Tue Jan 24 15:21:05 UTC 2023 aarch64 aarch64 aarch64 GNU/Linux
-----> memory:
total used free shared buff/cache available
Mem: 11940 515 4692 4 6732 11193
Swap: 0 0 0
-----> docker version:
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:46:32 2023
OS/Arch: linux/arm64
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:46:30 2023
OS/Arch: linux/arm64
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
-----> docker daemon info:
Client:
Context: default
Debug Mode: true
Plugins:
compose: Docker Compose (Docker Inc.)
Version: v2.16.0
Path: /usr/libexec/docker/cli-plugins/docker-compose
Server:
Containers: 6
Running: 4
Paused: 0
Stopped: 2
Images: 17
Server Version: 23.0.1
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Using metacopy: false
Native Overlay Diff: true
userxattr: false
Logging Driver: json-file
Cgroup Driver: systemd
Cgroup Version: 2
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: io.containerd.runc.v2 runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 2456e983eb9e37e47538f59ea18f2043c9a73640
runc version: v1.1.4-0-g5fd4c4d
init version: de40ad0
Security Options:
apparmor
seccomp
Profile: builtin
cgroupns
Kernel Version: 5.15.0-1029-oracle
Operating System: Ubuntu 22.04.2 LTS
OSType: linux
Architecture: aarch64
CPUs: 2
Total Memory: 11.66GiB
Name: arm1
ID: 91a59387-ea2d-472e-888c-e9327bf5feba
Docker Root Dir: /var/lib/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
-----> git version: git version 2.25.1
-----> sigil version: 0.9.0build+bc921b7
-----> herokuish version:
! herokuish not supported on arm64 architecture
-----> dokku version: dokku version 0.30.1
-----> plugn version: plugn: 0.12.0build+3a27594
-----> dokku plugins:
00_dokku-standard 0.30.1 enabled dokku core standard plugin
20_events 0.30.1 enabled dokku core events logging plugin
app-json 0.30.1 enabled dokku core app-json plugin
apps 0.30.1 enabled dokku core apps plugin
builder 0.30.1 enabled dokku core builder plugin
builder-dockerfile 0.30.1 enabled dokku core builder-dockerfile plugin
builder-herokuish 0.30.1 enabled dokku core builder-herokuish plugin
builder-lambda 0.30.1 enabled dokku core builder-lambda plugin
builder-null 0.30.1 enabled dokku core builder-null plugin
builder-pack 0.30.1 enabled dokku core builder-pack plugin
buildpacks 0.30.1 enabled dokku core buildpacks plugin
caddy-vhosts 0.30.1 enabled dokku core caddy-vhosts plugin
certs 0.30.1 enabled dokku core certificate management plugin
checks 0.30.1 enabled dokku core checks plugin
common 0.30.1 enabled dokku core common plugin
config 0.30.1 enabled dokku core config plugin
cron 0.30.1 enabled dokku core cron plugin
docker-options 0.30.1 enabled dokku core docker-options plugin
domains 0.30.1 enabled dokku core domains plugin
enter 0.30.1 enabled dokku core enter plugin
git 0.30.1 enabled dokku core git plugin
haproxy-vhosts 0.30.1 enabled dokku core haproxy-vhosts plugin
letsencrypt 0.20.0 enabled Automated installation of let's encrypt TLS certificates
logs 0.30.1 enabled dokku core logs plugin
mongo 1.32.0 enabled dokku mongo service plugin
network 0.30.1 enabled dokku core network plugin
nginx-vhosts 0.30.1 enabled dokku core nginx-vhosts plugin
plugin 0.30.1 enabled dokku core plugin plugin
postgres 1.32.0 enabled dokku postgres service plugin
proxy 0.30.1 enabled dokku core proxy plugin
ps 0.30.1 enabled dokku core ps plugin
registry 0.30.1 enabled dokku core registry plugin
repo 0.30.1 enabled dokku core repo plugin
resource 0.30.1 enabled dokku core resource plugin
run 0.30.1 enabled dokku core run plugin
scheduler 0.30.1 enabled dokku core scheduler plugin
scheduler-docker-local 0.30.1 enabled dokku core scheduler-docker-local plugin
scheduler-null 0.30.1 enabled dokku core scheduler-null plugin
shell 0.30.1 enabled dokku core shell plugin
ssh-keys 0.30.1 enabled dokku core ssh-keys plugin
storage 0.30.1 enabled dokku core storage plugin
trace 0.30.1 enabled dokku core trace plugin
traefik-vhosts 0.30.1 enabled dokku core traefik-vhosts plugin
=====> mern-boilerplate app-json information
App json computed selected: app.json
App json global selected: app.json
App json selected:
=====> mern-boilerplate app information
App created at: 1678004858
App deploy source:
App deploy source metadata:
App dir: /home/dokku/mern-boilerplate
App locked: false
=====> mern-boilerplate builder information
Builder build dir:
Builder computed build dir:
Builder computed selected:
Builder global build dir:
Builder global selected:
Builder selected:
=====> mern-boilerplate builder-dockerfile information
Builder dockerfile computed dockerfile path: Dockerfile
Builder dockerfile global dockerfile path: Dockerfile
Builder dockerfile dockerfile path:
=====> mern-boilerplate builder-lambda information
Builder lambda computed lambdayml path: lambda.yml
Builder lambda global lambdayml path: lambda.yml
Builder lambda lambdayml path:
=====> mern-boilerplate builder-pack information
Builder pack computed projecttoml path: project.toml
Builder pack global projecttoml path: project.toml
Builder pack projecttoml path:
=====> mern-boilerplate buildpacks information
Buildpacks computed stack: gliderlabs/herokuish:latest-20
Buildpacks global stack:
Buildpacks list:
Buildpacks stack:
=====> mern-boilerplate ssl information
Ssl dir: /home/dokku/mern-boilerplate/tls
Ssl enabled: false
Ssl hostnames:
Ssl expires at:
Ssl issuer:
Ssl starts at:
Ssl subject:
Ssl verified:
=====> mern-boilerplate checks information
Checks disabled list: none
Checks skipped list: none
Checks computed wait to retire: 60
Checks global wait to retire: 60
Checks wait to retire:
=====> mern-boilerplate cron information
Cron task count: 0
=====> mern-boilerplate docker options information
Docker options build:
Docker options deploy: --restart=on-failure:10
Docker options run:
=====> mern-boilerplate domains information
Domains app enabled: true
Domains app vhosts: mern-boilerplate.dokku.arm1.localhost3002.live
Domains global enabled: true
Domains global vhosts: dokku.arm1.localhost3002.live
=====> mern-boilerplate git information
Git deploy branch: master
Git global deploy branch: master
Git keep git dir: false
Git rev env var: GIT_REV
Git sha:
Git source image:
Git last updated at:
Can't open /home/dokku/mern-boilerplate/tls/server.crt for reading, No such file or directory
281473808300512:error:02001002:system library:fopen:No such file or directory:../crypto/bio/bss_file.c:69:fopen('/home/dokku/mern-boilerplate/tls/server.crt','r')
281473808300512:error:2006D080:BIO routines:BIO_new_file:no such file:../crypto/bio/bss_file.c:76:
unable to load certificate
=====> mern-boilerplate letsencrypt information
Letsencrypt active: false
Letsencrypt autorenew: false
Letsencrypt computed dns provider:
Letsencrypt global dns provider:
Letsencrypt dns provider:
Letsencrypt computed email:
Letsencrypt global email:
Letsencrypt email:
Letsencrypt expiration: 1677974400
Letsencrypt computed graceperiod: 2592000
Letsencrypt global graceperiod:
Letsencrypt graceperiod:
Letsencrypt computed lego docker args:
Letsencrypt global lego docker args:
Letsencrypt lego docker args:
Letsencrypt computed server: https://acme-v02.api.letsencrypt.org/directory
Letsencrypt global server:
Letsencrypt server:
=====> mern-boilerplate logs information
Logs computed max size: 10m
Logs global max size: 10m
Logs global vector sink:
Logs max size:
Logs vector sink:
=====> mern-boilerplate network information
Network attach post create:
Network attach post deploy:
Network bind all interfaces: false
Network computed attach post create:
Network computed attach post deploy:
Network computed bind all interfaces: false
Network computed initial network: dokku-external
Network computed tld:
Network global attach post create:
Network global attach post deploy:
Network global bind all interfaces: false
Network global initial network: dokku-external
Network global tld:
Network initial network:
Network static web listener:
Network tld:
Network web listeners:
=====> mern-boilerplate nginx information
Nginx access log format:
Nginx access log path: /var/log/nginx/mern-boilerplate-access.log
Nginx bind address ipv4:
Nginx bind address ipv6: ::
Nginx client max body size:
Nginx disable custom config: false
Nginx error log path: /var/log/nginx/mern-boilerplate-error.log
Nginx global hsts: true
Nginx computed hsts: true
Nginx hsts:
Nginx hsts include subdomains: true
Nginx hsts max age: 15724800
Nginx hsts preload: false
Nginx computed nginx conf sigil path: nginx.conf.sigil
Nginx global nginx conf sigil path: nginx.conf.sigil
Nginx nginx conf sigil path:
Nginx proxy buffer size: 4096
Nginx proxy buffering: on
Nginx proxy buffers: 8 4096
Nginx proxy busy buffers size: 8192
Nginx proxy read timeout: 60s
Nginx last visited at:
Nginx x forwarded for value: $remote_addr
Nginx x forwarded port value: $server_port
Nginx x forwarded proto value: $scheme
Nginx x forwarded ssl:
=====> mern-boilerplate proxy information
Proxy enabled: true
Proxy port map:
Proxy type: nginx
=====> mern-boilerplate ps information
Deployed: false
Processes: 0
Ps can scale: true
Ps computed procfile path: Procfile
Ps global procfile path: Procfile
Ps procfile path:
Ps restart policy: on-failure:10
Restore: true
Running: false
=====> mern-boilerplate registry information
Registry computed image repo: dokku/mern-boilerplate
Registry computed push on release: false
Registry computed server:
Registry global push on release:
Registry global server:
Registry image repo:
Registry push on release:
Registry server:
Registry tag version:
=====> mern-boilerplate resource information
=====> mern-boilerplate scheduler information
Scheduler computed selected: docker-local
Scheduler global selected: docker-local
Scheduler selected:
=====> mern-boilerplate scheduler-docker-local information
Scheduler docker local disable chown:
Scheduler docker local init process: true
Scheduler docker local parallel schedule count:
=====> mern-boilerplate storage information
Storage build mounts:
Storage deploy mounts:
Storage run mounts:
ubuntu@arm1:~/traefik-proxy/apps/dokku$
How (deb/make) and where (AWS, VirtualBox, physical, etc.) was Dokku installed?:
Dokku in Docker container.
Additional information
ubuntu@arm1:~/traefik-proxy/apps/dokku$ dokku nginx:show-config mern-boilerplate
! No nginx.conf exists for mern-boilerplate
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 17 (6 by maintainers)
@nemanjam run in the same problem today on a x86_64 ubuntu machine. In my case the workaround was easy: i had to replace all
-
to underscores_
in my mongodb name. So i had to usedokku mongo:create mern_boilerplate_database
instead ofdokku mongo:create mern-boilerplate-database
.Okay interesting. This at least doesn’t work on arm (not arm64), which is what I’m running on my raspberry pi. It doesn’t work there because there is no
linux/arm/v7
version of mongo 😂I got access to oracle cloud, so I might have a bit of time later this week to test it out there.