美文网首页
win10 docker 使用tinyproxy搭建并配置htt

win10 docker 使用tinyproxy搭建并配置htt

作者: mudssky | 来源:发表于2019-05-23 15:31 被阅读0次

win10下使用docker,会下载一个docker desktop,通过gui可以很方便进行一些基础的设置。

问题是我们需要搭建一个http/https代理。

一开始我想找找nginx有没有相关功能,但是貌似默认不支持https,并且配置有些麻烦所以放弃了。

常用的支持http/https的代理软件有以下几个

squid,trafficserver Apache Traffic Server Manual,tinyproxy Tinyproxy

也有基于python的:
exaproxy http://code.google.com/p/exaproxy/
mitmproxy http://mitmproxy.org/

还有跨平台且有GUI的 Charles Charles Web Debugging Proxy • HTTP Monitor / HTTP Proxy / HTTPS & SSL Proxy / Reverse Proxy

01.ubuntu下安装tinyproxy

我选择使用tinyproxy,配置十分简单。

我的vps系统为 ubuntu18.04

直接使用apt-get安装tinyproxy

apt-get install tinyproxy

02.tinyproxy配置以及基本命令

先启动服务

# 启动
service tinyproxy start

# 停止
service tinyproxy stop

# 重启
service tinyproxy restart

配置文件路径

/etc/tinyproxy/tinyproxy.conf

修改配置文件,端口号进行修改(默认8888)

再设置调整允许使用代理的ip

Port 1234
# Allow 127.0.0.1 注释掉这一条允许所有人使用

设置好后重启服务就可用了

想查看其他文档可以去,tiny官方站点 https://tinyproxy.github.io/

执行docker search 可以搜索到镜像了

PS C:\Users\mudssky\Desktop> docker search ubuntu
NAME                                                   DESCRIPTION                                     STARS               OFFICIAL            AUTOMATED
ubuntu                                                 Ubuntu is a Debian-based Linux operating sys…   9560                [OK]
dorowu/ubuntu-desktop-lxde-vnc                         Docker image to provide HTML5 VNC interface …   303                                     [OK]
rastasheep/ubuntu-sshd                                 Dockerized SSH service, built on top of offi…   216                                     [OK]
consol/ubuntu-xfce-vnc                                 Ubuntu container with "headless" VNC session…   178                                     [OK]
ubuntu-upstart                                         Upstart is an event-based replacement for th…   98                  [OK]
ansible/ubuntu14.04-ansible                            Ubuntu 14.04 LTS with ansible                   96                                      [OK]
neurodebian                                            NeuroDebian provides neuroscience research s…   57                  [OK]
1and1internet/ubuntu-16-nginx-php-phpmyadmin-mysql-5   ubuntu-16-nginx-php-phpmyadmin-mysql-5          50                                      [OK]
ubuntu-debootstrap                                     debootstrap --variant=minbase --components=m…   40                  [OK]
nuagebec/ubuntu                                        Simple always updated Ubuntu docker images w…   23                                      [OK]
i386/ubuntu                                            Ubuntu is a Debian-based Linux operating sys…   17
1and1internet/ubuntu-16-apache-php-7.0                 ubuntu-16-apache-php-7.0                        13                                      [OK]
ppc64le/ubuntu                                         Ubuntu is a Debian-based Linux operating sys…   13
eclipse/ubuntu_jdk8                                    Ubuntu, JDK8, Maven 3, git, curl, nmap, mc, …   11                                      [OK]
1and1internet/ubuntu-16-nginx-php-5.6-wordpress-4      ubuntu-16-nginx-php-5.6-wordpress-4             7                                       [OK]
codenvy/ubuntu_jdk8                                    Ubuntu, JDK8, Maven 3, git, curl, nmap, mc, …   5                                       [OK]
darksheer/ubuntu                                       Base Ubuntu Image -- Updated hourly             5                                       [OK]
pivotaldata/ubuntu                                     A quick freshening-up of the base Ubuntu doc…   2
smartentry/ubuntu                                      ubuntu with smartentry                          1                                       [OK]
1and1internet/ubuntu-16-sshd                           ubuntu-16-sshd                                  1                                       [OK]
1and1internet/ubuntu-16-php-7.1                        ubuntu-16-php-7.1                               1                                       [OK]
paasmule/bosh-tools-ubuntu                             Ubuntu based bosh-cli                           1                                       [OK]
ossobv/ubuntu                                          Custom ubuntu image from scratch (based on o…   0
pivotaldata/ubuntu16.04-build                          Ubuntu 16.04 image for GPDB compilation         0
pivotaldata/ubuntu-gpdb-dev                            Ubuntu images for GPDB development              0

相关文章

网友评论

      本文标题:win10 docker 使用tinyproxy搭建并配置htt

      本文链接:https://www.haomeiwen.com/subject/cuqbzqtx.html