Dokku: Expose two ports from an application
Asked Answered
C

1

2

I am trying to deploy a Scala based application to dokku, the application runs a http server and a customised sshd server.

The problem I have is it seems that dokku only supports one port for the application. I need dokku to expose both my applications ports to the web.

In docker this is possible and quite straight forward to do, but when I implement the same technique in the dokku file, I get an error.

Any suggestions on allowing two ports to be accessible?

Chiba answered 1/10, 2014 at 5:59 Comment(1)
Possible duplicate of Dokku: Listen to multiple ports from an appWhap
B
0

Since this is, after all, docker, you can use an ambassador...

You will need a line like:

docker run -t -i -link mysql:mysql -name mysql_ambassador -p 3306:3306 ctlc/ambassador

Replacing with your port and mysql with your container name (from docker images)

See https://www.ctl.io/developers/blog/post/deploying-multi-server-docker-apps-with-ambassadors

NOTE: Make sure you docker pull svendowideit/ambassador:latest before...

Brandabrandais answered 19/2, 2016 at 16:44 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.