Skip to content

Commit

Permalink
Merge pull request #75 from dokku/josegonzalez-patch-1
Browse files Browse the repository at this point in the history
fix: lowercase the service host when generated from the service type and name
  • Loading branch information
josegonzalez authored Sep 14, 2024
2 parents 0792433 + 64caf4a commit 7a34463
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion entrypoint
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ if [ -n "$SERVICE_TYPE" ] && [ -n "$SERVICE_NAME" ]; then
service_name=$(echo "$SERVICE_NAME" | tr .- _ | tr '[:lower:]' '[:upper:]')
host_prefix="DOKKU_${service_type}_${service_name}_PORT_"
if [ -z "$SERVICE_HOST" ] && [ -z "$SERVICE_HOST_ENV_VAR" ]; then
SERVICE_HOST="dokku-${service_type}-${service_name}"
SERVICE_HOST="$(echo "dokku-${service_type}-${service_name}" | tr '[:upper:]' '[:lower:]')"
fi
if [ -z "$SERVICE_PORT" ] && [ -z "$SERVICE_PORT_ENV_VAR" ]; then
SERVICE_PORT=$(env | sort | grep "$host_prefix" | grep PORT= | head -n1 | cut -d= -f2)
Expand Down

0 comments on commit 7a34463

Please sign in to comment.