New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Forbid more characters from request/deploy IDs #1407

Merged
merged 3 commits into from Feb 10, 2017

Conversation

Projects
None yet
2 participants
@PtrTeixeira
Contributor

PtrTeixeira commented Jan 26, 2017

In an effort to prevent attempting to create docker containers
with names that docker will refuse, this forbids more characters
from being used in request/deploy IDs. This is actually more of a
whitelist approach than a blacklist approach; it explicitly
says the characters that can be used and forbids anything else.

Closes #1406
/cc @ssalinas

Forbid more characters from request/deploy IDs
In an effort to prevent attempting to create docker containers
with names that docker will refuse, this forbids more characters
from being used in request/deploy IDs. This is actually more of a
whitelist approach than a blacklist approach; it explicitly
says the characters that can be used and forbids anything else.
Re-arrange test code
Move the code from the validator test class that I had created into
a the existing validator test class. This let me get rid of the
dependencies that I had added as a part of testing my code.
Neaten up the test class w/ builders
Use builders to create the Singularity{Request,Deploy} instances that
were needed for testing. This lets the contructors and all of their
`Optional.<>absent()` arguments be elided, which makes the whole think
much, much easier to read. Thanks to Stephen for the fix.

@ssalinas ssalinas modified the milestone: 0.14.0 Feb 9, 2017

@ssalinas ssalinas added the hs_stable label Feb 10, 2017

@ssalinas

This comment has been minimized.

Show comment
Hide comment
@ssalinas

ssalinas Feb 10, 2017

Member

LGTM

Member

ssalinas commented Feb 10, 2017

LGTM

@ssalinas ssalinas merged commit 9c71343 into master Feb 10, 2017

1 of 2 checks passed

continuous-integration/travis-ci/pr The Travis CI build failed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@ssalinas ssalinas deleted the expand-deployId-character-blacklist branch Feb 10, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment