如何从 grails 的 url 中删除应用程序名称和端口? [英] How to remove app name and port from url in grails?

查看:22
本文介绍了如何从 grails 的 url 中删除应用程序名称和端口?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

而不是将我的应用部署到

Instead of deploying my app to

http://localhost:8080/myApp

我想将它部署到

http://localhost

推荐答案

要更改 run-app 端口,请编辑 grails-app/conf/BuildConfig.groovy 并添加行

To change the run-app port, edit grails-app/conf/BuildConfig.groovy and add the line

grails.server.port.http = 80

要删除上下文(myApp"部分),请编辑 application.properties 并添加行

To remove the context (the 'myApp' part) edit application.properties and add the line

app.context=/

这篇关于如何从 grails 的 url 中删除应用程序名称和端口?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆