douyouyi8878 2016-08-12 16:11
浏览 18

使用.htaccess在灯环境中设置Node.js.

I have a subdomain like abc.example.com which run wordpress. And its htaccess has this

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

END WordPress

How do I make my root domain which is example.com to not use wordpress / php at all? because example.com is my suppose to be running my node.js app.

I've tried to replace line 2 with

RewriteRule / http://localhost:3000/$1 [P,L] but it broke myabc.example.com

  • 写回答

1条回答 默认 最新

  • douwei2825 2016-08-12 17:24
    关注

    Is Node installed on your server? Does your host support using Node? Verify that with your hosting, and if they do support Node, ask how you they can help you to configure your instance for use with Node.

    If they do not, consider a hosting solution that supports Node, like Heroku or Digital Ocean.

    评论

报告相同问题?

悬赏问题

  • ¥15 HFSS 中的 H 场图与 MATLAB 中绘制的 B1 场 部分对应不上
  • ¥15 如何在scanpy上做差异基因和通路富集?
  • ¥20 关于#硬件工程#的问题,请各位专家解答!
  • ¥15 关于#matlab#的问题:期望的系统闭环传递函数为G(s)=wn^2/s^2+2¢wn+wn^2阻尼系数¢=0.707,使系统具有较小的超调量
  • ¥15 FLUENT如何实现在堆积颗粒的上表面加载高斯热源
  • ¥30 截图中的mathematics程序转换成matlab
  • ¥15 动力学代码报错,维度不匹配
  • ¥15 Power query添加列问题
  • ¥50 Kubernetes&Fission&Eleasticsearch
  • ¥15 報錯:Person is not mapped,如何解決?