Warning: Undefined array key 1 in /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php on line 505

Warning: Undefined array key 2 in /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php on line 505

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php on line 557

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930

Warning: Cannot modify header information - headers already sent by (output started at /home/yogindar/www/blog/wp-content/plugins/visitors-online/visitors-online.php:505) in /home/yogindar/www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1930
{"id":2579,"date":"2025-01-21T05:32:09","date_gmt":"2025-01-21T05:32:09","guid":{"rendered":"http:\/\/www.yogindar.com\/news\/?p=2579"},"modified":"2025-01-21T05:32:09","modified_gmt":"2025-01-21T05:32:09","slug":"adding-http-https-proxy-for-docker-image-downloads","status":"publish","type":"post","link":"http:\/\/blog.yogindar.org\/?p=2579","title":{"rendered":"Adding HTTP\/HTTPS proxy for docker image downloads"},"content":{"rendered":"

As part of development your lab network or corporate network might be under a proxy network to download docker images.
\nThis article explains on how to add HTTP\/HTTPS proxy to download the docker images in a corporate environment.<\/p>\n

Add the below lines<\/p>\n

\n[Service]
\nEnvironment=”HTTP_PROXY=http:\/\/proxy.mycompany.com:80\/”<\/p><\/blockquote>\n

in \/etc\/systemd\/system\/docker.service.d\/http-proxy.conf<\/p>\n

and<\/p>\n

[Service]
\nEnvironment=”HTTPS_PROXY=https:\/\/proxy.mycompany.com:443\/”<\/p><\/blockquote>\n

in \/etc\/systemd\/system\/docker.service.d\/https-proxy.conf<\/p>\n

Replace proxy.mycompany.com with your companies proxy server details.<\/p>\n

Additionally add nameserver entry also to resolve hostnames.<\/p>\n

#Use your DNS server details.
\nnameserver 172.10.22.1<\/p><\/blockquote>\n

in \/etc\/resolv.conf<\/p>\n

Once added restart docker daemon and reload. Commands below.<\/p>\n

\n$ sudo systemctl daemon-reload
\n$ sudo systemctl restart docker<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"

As part of development your lab network or corporate network might be under a proxy network to download docker images. This article explains on how to add HTTP\/HTTPS proxy to download the docker images in a corporate environment. Add the below lines [Service] Environment=”HTTP_PROXY=http:\/\/proxy.mycompany.com:80\/” in \/etc\/systemd\/system\/docker.service.d\/http-proxy.conf and [Service] Environment=”HTTPS_PROXY=https:\/\/proxy.mycompany.com:443\/” in \/etc\/systemd\/system\/docker.service.d\/https-proxy.conf Replace proxy.mycompany.com with your […]<\/p>\n","protected":false},"author":29,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1699],"tags":[1700,1701,1702,1462,1703],"class_list":["post-2579","post","type-post","status-publish","format-standard","hentry","category-docker","tag-docker","tag-http","tag-https","tag-linux","tag-proxy"],"_links":{"self":[{"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=\/wp\/v2\/posts\/2579","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=\/wp\/v2\/users\/29"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2579"}],"version-history":[{"count":1,"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=\/wp\/v2\/posts\/2579\/revisions"}],"predecessor-version":[{"id":2580,"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=\/wp\/v2\/posts\/2579\/revisions\/2580"}],"wp:attachment":[{"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2579"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2579"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.yogindar.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2579"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}