{"id":173,"date":"2018-06-05T04:38:35","date_gmt":"2018-06-05T10:38:35","guid":{"rendered":"https:\/\/ha.lc\/?p=173"},"modified":"2018-06-05T04:38:55","modified_gmt":"2018-06-05T10:38:55","slug":"173","status":"publish","type":"post","link":"https:\/\/ha.lc\/?p=173","title":{"rendered":"Configurar proxy para APT"},"content":{"rendered":"<p><a href=\"https:\/\/stackoverflow.com\/questions\/25322280\/how-can-i-configure-a-http-proxy-for-apt-get\">https:\/\/stackoverflow.com\/questions\/25322280\/how-can-i-configure-a-http-proxy-for-apt-get<\/a><\/p>\n<p>&nbsp;<\/p>\n<div class=\"votecell post-layout--left\">\n<div class=\"vote\"><span class=\"vote-count-post \">\u00a0<\/span><\/div>\n<\/div>\n<div class=\"answercell post-layout--right\">\n<div class=\"post-text\">\n<p>I managed to solve it in the following way. Go to the following folder:<\/p>\n<pre><code>cd \/etc\/apt\/apt.conf.d\r\n<\/code><\/pre>\n<p>Create a file named <code>10proxy<\/code>:<\/p>\n<pre><code>sudo nano 10proxy\r\n<\/code><\/pre>\n<p>Without authentication add the following line:<\/p>\n<pre><code>Acquire::http::Proxy \"http:\/\/yourproxyaddress:proxyport\/\";\r\n<\/code><\/pre>\n<p>With authentication:<\/p>\n<pre><code>Acquire::http::Proxy \"http:\/\/username:password@yourproxyaddress:proxyport\/\";\r\n<\/code><\/pre>\n<p>The <code>\/<\/code>at the very end was important. Without it it did not work.<\/p>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>https:\/\/stackoverflow.com\/questions\/25322280\/how-can-i-configure-a-http-proxy-for-apt-get &nbsp; \u00a0 I managed to solve it in the following way. Go to the following folder: cd \/etc\/apt\/apt.conf.d Create a file named 10proxy: sudo nano 10proxy Without authentication add the following line: Acquire::http::Proxy &#8220;http:\/\/yourproxyaddress:proxyport\/&#8221;; With authentication: Acquire::http::Proxy &#8220;http:\/\/username:password@yourproxyaddress:proxyport\/&#8221;; The \/at the very end was important. Without it it did not work.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[],"_links":{"self":[{"href":"https:\/\/ha.lc\/index.php?rest_route=\/wp\/v2\/posts\/173"}],"collection":[{"href":"https:\/\/ha.lc\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ha.lc\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ha.lc\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ha.lc\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=173"}],"version-history":[{"count":2,"href":"https:\/\/ha.lc\/index.php?rest_route=\/wp\/v2\/posts\/173\/revisions"}],"predecessor-version":[{"id":175,"href":"https:\/\/ha.lc\/index.php?rest_route=\/wp\/v2\/posts\/173\/revisions\/175"}],"wp:attachment":[{"href":"https:\/\/ha.lc\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=173"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ha.lc\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=173"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ha.lc\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=173"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}