zalando-stups / pierone-cli

DEPRECATED: Convenient command line client for STUPS' Pier One Docker registry
http://docs.stups.io/en/latest/components/pierone.html#command-line-client
Other
10 stars 13 forks source link

validators.py: allow team names to contain underscores #85

Closed thilp closed 4 years ago

thilp commented 4 years ago

Bug report: https://groups.google.com/a/zalando.de/d/msg/zooport-stork/IQ4_-aQxKw4/u0DaPEEFAQAJ.

unfortunately, out Team ID eaa_di_ds does not comply with pierone naming conventions. Therefore I get this error whenever I use pierone to interact with my team's repo. Error: Invalid value for "TEAM": 'eaa_di_ds' doesn't satisfy regular expression pattern '[a-z][a-z0-9-]+'

coveralls commented 4 years ago

Coverage Status

Coverage remained the same at 80.0% when pulling 326c4589aceb207be60ca099f84a29fe9215c126 on support-teams-with-underscores into 53e5da1bf7cc6cd5e2acf7c562c43fd84c830569 on master.

thilp commented 4 years ago

:+1:

ethercrow commented 4 years ago

đź‘Ť

juhmelo commented 4 years ago

đź‘Ť

hjacobs commented 4 years ago

Please don't change this validation, I'm pretty sure it follows the Docker regex (Docker client).

thilp commented 4 years ago

Please don't change this validation, I'm pretty sure it follows the Docker regex (Docker client).

The user reports success, and he was also saying that it used to work when going through CDP, which led me to think that this was not a restriction of Pierone or Docker, but pierone-cli itself.

Here is what I read now on https://docs.docker.com/engine/reference/commandline/tag/:

The hostname must comply with standard DNS rules, but may not contain underscores. If a hostname is present, it may optionally be followed by a port number in the format :8080. If not present, the command uses Docker’s public registry located at registry-1.docker.io by default. Name components may contain lowercase letters, digits and separators. A separator is defined as a period, one or two underscores, or one or more dashes. A name component may not start or end with a separator.