使用 ../gradlew server不能使用配置文件
linux配置:
# Determine the Java command to use to start the JVM. if [ -n "/app/jdk1.8.0_111" ] ; then if [ -x "/app/jdk1.8.0_111/jre/bin/java" ] ; then # IBM's JDK on AIX uses strange locations for the executables JAVACMD="/app/jdk1.8.0_111/jre/bin/java" else JAVACMD="/app/jdk1.8.0_111/bin/java" fi if [ ! -x "$JAVACMD" ] ; then die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME Please set the JAVA_HOME variable in your environment to match the location of your Java installation." fi else JAVACMD="java" which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. Please set the JAVA_HOME variable in your environment to match the location of your Java installation."
2.修改swagger的访问ip
server/ser/main/resource/swagger-ui/index.html文件
var url = window.location.search.match(/url=([^&]+)/); //http://127.0.0.1:8080/?url=127.0.0.1:8080 if (url && url.length > 1) { url = decodeURIComponent(url[1]); } else { url = "180.101.125.105:8080"; }
3.后台启动:
nohup java -jar conductor-server-2.6.0-SNAPSHOT-all.jar ../../src/main/resources/server.properties >output.log & >output.log可以不写,会使用默认的nohup.out文件
#UI启动
注意:linux下需要先修改/ui/gulpfile.babel.js的内容:

1.安装node.js(因为gulp基于nodejs)
官网https://nodejs.org/en/ 下载系统信息选择对应版本(.msi文件)
查看版本: node -v ;npm -v
2.安装cnpm:
npm install -g cnpm –registry=https://registry.npm.taobao.org
发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/211144.html原文链接:https://javaforall.net
