Axure+CentOS7+Nginx配置访问html文件
安装nginx
省略。。。
开启防护墙
通过systemctl start firewalld开启防火墙,没有任何提示即开启成功。
开放指定端口
firewall-cmd --zone=public --add-port=80/tcp --permanent
firewall-cmd --zone=public --add-port=8080/tcp --permanent
firewall-cmd --reload
假设有2个axure文件工程 demo1.rp和demo2.rp
axure导出html的文件上传到/usr/local/axurefile/demo1和/usr/local/axurefile/demo2文件夹下
nginx配置路径
vim /usr/local/nginx/conf/nginx.conf
server { listen 8080; server_name localhost; location / { root /usr/local/axurefile/demo1; index start.html; } location /demo1 { alias /usr/local/axurefile/demo1; index start.html; } location /demo2 { alias /usr/local/axurefile/demo2; index start.html; } }
重启nginx
cd /usr/local/nginx/sbin
./nginx -s reload
访问url即可以看到
相关推荐
nginxs 2020-11-14
Guanjs0 2020-11-13
小木兮子 2020-11-11
yserver 2020-11-11
ssihc0 2020-11-11
windle 2020-11-10
HanksWang 2020-11-10
liuchen0 2020-11-10
Freshairx 2020-11-10
ccschan 2020-11-10
liwf 2020-11-10
Guanjs0 2020-11-09
AderStep 2020-11-09
zrtlin 2020-11-09
mqfcu 2020-11-10
windle 2020-10-29