You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2022/03/01 12:56:34 UTC

[GitHub] [pulsar] lhotari opened a new pull request #14513: [Dockerfile] Enable retries for apt-get when building Pulsar docker image

lhotari opened a new pull request #14513:
URL: https://github.com/apache/pulsar/pull/14513


   ### Motivation
   
   - prevents issues where apt repository doesn't respond
   - example failure: https://github.com/apache/pulsar/runs/5374589351?check_suite_focus=true#step:10:1458
   
   ### Modifications
   
   - set retries to 3
   - also reduce default timeout to 30 seconds


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] michaeljmarshall commented on a change in pull request #14513: [Dockerfile] Enable retries for apt-get when building Pulsar docker image

Posted by GitBox <gi...@apache.org>.
michaeljmarshall commented on a change in pull request #14513:
URL: https://github.com/apache/pulsar/pull/14513#discussion_r816994480



##########
File path: docker/pulsar/Dockerfile
##########
@@ -51,6 +51,7 @@ ARG UBUNTU_MIRROR=mirror://mirrors.ubuntu.com/mirrors.txt
 
 # Install some utilities
 RUN sed -i "s|http://archive\.ubuntu\.com/ubuntu/|${UBUNTU_MIRROR:-mirror://mirrors.ubuntu.com/mirrors.txt}|g" /etc/apt/sources.list \
+     && echo 'Acquire::http::Timeout "30";\nAcquire::ftp::Timeout "30";\nAcquire::Retries "3";' > /etc/apt/apt.conf.d/99timeout_and_retries \

Review comment:
       @lhotari - I think we should add a line at the end of this `RUN` directive that removes `/etc/apt/apt.conf.d/99timeout_and_retries`. I don't think there is a reason to leave this configuration in the container image for derivative images or for the container runtime.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] michaeljmarshall commented on a change in pull request #14513: [Dockerfile] Enable retries for apt-get when building Pulsar docker image

Posted by GitBox <gi...@apache.org>.
michaeljmarshall commented on a change in pull request #14513:
URL: https://github.com/apache/pulsar/pull/14513#discussion_r816994480



##########
File path: docker/pulsar/Dockerfile
##########
@@ -51,6 +51,7 @@ ARG UBUNTU_MIRROR=mirror://mirrors.ubuntu.com/mirrors.txt
 
 # Install some utilities
 RUN sed -i "s|http://archive\.ubuntu\.com/ubuntu/|${UBUNTU_MIRROR:-mirror://mirrors.ubuntu.com/mirrors.txt}|g" /etc/apt/sources.list \
+     && echo 'Acquire::http::Timeout "30";\nAcquire::ftp::Timeout "30";\nAcquire::Retries "3";' > /etc/apt/apt.conf.d/99timeout_and_retries \

Review comment:
       @lhotari - I think we should consider adding a line at the end of this `RUN` directive that removes `/etc/apt/apt.conf.d/99timeout_and_retries`. I don't think there is a reason to leave this configuration in the container image for derivative images or for the container runtime.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] lhotari commented on a change in pull request #14513: [Dockerfile] Enable retries for apt-get when building Pulsar docker image

Posted by GitBox <gi...@apache.org>.
lhotari commented on a change in pull request #14513:
URL: https://github.com/apache/pulsar/pull/14513#discussion_r817137324



##########
File path: docker/pulsar/Dockerfile
##########
@@ -51,6 +51,7 @@ ARG UBUNTU_MIRROR=mirror://mirrors.ubuntu.com/mirrors.txt
 
 # Install some utilities
 RUN sed -i "s|http://archive\.ubuntu\.com/ubuntu/|${UBUNTU_MIRROR:-mirror://mirrors.ubuntu.com/mirrors.txt}|g" /etc/apt/sources.list \
+     && echo 'Acquire::http::Timeout "30";\nAcquire::ftp::Timeout "30";\nAcquire::Retries "3";' > /etc/apt/apt.conf.d/99timeout_and_retries \

Review comment:
       > I don't think there is a reason to leave this configuration in the container image for derivative images or for the container runtime.
   
   Why not? It's a better default for everyone and won't be harmful. 
   In Ubuntu, retries have been added by default for apt since Ubuntu 21.04 (Hirsute) according to https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1876035 .
   
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] lhotari merged pull request #14513: [Dockerfile] Enable retries for apt-get when building Pulsar docker image

Posted by GitBox <gi...@apache.org>.
lhotari merged pull request #14513:
URL: https://github.com/apache/pulsar/pull/14513


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] michaeljmarshall commented on a change in pull request #14513: [Dockerfile] Enable retries for apt-get when building Pulsar docker image

Posted by GitBox <gi...@apache.org>.
michaeljmarshall commented on a change in pull request #14513:
URL: https://github.com/apache/pulsar/pull/14513#discussion_r817155077



##########
File path: docker/pulsar/Dockerfile
##########
@@ -51,6 +51,7 @@ ARG UBUNTU_MIRROR=mirror://mirrors.ubuntu.com/mirrors.txt
 
 # Install some utilities
 RUN sed -i "s|http://archive\.ubuntu\.com/ubuntu/|${UBUNTU_MIRROR:-mirror://mirrors.ubuntu.com/mirrors.txt}|g" /etc/apt/sources.list \
+     && echo 'Acquire::http::Timeout "30";\nAcquire::ftp::Timeout "30";\nAcquire::Retries "3";' > /etc/apt/apt.conf.d/99timeout_and_retries \

Review comment:
       @lhotari - thanks for the context, sounds good to me.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] lhotari closed pull request #14513: [Dockerfile] Enable retries for apt-get when building Pulsar docker image

Posted by GitBox <gi...@apache.org>.
lhotari closed pull request #14513:
URL: https://github.com/apache/pulsar/pull/14513


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org