Vue项目部署过程记录
服务器
server{ listen 80; listen 443 ssl; ssl_certificate /usr/local/nginx/cert/your.crt; ssl_certificate_key /usr/local/nginx/cert/your.key; ssl_session_timeout 5m; ssl_protocols TLSv1 TLSv1.1 TLSv1.2; ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE; ssl_prefer_server_ciphers on;
server_name www.demo.com; root /home/wwwroot/vue/demo/dist/; location / {
index index.html index.htm;
try_files $uri $uri/ /index.html; } location /api { proxy_pass http://api.demo.com; } access_log /home/wwwlogs/access/default.log; }