Commit Graph

803 Commits

Author SHA1 Message Date
Jose Diaz-Gonzalez
1cbdde748e Merge pull request #2290 from dokku/1734-restart-policies
Implement restart-policy handling
2016-07-30 15:10:37 -04:00
Jose Diaz-Gonzalez
cb9c5b6988 Merge pull request #2317 from dokku/jg-cert-remap-http-to-https
Properly remap http port 80 mappings to https 443 when adding an ssl certificate
2016-07-30 15:09:53 -04:00
Jose Diaz-Gonzalez
2474c87bbd Pull the deploying app image name where necessary
All of these commands should execute against the image that is in use versus the "latest" that dokku provides the system with.
2016-07-29 12:49:29 -04:00
Jose Diaz-Gonzalez
115b939071 Cleanup deploying image name retrieval
Rather than try to shim in the logic from the existing get_app_image_name method, simply duplicate it to make the method name more readable
2016-07-29 04:51:36 -04:00
Jose Diaz-Gonzalez
372802f834 Only remove https ports when removing a certificate 2016-07-29 01:52:19 -04:00
Jose Diaz-Gonzalez
2732dda770 Fix plugin version
[ci skip]
2016-07-28 23:52:31 -04:00
Jose Diaz-Gonzalez
de550094da Standardize parenthesis usage for is_deployed 2016-07-23 16:04:13 -04: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
Michael Hobbs
a269f8e003 support --quiet and split up data access from presentation 2016-07-17 15:56:11 -07:00
Michael Hobbs
514ebf4d84 fix copypasta and actually call trigger 2016-07-17 15:55:14 -07:00
Justin Clark
d743a27de8 Fix is_valid_hostname regex 2016-07-08 13:05:14 -07:00
Jose Diaz-Gonzalez
b2fd5676eb Release 0.6.5 2016-07-06 18:39:17 -04:00
Michael Hobbs
01d65fccdd fix app.json extraction in dockerfile apps not using /app. closes #2300 2016-07-06 12:03:07 -07:00
Jose Diaz-Gonzalez
64c5a24919 Create the cache directory if it does not exist for deployment tasks 2016-07-05 02:38:02 -04:00
Jose Diaz-Gonzalez
72f1a85459 Use the deployed image name when running deploy tasks or running arbitrary commands
This ensures the proper image is in use, regardless of the phase in which dokku creates a docker container.
2016-07-05 02:37:50 -04:00
Jose Diaz-Gonzalez
3dccf814e8 Add deployed-app-image-repo plugin hook
This hook will allow users to modify the repo in use for deployed applications. An example use case would be one where the image being deployed is from a remote docker registry where the `dokku` username is taken and the app will be deployed from a separate username.
2016-07-05 02:34:13 -04:00
Jose Diaz-Gonzalez
3ae6b3f1a8 Document tar deployment method
[ci skip]
2016-07-05 01:21:19 -04:00
Jose Diaz-Gonzalez
edc0961e19 Fix documentation directory structure
Also ensure there is a trailing slash on all urls
2016-07-04 22:59:50 -04:00
Jose Diaz-Gonzalez
59c9207797 Implement restart-policy handling. Closes #1734
Applications without a restart-policy will have their policies set to `on-failure:10`. Users can completely unset the restart-policy using the `docker-options` plugin, though this will be equivalent to setting it explicitly to `no`.

Restart policies must be explicitly set, and the following are all valid:

- no
- unless-stopped
- always
- on-failure
- on-failure:NUMBER
2016-07-02 17:22:54 -04:00
Jose Diaz-Gonzalez
aa74315389 Release 0.6.4 2016-06-29 01:27:16 -04:00
Michael Hobbs
ae972cf3cd only attempt to stop a checks-disabled container if it is actually running. closes #2278 2016-06-28 20:32:04 -07:00
Stefan Seemayer
f0000a18ba Prefer file import in certs:add if files given
Fixes dokku/dokku-letsencrypt#67

Change the certs:add command to use a file import without trying to
detect a piped-in tarball if server.crt and server.key files were passed
in as arguments and those files exist.

Fixes hangs on certificate imports by filename when the check for a
STDIN pipe fails e.g. when running dokku remotely using a SSH command.
2016-06-27 16:09:05 +02:00
Jose Diaz-Gonzalez
2b019aef2f Release 0.6.3 2016-06-25 00:16:36 -04:00
Jose Diaz-Gonzalez
4b0163103e Add docs for removing a specific proxy tuple
[ci skip]
2016-06-20 23:19:44 -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
Jose Diaz-Gonzalez
d4cf23ec07 Merge pull request #2258 from dokku/2257_mh-domains-regex
support domains that start with digits per RFC1123
2016-06-20 22:47:12 -04:00
Jose Diaz-Gonzalez
bdd2b4bfe5 Release 0.6.2 2016-06-20 21:16:21 -04:00
Michael Hobbs
98ef078d33 support domains that start with digits per RFC1123. closes #2257 2016-06-20 15:01:48 -07:00
Michael Hobbs
aa345fad01 revert automatically binding storage mounts in build phase. closes #2254 2016-06-20 11:39:08 -07:00
Jose Diaz-Gonzalez
ed06b8961e Release 0.6.1 2016-06-18 23:54:00 -04:00
Michael Hobbs
d9ab4d1424 fix missing $ sign in default nginx template 2016-06-18 16:06:46 -07:00
Jose Diaz-Gonzalez
833db67f25 Release 0.6.0 2016-06-18 01:53:48 -04:00
Michael Hobbs
9effe275bd don't call dokku binary in checks/install. fix variable typo 2016-06-17 19:49:15 -07:00
Michael Hobbs
ce3aa4b93e remove calls to dokku binary for build/receive/release 2016-06-17 16:40:35 -07:00
Michael Hobbs
fcefd4a29b use central deploy lock in git plugin 2016-06-17 16:16:20 -07:00
Michael Hobbs
4f8c1b64c9 implement central deploy lock and use in tar plugin 2016-06-17 15:58:31 -07:00
Michael Hobbs
2ece0e1bf8 move DOKKU_NGINX_SSL_PORT setting to correct logic block 2016-06-17 15:25:09 -07:00
Jose Diaz-Gonzalez
1216a5e65a Remove use of dokku binary from tar plugin 2016-06-17 13:55:43 -07:00
Jose Diaz-Gonzalez
aca2540651 Move tar functions into sourceable functions file 2016-06-17 13:55:43 -07:00
Jose Diaz-Gonzalez
2cb20f3fd0 Remove use of dokku binary from git plugin 2016-06-17 13:55:43 -07:00
Jose Diaz-Gonzalez
946756bd43 Move git functions into sourceable functions file 2016-06-17 13:55:43 -07:00
Michael Hobbs
e6dfdc0732 fix reference to .SPDY_SUPPORTED in default template 2016-06-16 17:23:35 -07:00
Michael Hobbs
21d0859253 make proxy port listing a callable function 2016-06-16 16:04:44 -07:00
Michael Hobbs
ab94a9fc67 fix broken tar/urls tests 2016-06-16 16:04:44 -07:00
Michael Hobbs
ff18e0d6be cleanup external references to nginx-vhosts plugin 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
99c56ccd6d Merge pull request #2243 from dokku/nginx-fixes
Nginx 1.9.5+ support
2016-06-16 16:02:02 -07:00
Jose Diaz-Gonzalez
f99aa2b128 Skip upgrading nginx when the version of nginx is at least 1.8.0
Refs #2059
2016-06-16 17:18:47 -04:00
Jose Diaz-Gonzalez
a43fc39d9a Support nginx 1.9.5+
Newer versions of nginx drop spdy support in favor of http2, and thus the nginx config that we bundle with dokku causes nginx to fail to reload in certain cases. This change drops spdy support in favor of http2 for versions of nginx greater than 1.9.5.

Closes #2216
2016-06-16 17:18:43 -04:00
Michael Hobbs
5e9df3a92d Merge pull request #2168 from dokku/2073_mh-zero-downtime
allow zero-downtime to be completely disabled.
2016-06-16 12:46:30 -07:00