Skip to content
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

docker::services: Fix using multiple published ports #447

Merged
merged 1 commit into from
Mar 4, 2019

Conversation

jacksgt
Copy link
Contributor

@jacksgt jacksgt commented Mar 2, 2019

While the class docker::services already allowed arrays to be
specified for publish ports, it didn't handle this correctly since
this array was simply converted to a string and passed onto Docker,
like so:

--publish '["80:80", "443:443"]'

To correctly publish multiple ports, the --publish parameter has to
be called specified for each port.

--publish '80:80' --publish '443:443'

This patch also introduces a new spec test to check this behavior

While the class docker::services already allowed arrays to be
specified for `publish` ports, it didn't handle this correctly since
this array was simply converted to a string and passed onto Docker,
like so:

    --publish '["80:80", "443:443"]'

To correctly publish multiple ports, the `--publish` parameter has to
be called specified for each port.

    --publish '80:80' --publish '443:443'

This patch also introduces a new spec test to check this behavior
@davejrt
Copy link
Contributor

davejrt commented Mar 4, 2019

LGTM

@davejrt davejrt merged commit a204679 into puppetlabs:master Mar 4, 2019
@davejrt davejrt added this to the 3.4.1 milestone Mar 14, 2019
@Ramesh7 Ramesh7 added the bugfix label Jul 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants