Commit Graph

13 Commits

Author SHA1 Message Date
Jose Diaz-Gonzalez
86795ddacc tests: run mvdan/shfmt on test runs
While I do not agree with _every_ style change, this will force Dokku to have consistent formatting across all shell scripts, which is arguably a Good Thing™.

The command used to reprocess everything is:

```shell
shfmt -l -bn -ci -i 2 -w .
```
2019-01-07 01:25:55 -05:00
Jose Diaz-Gonzalez
13ffd960d9 feat: create proxy:ports-set call
In some cases, it may be useful to completely override the set ports for a given application - such as on initial deploy when there is no global domain set. This change also further allows us to handle automation in a smoother fashion.
2018-04-07 14:48:18 -04:00
Jose Diaz-Gonzalez
4aac1fd936 feat: add report trigger
This allows users to quickly show the state of any configured application, as well as the state of their server. In doing so, we make it easy for them to provide information necessary for debugging in a single command.
2018-04-07 04:49:21 -04:00
Jose Diaz-Gonzalez
15021d05c9 feat: allow quieter report output
Users should have the option of suppressing headers, which are not always useful when interacting with dokku in a programmatic fashion.
2017-04-21 00:53:35 -06:00
Jose Diaz-Gonzalez
97e35e796c fix: ensure we can call the report subcommand without an app while specifying flags
Closes #2628
2017-03-16 02:33:51 -06:00
Jose Diaz-Gonzalez
0e899cdd13 feat: implement proxy:report command
Also deprecate `proxy:default` in favor of `proxy:report`

Refs #2356
2017-02-20 21:52:02 -07:00
Jose Diaz-Gonzalez
7ac47d2e61 Fix iteration on all apps for dokku proxy command
Closes #2481
2016-11-20 15:15:40 -07:00
Jose Diaz-Gonzalez
0d4560177a Properly remap http port 80 mappings to https 443 when adding an ssl certificate
Rather than removing all port mappings, we simply remap port 80 mappings to 443. The previous behavior would remove custom port mappings for all applications and reset them on any certificate change, preventing automation from plugins such as letsencrypt. While this behavior doesn't matter for buildpack deploys - which only expose a single port on container port 5000 - Dockerfile deploys would frequently be affected by such a change, requiring a remapping of all custom ports.

This commit also standardizes on the method used to source the proxy functions
2016-07-23 16:04:13 -04:00
Jose Diaz-Gonzalez
bd7deae883 Add ability to remove a specific port mapping tuple
This allows users to specify port 80 after an application has had domain added. Normally, when we first add an extra domain, the following tuple is added:

    http:80:5000

A user might then want to remap port 80 to another port, such as port 8080:

    dokku proxy:ports-add APP http:80:8080

The application would then have the following proxy map:

    http:80:5000 http:80:8080

As nginx vhosts are resolved in FIFO order, the "correct" upstream of 8080 would basically be ignored. The workaround would be to remove the original port mapping, but the following:

    dokku proxy:ports-remove APP 80

Would remove *both* entries and then re-add the default of `http:80:5000`. Thus it was not possible to use the porcelain to correct the port mapping and a user would have to fall back to using the following hack to fix their mapping:

    dokku config:set APP DOKKU_PROXY_PORT_MAP='http:80:8080'

You can now use the previous syntax *as well as* the following to remove a port mapping:

    dokku proxy:ports-remove APP http:80:5000
2016-06-20 23:17:55 -04:00
Michael Hobbs
21d0859253 make proxy port listing a callable function 2016-06-16 16:04:44 -07:00
Michael Hobbs
6c1d6225f9 initial pass at implementing DOKKU_PROXY_PORT_MAP. closes #2239. 2016-06-16 16:04:44 -07:00
Michael Hobbs
987c5cfb9c use declare for description variable 2016-03-08 15:30:34 -05:00
Michael S. Hobbs
89f289b433 subcommand restructure and bashstyle refactor. closes #1579 2016-03-03 22:11:35 -08:00