Docker 的一些指令记录 发表于 2021-05-18 更新于 2021-05-23 阅读次数: 有些指令啊,经常忘记哈哈哈哈。干脆直接记在这里吧!!! 启动 nginx 和挂载1docker run -d -p 80:80 --name nginx-web -v ~/nginx/www:/usr/share/nginx/html -v ~/nginx/conf/nginx.conf:/etc/nginx/nginx.conf -v ~/nginx/logs:/var/log/nginx nginx nginx 配置代理12345678910location / { proxy_ignore_client_abort on; root /usr/share/nginx/html; index index.html; } location ^~ /api/ { proxy_pass http://121.4.162.86:8081; proxy_set_header Host $host:$server_port; }