ubuntu in snap settings sock proxy

Brief introduction

ubuntu based ubuntu release and most of them default service with snap, snap is a new software package management, which is similar to a container has an application all the files and libraries, are completely independent of each application. So the benefits of using snap package is that it solves the problem of dependence between applications, making it easier to manage between applications. But the problem is caused thus it takes up more disk space.

Due to the current domestic and not snapcraft server, so use snap to install software is a very painful thing, with an average speed of only 30 ~ 40KB / s, and most snap larger package, it is easy to disconnection error.

operating

It will snap from / etc / environment reads the configuration file, so you can add the following in the file:

http_proxy="socks5://127.0.0.1:1080"
https_proxy="socks5://127.0.0.1:1080"

After adding the need to restart the snap Services:

sudo systemctl restart snapd.service

After I added the proxy configuration using snap speed will reach the company's own computer 350 ~ 450KB / s, this may be related to the use of agents, although the speed is still not fast, but the speed has been relatively before a lot faster (reportedly after the ubuntu more and more software source version of the software that comes with the software store will be replaced snap source, do not know is not true).

Guess you like

Origin www.cnblogs.com/juggerhoo/p/11635331.html