dokku / ci-docker-image

A Docker Image meant for use with CI/CD pipelines
MIT License
35 stars 24 forks source link

Cannot use an IPv6 address in the Git URL #99

Closed yttrian closed 7 months ago

yttrian commented 7 months ago

If you're using Dokku - especially for commercial purposes - consider donating to project development via OpenCollective or Patreon. Funds go to general development, support, and infrastructure costs.

If you'd like to sponsor specific functionality, see the project's Sponsoring document.

If you need support for a version of Dokku that is more than a year old, your issue may be closed without an answer. Please upgrade to a recent version before filing an issue.

Description of problem

Unlike IPv4 addresses, IPv6 addresses cannot be used.

How reproducible

Very

Steps to Reproduce

  1. GIT_REMOTE_URL=ssh://dokku@1.1.1.1:22/example bin/parse-ssh-host
  2. GIT_REMOTE_URL=ssh://dokku@[2606:4700:4700::1111]:22/example bin/parse-ssh-host

Actual Results

  1. 1.1.1.1
  2. [2606

Expected Results

  1. 1.1.1.1
  2. [2606:4700:4700::1111]

Environment Information

GitLab CI specifically, but reproducible outside.

josegonzalez commented 7 months ago

Yeah thats probably from here: https://github.com/dokku/ci-docker-image/blob/master/bin/parse-ssh-host#L12

Honestly I think this should probably be a small python script that uses url.parse or something instead.