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

Add custom network IP address property mappings #533

Merged
merged 1 commit into from
Aug 3, 2016

Conversation

jdcasey
Copy link
Contributor

@jdcasey jdcasey commented Aug 2, 2016

This adds property mappings for custom networks, using the format:

docker.container.<alias>.net.<name>.ip

It seems important when the build is running on a container, and tries to start other containers in order to use them as remote services for integration testing. In this case, the only way I've found success is by using a custom network created using:

    $ docker network create -d bridge ci-network

My Jenkins instance is running in its own docker container, so the bridge aspect allows me access to Jenkins. All the docker containers started by Jenkins will also need to use this custom network, I've found, and when the build needs to access them it can use the container's IP address on the custom network along with the ports from the EXPOSE line in the Dockerfile (not mapped ports).

This works for me, but I'm not sure I understand how to write tests for the patch I'm submitting. I've tried to match code formatting, but ended up just guessing at the rules. Please let me know if I've missed something that needs attention.

@rhuss
Copy link
Collaborator

rhuss commented Aug 3, 2016

LGTM, thanks !

I'll add some documentation and try to add a unit test for the IP extraction part.

Code formatting looks fine, its not so strict anyway ;-)

rhuss added a commit that referenced this pull request Aug 3, 2016
@rhuss rhuss merged commit 2a6d910 into fabric8io:master Aug 3, 2016
@rhuss
Copy link
Collaborator

rhuss commented Aug 3, 2016

fyi, 0.15.16 is released .....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants