Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vue.js单页移动应用服务端部署方法 #5

Open
firekyrin opened this issue Dec 8, 2016 · 0 comments
Open

vue.js单页移动应用服务端部署方法 #5

firekyrin opened this issue Dec 8, 2016 · 0 comments

Comments

@firekyrin
Copy link
Owner

Apache部署

如果只使用Apache做HTTP服务器,可以设置Apache的url重定向,将所有的请求路由到index.html

打开~\Apache\conf\httpd.conf文件
去除httpd.conf文件中LoadModule rewrite_module modules/mod_rewrite.so前面的#号
在httpd.conf文件中添加重定向规则

RewriteEngine on 
# 当访问路由地址为 /live 开头的,则将路由重定向到 /index.html
RewriteRule \/live.*$ /index.html

参考

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant