Commit Graph

27 Commits

Author SHA1 Message Date
Jose Diaz-Gonzalez
f8ccf52079 refactor: only use detected port mapping if override is not specified
Previously, we would always set the port mapping during a dockerfile build, making it difficult for users to override mappings. We also only _sometimes_ updated the detected port mapping, further confusing issues when users were migrating from Dockerfile to Buildpacks for builds.

Now, we always detect the port mapping during the build process, and only use that detected port mapping if an override is not specified. This greatly simplifies the experience around port mapping, as now a user can create an app, set a port mapping, and that first deploy will respect the port mapping without an additional deploy.

The builder always has the best context for what the app should be listening on, and thus we can always specify a "default" port mapping at this stage. Users can override this map as desired later.

This change also results in the removal of a ton of internal code that is now centralized in the ports plugin.

Closes #4067
2023-08-05 10:58:57 -04:00
Jose Diaz-Gonzalez
9ecfa843f0 feat: add support for routing an app to a specified host:port
This is useful when there is a service not managed by Dokku but should be exposed via the Dokku routing layer. As an example, some binaries (consul, nomad, vault) expose web uis, and are traditionally run on the host directly vs in a container.

Closes #4665
2021-08-06 01:29:25 -04:00
Jose Diaz-Gonzalez
a086302fc5 fix: actually create the network triggers 2021-07-09 21:12:43 -04:00
Jose Diaz-Gonzalez
63f4ec3867 feat: call clone/destroy prop commands as necessary 2020-02-17 19:08:39 -05:00
Jose Diaz-Gonzalez
9818cc6461 feat: implement container network attaching
Containers can be attached:

- after they are created, but before they are started
- after a successful deploy, but before the proxy reloads

This allows folks to have flexibility around when they would like a container to be made available to a network.
2020-02-08 19:55:29 -05:00
Jose Diaz-Gonzalez
6a7d2e5252 refactor: decrease compile time for golang plugins
This change refactors the compiled golang plugins into 3 distinct binaries:

- commands: already existing
- subcommands/subcommands: entrypoint into all subcommands
- triggers: entrypoint into all triggers

It then further symlinks triggers and subcommands to the built binaries. This results in both a much faster build process as well as smaller package size.
2019-09-15 19:15:08 -04:00
Jose Diaz-Gonzalez
bf8b67b35d feat: cleanup glide plugins when running src-clean 2019-04-16 20:00:35 -04:00
Jose Diaz-Gonzalez
e7fb6007d3 feat: build golang binaries with higher concurrency
This should allow us to shave off a few minutes of build time, both locally and on CI
2019-01-20 18:12:08 -05:00
Jose Diaz-Gonzalez
56967ef950 fix: add post-app-clone-setup to network clean make target 2018-12-29 16:35:40 -05:00
Jose Diaz-Gonzalez
cfd8f237df feat: cleanup IP and PORT files on app clone 2018-12-28 17:02:06 -05: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
1201b05dfa fix: ignore a few files in the network plugin 2018-02-28 03:23:50 -05:00
Jose Diaz-Gonzalez
f1baa1f6a5 fix: remove golang files and triggers directory for packaging 2017-12-12 03:13:07 -05:00
Jose Diaz-Gonzalez
2e0939702a fix: properly copy triggers into place 2017-12-12 02:52:22 -05:00
Jose Diaz-Gonzalez
39abbdc5dd fix: ensure the trigger is moved into the correct directory 2017-12-12 00:22:18 -05:00
Jose Diaz-Gonzalez
5d5ede2b85 revert: drop reference to CGO_ENABLED completely 2017-12-12 00:09:36 -05:00
Jose Diaz-Gonzalez
b449227467 revert: re-enable system net usage 2017-12-11 23:46:08 -05:00
Jose Diaz-Gonzalez
228eb9ed7a revert: re-enable CGO_ENABLED=0 2017-12-11 23:44:08 -05:00
Jose Diaz-Gonzalez
a999f9d4e5 fix: set the TRIGGERS make variable properly 2017-12-11 23:26:33 -05:00
Jose Diaz-Gonzalez
9b431321fa feat: use the built-in net package instead of linking to system 2017-12-11 23:22:27 -05:00
Jose Diaz-Gonzalez
a96c1d644a fix: turn off CGO for all go builds 2017-12-11 23:22:11 -05:00
Jose Diaz-Gonzalez
6bd6cad8fd refactor: simplify triggers targets 2017-12-11 23:21:14 -05:00
Jose Diaz-Gonzalez
58cc088445 feat: converge upon a more standard Makefile for golang plugins 2017-12-11 23:16:03 -05:00
Jose Diaz-Gonzalez
ad732bd42b feat: add network:report command 2017-10-04 00:58:29 -04:00
Jose Diaz-Gonzalez
acde3d60a7 feat: allow users to bind to all interfaces when a proxy is enabled
- use a plugin trigger to see whether we should bind to all interfaces
- create a generic way of setting properties for a plugin
- migrate proxy-enabled to the new network property "bind-all-interfaces"
- add network:set subcommand
2017-10-02 15:05:13 -07:00
Jose Diaz-Gonzalez
dc00542b6f refactor: remove use of IP and PORT files from core-post-deploy plugin 2017-10-02 15:05:13 -07:00
Jose Diaz-Gonzalez
c788659b63 refactor: rewrite network plugin in golang 2017-10-02 15:05:13 -07:00