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

Use 'host' network in deb container builds #1071

Merged
merged 1 commit into from
Nov 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions ros_buildfarm/templates/release/deb/binarypkg_job.xml.em
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ but disabled since the package is blacklisted (or not whitelisted) in the config
'echo "# BEGIN SECTION: Build Dockerfile - binarydeb task"',
'cd $WORKSPACE/docker_generating_docker',
'python3 -u $WORKSPACE/ros_buildfarm/scripts/misc/docker_pull_baseimage.py',
'docker build --force-rm -t binarydeb_task_generation.%s_%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, arch, pkg_name),
'docker build --network=host --force-rm -t binarydeb_task_generation.%s_%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, arch, pkg_name),
'echo "# END SECTION"',
'',
'echo "# BEGIN SECTION: Run Dockerfile - binarydeb task"',
Expand All @@ -138,6 +138,7 @@ but disabled since the package is blacklisted (or not whitelisted) in the config
' --rm ' +
' --cidfile=$WORKSPACE/docker_generating_docker/docker.cid' +
' -e=TRAVIS=$TRAVIS' +
' --net=host' +
' -e=ROS_BUILDFARM_PULL_REQUEST_BRANCH=$ROS_BUILDFARM_PULL_REQUEST_BRANCH' +
' -v $WORKSPACE/ros_buildfarm:/tmp/ros_buildfarm:ro' +
' -v $WORKSPACE/binarydeb:/tmp/binarydeb' +
Expand All @@ -159,7 +160,7 @@ but disabled since the package is blacklisted (or not whitelisted) in the config
'# build and run build_binarydeb Dockerfile',
'cd $WORKSPACE/docker_build_binarydeb',
'python3 -u $WORKSPACE/ros_buildfarm/scripts/misc/docker_pull_baseimage.py',
'docker build --force-rm -t binarydeb_build.%s_%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, arch, pkg_name),
'docker build --network=host --force-rm -t binarydeb_build.%s_%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, arch, pkg_name),
'echo "# END SECTION"',
'',
'echo "# BEGIN SECTION: Run Dockerfile - build binarydeb"',
Expand Down Expand Up @@ -224,7 +225,7 @@ but disabled since the package is blacklisted (or not whitelisted) in the config
@# 'echo "# BEGIN SECTION: Build Dockerfile - install"',
@# 'cd $WORKSPACE/docker_install_binarydeb',
@# 'python3 -u $WORKSPACE/ros_buildfarm/scripts/misc/docker_pull_baseimage.py',
@# 'docker build --force-rm -t binarydeb_install.%s_%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, arch, pkg_name),
@# 'docker build --network=host --force-rm -t binarydeb_install.%s_%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, arch, pkg_name),
@# 'echo "# END SECTION"',
@# '',
@# 'echo "# BEGIN SECTION: Run Dockerfile - install"',
Expand Down
2 changes: 1 addition & 1 deletion ros_buildfarm/templates/release/deb/sourcepkg_job.xml.em
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ but disabled since the package is blacklisted (or not whitelisted) in the config
'echo "# BEGIN SECTION: Build Dockerfile - generate sourcedeb"',
'cd $WORKSPACE/docker_sourcedeb',
'python3 -u $WORKSPACE/ros_buildfarm/scripts/misc/docker_pull_baseimage.py',
'docker build --force-rm -t sourcedeb.%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, pkg_name),
'docker build --network=host --force-rm -t sourcedeb.%s_%s_%s_%s .' % (rosdistro_name, os_name, os_code_name, pkg_name),
'echo "# END SECTION"',
'',
'echo "# BEGIN SECTION: Run Dockerfile - generate sourcedeb"',
Expand Down
Loading