apache - 在多个 URL 上使用相同的 tomcat 实例
问题描述
我的服务器 opxxx01(FQDN:opxxx01.domain.com)上运行了一个 tomcat 实例,一切正常。但我想在另一个 URL 上显示相同的实例: quietude.anotherdomain.com
我阅读了很多关于此的主题,但对我没有任何帮助:
在 opxxx01.domain.com --> OK
在 quietude.anotherdomain.com --> KO
上下文:Red Hat Enterprise Linux Server release 7.4 (Maipo);雄猫 8.5.30;阿帕奇 2.4.6
您可以在下面看到我的代码,但 quietude.anotherdomain.com 上没有显示任何内容。
谢谢你的帮助 :)
<Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true">
<Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
prefix="localhost_access_log" suffix=".txt"
pattern="%h %l %u %t "%r" %s %b %S %D %F" />
<Valve className="org.apache.catalina.valves.ErrorReportValve" showReport="false" showServerInfo="false" />
</Host>
<!-- I added these lines below -->
<Host name="quietude.anotherdomain.com" appBase="webapps" unpackWARs="true" autoDeploy="true">
<Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
prefix="quietude_access_log" suffix=".txt"
pattern="%h %l %u %t "%r" %s %b %S %D %F" />
</Host>
解决方案
我终于找到了!
我的文件app.f2e312e439be13da8b85.js,我改变:
http://opxxx01.domain.com/downloads/quietude_result.csv
经过
/downloads/quietude_result.csv
在我的文件Statistics.vue中,我更改:
axios.get('http://opxxx01.domain.com/downloads/quietude_result.csv').then(response => {
经过
axios.get('/downloads/quietude_result.csv').then(response => {
推荐阅读
- r - 将具有 NA 值的时间序列转换为 r 中的数据帧时出错
- node.js - 无法使用 npm i cypress -g 从 Node 包安装 cypress
- google-apps-script - 使用人员 API 将联系人添加到组时出错
- reactjs - 状态更改后反应组件渲染延迟工作
- javascript - 如何合并 2 个循环,使对象的值重叠?
- bigbluebutton - 我可以在 Heroku 上使用 bigbluebutton 服务器吗?
- c++ - 是否有一种“简单”的方法可以让 ld 输出解组函数名称?
- apache-nifi - NiFi MergeContent 不处理流文件
- arrays - 将二维数组传递给 C 中的函数时的意外行为
- php - PHP联系表格刚刚..停止..工作