Description of problem:
If someone pushes to remote of non-existent app, dokku tries to create the app.
It may look cool but in complex environments that in 99,99% cases means a typo in remote and build will fail anyway due lack of proper associated services or config and much more useful would have been to display an error that given app does not exist.
There should be an option to disable automatic creation of apps.
Output of the following commands
-----> uname: Linux dokku-ovh1-003 4.4.0-59-generic #80-Ubuntu SMP Fri Jan 6 17:47:47 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
-----> memory:
total used free shared buff/cache available
Mem: 16037 3954 1144 698 10938 10797
Swap: 1021 334 687
-----> docker version:
Client:
Version: 17.03.0-ce
API version: 1.26
Go version: go1.7.5
Git commit: 60ccb22
Built: Thu Feb 23 11:02:43 2017
OS/Arch: linux/amd64
Server:
Version: 17.03.0-ce
API version: 1.26 (minimum version 1.12)
Go version: go1.7.5
Git commit: 60ccb22
Built: Thu Feb 23 11:02:43 2017
OS/Arch: linux/amd64
Experimental: false
-----> docker daemon info:
Containers: 45
Running: 43
Paused: 0
Stopped: 2
Images: 476
Server Version: 17.03.0-ce
Storage Driver: aufs
Root Dir: /home/docker-data/aufs
Backing Filesystem: extfs
Dirs: 569
Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host macvlan null overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 977c511eda0925a723debdc94d09459af49d082a
runc version: a01dafd48bc1c7cc12bdb01206f9fea7dd6feb70
init version: 949e6fa
Security Options:
apparmor
seccomp
Profile: default
Kernel Version: 4.4.0-59-generic
Operating System: Ubuntu 16.04.1 LTS
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 15.66 GiB
Name: dokku-ovh1-003
ID: ODSG:K5CP:S7PY:27AZ:T2LW:SHBK:OSEM:TT4X:C5LT:57HI:VJAI:FDQU
Docker Root Dir: /home/docker-data
Debug Mode (client): true
Debug Mode (server): false
Registry: https://index.docker.io/v1/
WARNING: No swap limit support
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
-----> sigil version: 0.4.0
-----> herokuish version:
herokuish: 0.3.29
buildpacks:
heroku-buildpack-multi v1.0.0
heroku-buildpack-ruby v159
heroku-buildpack-nodejs v99
heroku-buildpack-clojure v76
heroku-buildpack-python v99
heroku-buildpack-java v51
heroku-buildpack-gradle v21
heroku-buildpack-grails v21
heroku-buildpack-scala v76
heroku-buildpack-play v26
heroku-buildpack-php v121
heroku-buildpack-go v64
heroku-buildpack-erlang fa17af9
buildpack-nginx v8
-----> dokku version: 0.9.4
-----> dokku plugins:
! Deprecated: Please use plugin:list
plugn: 0.3.0
00_dokku-standard 0.9.4 enabled dokku core standard plugin
20_events 0.9.4 enabled dokku core events logging plugin
apps 0.9.4 enabled dokku core apps plugin
build-env 0.9.4 enabled dokku core build-env plugin
certs 0.9.4 enabled dokku core certificate management plugin
checks 0.9.4 enabled dokku core checks plugin
common 0.9.4 enabled dokku core common plugin
config 0.9.4 enabled dokku core config plugin
deployment-keys 0.1.0 enabled Manage SSH deployment keys that should get injected into your containers on-build
docker-options 0.9.4 enabled dokku core docker-options plugin
domains 0.9.4 enabled dokku core domains plugin
enter 0.9.4 enabled dokku core enter plugin
git 0.9.4 enabled dokku core git plugin
hostkeys-plugin 0.1.0 enabled Manage hostkeys (.ssh/known_hosts) in your container environment
letsencrypt 0.8.6 enabled Automated installation of let's encrypt TLS certificates
logs 0.9.4 enabled dokku core logs plugin
named-containers 0.9.4 enabled dokku core named containers plugin
nginx-vhosts 0.9.4 enabled dokku core nginx-vhosts plugin
plugin 0.9.4 enabled dokku core plugin plugin
postgres 1.0.0 enabled dokku postgres service plugin
proxy 0.9.4 enabled dokku core proxy plugin
ps 0.9.4 enabled dokku core ps plugin
redis 1.0.0 enabled dokku redis service plugin
repo 0.9.4 enabled dokku core repo plugin
shell 0.9.4 enabled dokku core shell plugin
slack 0.1.0 enabled Notify Slack on deploy
ssh-keys 0.9.4 enabled dokku core ssh-keys plugin
storage 0.9.4 enabled dokku core storage plugin
tags 0.9.4 enabled dokku core tags plugin
tar 0.9.4 enabled dokku core tar plugin
Environment details (AWS, VirtualBox, physical, etc.):
bare metal
How was Dokku installed?:
from .deb
How reproducible:
Always
Steps to Reproduce:
[email protected]:someappActual Results:
New app is being created
Expected Results:
App should be created by default but there should be a setting to disable this behaviour and if it was turned on, the error should show up.
Additional info:
None
I'm not at all opposed to this and would welcome a PR to implement. Let us know if you would like to contribute and I'd be happy to help guide you through any code/testing questions.
I don't mind implementing this but do you have any idea what will be dokku-style way to do this?
New command such as dokku autocreate off or rather some config?
It's probably fine to have as just a global config variable for now:
# any value other than true means we can create it
dokku config:set --global DOKKU_DISABLE_APP_AUTOCREATION=true
Closing as there is a pull request up.
Most helpful comment
It's probably fine to have as just a global config variable for now: