Commit Graph

63 Commits

Author SHA1 Message Date
Jose Diaz-Gonzalez
87889957ff fix: correct imports 2023-02-08 04:12:43 -05:00
Jose Diaz-Gonzalez
0dca37d8a1 feat: add support for specifying an initial-network property
This network is the network that is associated with the container on creation. If specified, then the bridge network is not attached to the service.

Only a single initial network can be specified at this time.
2023-02-07 18:24:54 -05:00
Jose Diaz-Gonzalez
881f07df19 feat: implement service filtering
If a user implements the user-auth-service trigger in a plugin and that plugin does not echo the passed in app(s) on stdout, the app is assumed to not exist. This mirrors the functionality for applications in regards to auth filtering.

This may still need auditing to ensure it covers everything and doesn't cause issues, but local testing implies that everything is working as expected.
2022-07-07 02:54:14 -04:00
Jose Diaz-Gonzalez
238f09dae0 chore: run shfmt 2019-05-30 11:06:25 -04:00
Jose Diaz-Gonzalez
c00f5104e7 feat: default to help output when no subcommand specified
Refs dokku/dokku-redis#95
2018-02-25 22:52:27 -05:00
Jose Diaz-Gonzalez
bc37291bcb feat: prepare ground for config directory changes 2017-09-11 03:52:52 -04:00
Jose Diaz-Gonzalez
3d9930369e feat: add support for enhanced help output 2017-09-11 01:25:22 -04:00
Jose Diaz-Gonzalez
d45123b8c4 feat: Adds possibility to set encryption for s3 2017-09-09 14:32:14 -04:00
Jose Diaz-Gonzalez
cb633ca36b docs: destroy help now shows that data will be deleted 2017-08-27 18:43:17 -04:00
Jose Diaz-Gonzalez
dd58ff6534 fix: add missing argument to backup subcommand help output 2017-08-26 05:21:20 -04:00
Jose Diaz-Gonzalez
c4b0235936 Adds parameters to backup-auth for region support and non AWS endpoint support
Refs dokku/dokku-mariadb#61
2017-08-26 00:03:36 -04:00
Jose Diaz-Gonzalez
f001535060 feat: add s3 backup support 2016-10-31 11:39:22 -06:00
Jose Diaz-Gonzalez
b6c472f0c7 Make dokku help friendlier 2016-08-28 01:13:10 -04:00
Vitaly Domnikov
9098f2e9cc rename admin command 2016-07-11 16:52:58 -07:00
Vitaly Domnikov
c148691ea7 rename admin command 2016-07-11 16:51:10 -07:00
Vitaly Domnikov
0d64d42218 add mongo:admin command 2016-07-11 16:18:29 -07:00
Jose Diaz-Gonzalez
f5962b2b68 Always remove * directory 2016-05-23 21:12:48 -04:00
Jose Diaz-Gonzalez
ddf428c035 Conform to function declaration standards
- declare desc variable
- declare all positional arguments
- set the cmd
- properly handle DOKKU_APP_NAME
2016-05-15 23:56:32 -04:00
Jose Diaz-Gonzalez
e2f6d6b045 Move all commands into subcommand structure 2016-05-15 22:12:43 -04:00
Jose Diaz-Gonzalez
8840d94497 Upgrade help output for dokku 0.5.x
Also completely drop support for help output on 0.3.x
2016-05-15 19:13:02 -04:00
Jose Diaz-Gonzalez
3ed0c73bd9 Move setting of PLUGIN_BASE_PATH to config 2016-05-15 18:36:44 -04:00
Jose Diaz-Gonzalez
108a02f61e quote SERVICE_NAME value 2016-05-08 14:57:05 -04:00
Jose Diaz-Gonzalez
dd5fe9104b ensure we don't expand PLUGIN_DATA_ROOT 2016-05-08 14:55:39 -04:00
Jose Diaz-Gonzalez
cbead0b152 quote docker pull call 2016-05-08 14:55:28 -04:00
Jose Diaz-Gonzalez
67dbee1b90 fix read call 2016-05-08 14:55:16 -04:00
Jose Diaz-Gonzalez
bce92157fc Move command check before DOKKU_TRACE to reduce trace output 2016-05-08 03:00:25 -04:00
Jose Diaz-Gonzalez
3edec37f54 Rework how config vars are sourced
- ensure we source config/functions from the correct directory
- move config sourcing up before DOKKU_TRACE to reduce trace output
2016-05-08 03:00:05 -04:00
Jose Diaz-Gonzalez
27ded0dca0 create container if not exists on service:start 2016-05-04 01:02:14 -04:00
Trey Thomas
06ad8a15a4 Automatically pull image if it's not already downloaded 2016-04-18 16:45:37 -06:00
Edgars Beigarts
822a0259f9 Fix exit code for mongo:export when SSH_TTY is not present 2016-02-24 09:16:59 +02:00
Jose Diaz-Gonzalez
b0efaebdbe Remove invalid service directory during command runs
Closes dokku/dokku-mongo#40
2016-01-17 21:29:19 -05:00
Jacob Williams
179b4984a3 Redirect mongodump stdout to stderr
In version 3.x, the output of mongodump is on stderr, but on 2.6.x
it writes information to stdout. This change doesn't break 3.x in
my tests but prevents extraneous junk in beginning of the tar file
when exporting in 2.6.x.

Updated test to match redirect in exec command.
2015-12-07 23:59:55 -06:00
Jacob Williams
3d30b6ca35 remove = after -o in mongodump command
The -o= seems to work fine in 3.x but in 2.x it actually includes the equals sign in the path, resulting in "/=/tmp/tmp.XXXXXX". The mongodump command docs for neither 2.x nor 3.x list the equals sign as part of the -o or --out parameter. It seems to work fine in 3.x with or without the equals sign.

Updated test to reflect change to -o
2015-12-07 23:57:17 -06:00
Jose Diaz-Gonzalez
ab0f4f2fe3 Add support for custom environment variables when starting a service container 2015-11-05 01:29:10 -05:00
Loïc Guitaut
e183572bf0 Fix export when using ssh -t 2015-10-19 11:32:57 +02:00
Loïc Guitaut
3609235d1b Fix the destroy command
Checking for container with its service name instead of ID.
Doing a chmod 777 on `/data` before removing data from the service.
2015-10-12 10:58:12 +02:00
Jose Diaz-Gonzalez
cbd49a633f Remove quotes on $MONGO_CONFIG_OPTIONS to allow for variable expansion 2015-10-11 02:39:18 -04:00
Jose Diaz-Gonzalez
e5276c4118 Use MONGO_CONFIG_OPTIONS env var when running mongodb 2015-10-05 14:05:06 -04:00
Jose Diaz-Gonzalez
35944a2325 Merge pull request #28 from dokku/lg-revamp-link-unlink
Revamp link/unlink commands
2015-10-05 13:55:31 -04:00
Loïc Guitaut
5eed4378aa Revamp link/unlink commands
Previously we were exporting `MONGO_URL` via the docker-args* hooks.
This seems to confuse our users (since the env var is not displayed
when calling `dokku config`) and in some cases it also seems that the
env var is not correctly set.
Another problem is if several services are linked to the same app and
if they are exporting `MONGO_URL` as well. Then we don’t know what
will be set.

To resolve theses issues, this patch changes the way we manage the env
vars. We use standard dokku commands (`config` and `docker-options`) so
config is set on the linked application and can be reviewed by the user
easily.
We also handle the case where `MONGO_URL` is already set on the
linked application. When it’s the case, we automatically generate
another env var based on the following pattern: DOKKU_<service
name>_<random unused color>_URL. For example, this can give:
DOKKU_MONGO_BLACK_URL.

Since naming is now handled automatically, the `alias` command has been
removed. If the user wants to set a different env var on her app, it’s
just a matter of using `dokku config:set` and pasting the wanted value.

IP in DSN has been removed in favor of host name exported by docker in
the container. This is more robust and simpler since the IP can change
but the name will remain the same if the service container restarts for
instance.

With all those changes, a new command has been introduced: `promote`.
The goal of this command is to easily set a service as the primary one
when several are linked to an app. (see README for an example)
2015-10-05 18:11:25 +02:00
Edgars Beigarts
7f7a156482 Fix /data/db volume mount point 2015-10-05 09:51:59 +03:00
Jose Diaz-Gonzalez
75f5e9b65c Add mongo:help command 2015-09-27 17:19:08 -04:00
Loïc Guitaut
34fd421d4c Use our own image to wait for services 2015-09-24 11:42:49 +02:00
Loïc Guitaut
22fa6bd92d Do not always allocate a tty on connect 2015-09-21 10:12:55 +02:00
Loïc Guitaut
ed884da6f8 Fix compatibility with dokku 0.4+ 2015-09-16 23:48:58 +02:00
Loïc Guitaut
31cefc9387 Use authentication when creating database 2015-09-15 22:38:19 +02:00
Loïc Guitaut
61f2afb099 Implement export, import and clone commands 2015-09-14 23:12:40 +02:00
Loïc Guitaut
1acba04ade Compatibility with dokku 0.3.x & 0.4.x for help output 2015-09-11 23:27:52 +02:00
Loïc Guitaut
1f0905d353 Use aanand/wait image to wait for service to be ready 2015-09-09 19:26:23 +02:00
Loïc Guitaut
7ac355a0d2 Remove call to docker kill 2015-09-09 19:21:39 +02:00