Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
apollo
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
openSource
apollo
Commits
d6779624
Commit
d6779624
authored
Apr 28, 2016
by
Yiming Liu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update start script by leverage spring boot launch
parent
39fb6a84
Show whitespace changes
Inline
Side-by-side
Showing
23 changed files
with
135 additions
and
73 deletions
+135
-73
pom.xml
apollo-adminservice/pom.xml
+3
-0
assembly-descriptor.xml
apollo-adminservice/src/assembly/assembly-descriptor.xml
+14
-2
apollo-adminservice.conf
apollo-adminservice/src/main/config/apollo-adminservice.conf
+4
-0
logback.xml
apollo-adminservice/src/main/resources/logback.xml
+11
-0
env.sh
apollo-adminservice/src/main/scripts/env.sh
+0
-0
shutdown.sh
apollo-adminservice/src/main/scripts/shutdown.sh
+2
-4
startup.sh
apollo-adminservice/src/main/scripts/startup.sh
+11
-3
application-dev.example.properties
...biz/src/main/resources/application-dev.example.properties
+4
-0
application.properties
apollo-biz/src/main/resources/application.properties
+0
-1
common.sh
apollo-buildtools/src/main/scripts/common.sh
+0
-47
assembly-descriptor.xml
apollo-configservice/src/assembly/assembly-descriptor.xml
+13
-1
apollo-configservice.conf
...o-configservice/src/main/config/apollo-configservice.conf
+3
-0
logback.xml
apollo-configservice/src/main/resources/logback.xml
+11
-0
env.sh
apollo-configservice/src/main/scripts/env.sh
+0
-0
shutdown.sh
apollo-configservice/src/main/scripts/shutdown.sh
+3
-4
startup.sh
apollo-configservice/src/main/scripts/startup.sh
+12
-3
pom.xml
apollo-portal/pom.xml
+3
-0
assembly-descriptor.xml
apollo-portal/src/assembly/assembly-descriptor.xml
+13
-1
apollo-portal.conf
apollo-portal/src/main/config/apollo-portal.conf
+3
-0
logback.xml
apollo-portal/src/main/resources/logback.xml
+11
-0
env.sh
apollo-portal/src/main/scripts/env.sh
+0
-0
shutdown.sh
apollo-portal/src/main/scripts/shutdown.sh
+2
-4
startup.sh
apollo-portal/src/main/scripts/startup.sh
+12
-3
No files found.
apollo-adminservice/pom.xml
View file @
d6779624
...
...
@@ -83,6 +83,9 @@
<plugin>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-maven-plugin
</artifactId>
<configuration>
<executable>
true
</executable>
</configuration>
</plugin>
<plugin>
<artifactId>
maven-assembly-plugin
</artifactId>
...
...
apollo-adminservice/src/assembly/assembly-descriptor.xml
View file @
d6779624
...
...
@@ -12,7 +12,7 @@
<useAllReactorProjects>
true
</useAllReactorProjects>
<includes>
<include>
*:apollo-buildtools:*
</include>
<include>
*:apollo-adminervice:*
</include>
<include>
*:apollo-admin
s
ervice:*
</include>
</includes>
<sources>
<includeModuleDirectory>
false
</includeModuleDirectory>
...
...
@@ -30,6 +30,18 @@
<fileSet>
<directory>
src/main/config
</directory>
<outputDirectory>
config
</outputDirectory>
<excludes>
<exclude>
apollo-adminservice.conf
</exclude>
</excludes>
<lineEnding>
unix
</lineEnding>
</fileSet>
<fileSet>
<directory>
src/main/config
</directory>
<outputDirectory>
/
</outputDirectory>
<includes>
<include>
apollo-adminservice.conf
</include>
</includes>
<lineEnding>
unix
</lineEnding>
</fileSet>
<!--artifact -->
<fileSet>
...
...
@@ -38,7 +50,7 @@
<includes>
<include>
${project.artifactId}-*.jar
</include>
</includes>
<fileMode>
0
444
</fileMode>
<fileMode>
0
755
</fileMode>
</fileSet>
</fileSets>
</sources>
...
...
apollo-adminservice/src/main/config/apollo-adminservice.conf
0 → 100644
View file @
d6779624
MODE
=
service
PID_FOLDER
=.
LOG_FOLDER
=/
opt
/
logs
/
100003172
/
\ No newline at end of file
apollo-adminservice/src/main/resources/logback.xml
0 → 100644
View file @
d6779624
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<include
resource=
"org/springframework/boot/logging/logback/defaults.xml"
/>
<property
name=
"LOG_FILE"
value=
"${LOG_FILE:-${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}/}apollo-adminservice.log}"
/>
<include
resource=
"org/springframework/boot/logging/logback/file-appender.xml"
/>
<root
level=
"INFO"
>
<appender-ref
ref=
"FILE"
/>
</root>
</configuration>
\ No newline at end of file
apollo-adminservice/src/main/scripts/env.sh
deleted
100644 → 0
View file @
39fb6a84
apollo-adminservice/src/main/scripts/shutdown.sh
View file @
d6779624
#!/bin/bash
SERVICE_NAME
=
apollo-adminservice
PATH_TO_JAR
=
$SERVICE_NAME
"-0.0.1-SNAPSHOT.jar"
LOG_PATH
=
/opt/logs/100003172/
cd
`
dirname
$0
`
/..
source
bin/common.sh stop
\ No newline at end of file
./
$SERVICE_NAME
".jar"
stop
apollo-adminservice/src/main/scripts/startup.sh
View file @
d6779624
#!/bin/bash
SERVICE_NAME
=
apollo-adminservice
PATH_TO_JAR
=
$SERVICE_NAME
"-0.0.1-SNAPSHOT.jar"
LOG_PATH
=
/opt/logs/100003172/
VERSION
=
0.0.1-SNAPSHOT
PATH_TO_JAR
=
$SERVICE_NAME
"-"
$VERSION
".jar"
cd
`
dirname
$0
`
/..
source
bin/common.sh start
if
[[
-f
$SERVICE_NAME
".jar"
]]
;
then
rm
-rf
$SERVICE_NAME
".jar"
fi
ln
$PATH_TO_JAR
$SERVICE_NAME
".jar"
./
$SERVICE_NAME
".jar"
start
exit
0
;
\ No newline at end of file
apollo-biz/src/main/resources/application-dev.example.properties
0 → 100644
View file @
d6779624
# DataSource
spring.datasource.url
=
spring.datasource.username =
spring.datasource.password
=
apollo-biz/src/main/resources/application.properties
View file @
d6779624
...
...
@@ -7,4 +7,3 @@ spring.datasource.validationQuery=SELECT 1
spring.jpa.hibernate.naming_strategy
=
org.hibernate.cfg.EJB3NamingStrategy
spring.jpa.hibernate.globally_quoted_identifiers
=
true
spring.jpa.properties.hibernate.globally_quoted_identifiers
=
true
spring.jpa.properties.hibernate.show_sql
=
true
apollo-buildtools/src/main/scripts/common.sh
deleted
100644 → 0
View file @
39fb6a84
#!/bin/bash
# directories
SYSOUT_LOG
=
$LOG_PATH
/sysout.log
mkdir
-p
$LOG_PATH
PID_PATH_NAME
=
$SERVICE_NAME
".pid"
case
$1
in
start
)
echo
"Starting
$SERVICE_NAME
..."
if
[
!
-f
$PID_PATH_NAME
]
;
then
nohup
java
-jar
$PATH_TO_JAR
/tmp 2>>
$SYSOUT_LOG
>>
$SYSOUT_LOG
&
echo
$!
>
$PID_PATH_NAME
echo
"
$SERVICE_NAME
started ..."
else
echo
"
$SERVICE_NAME
is already running ..."
fi
;;
stop
)
if
[
-f
$PID_PATH_NAME
]
;
then
PID
=
$(
cat
$PID_PATH_NAME
)
;
echo
"
$SERVICE_NAME
stopping ..."
kill
$PID
;
echo
"
$SERVICE_NAME
stopped ..."
rm
$PID_PATH_NAME
else
echo
"
$SERVICE_NAME
is not running ..."
fi
;;
restart
)
if
[
-f
$PID_PATH_NAME
]
;
then
PID
=
$(
cat
$PID_PATH_NAME
)
;
echo
"
$SERVICE_NAME
stopping ..."
;
kill
$PID
;
echo
"
$SERVICE_NAME
stopped ..."
;
rm
$PID_PATH_NAME
echo
"
$SERVICE_NAME
starting ..."
nohup
java
-jar
$PATH_TO_JAR
/tmp 2>>
$SYSOUT_LOG
>>
$SYSOUT_LOG
&
echo
$!
>
$PID_PATH_NAME
echo
"
$SERVICE_NAME
started ..."
else
echo
"
$SERVICE_NAME
is not running ..."
fi
;;
esac
exit
0
\ No newline at end of file
apollo-configservice/src/assembly/assembly-descriptor.xml
View file @
d6779624
...
...
@@ -30,6 +30,18 @@
<fileSet>
<directory>
src/main/config
</directory>
<outputDirectory>
config
</outputDirectory>
<excludes>
<exclude>
apollo-configservice.conf
</exclude>
</excludes>
<lineEnding>
unix
</lineEnding>
</fileSet>
<fileSet>
<directory>
src/main/config
</directory>
<outputDirectory>
/
</outputDirectory>
<includes>
<include>
apollo-configservice.conf
</include>
</includes>
<lineEnding>
unix
</lineEnding>
</fileSet>
<!--artifact -->
<fileSet>
...
...
@@ -38,7 +50,7 @@
<includes>
<include>
${project.artifactId}-*.jar
</include>
</includes>
<fileMode>
0
444
</fileMode>
<fileMode>
0
755
</fileMode>
</fileSet>
</fileSets>
</sources>
...
...
apollo-configservice/src/main/config/apollo-configservice.conf
0 → 100644
View file @
d6779624
MODE
=
service
PID_FOLDER
=.
LOG_FOLDER
=/
opt
/
logs
/
100003171
/
apollo-configservice/src/main/resources/logback.xml
0 → 100644
View file @
d6779624
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<include
resource=
"org/springframework/boot/logging/logback/defaults.xml"
/>
<property
name=
"LOG_FILE"
value=
"${LOG_FILE:-${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}/}apollo-configservice.log}"
/>
<include
resource=
"org/springframework/boot/logging/logback/file-appender.xml"
/>
<root
level=
"INFO"
>
<appender-ref
ref=
"FILE"
/>
</root>
</configuration>
\ No newline at end of file
apollo-configservice/src/main/scripts/env.sh
deleted
100644 → 0
View file @
39fb6a84
apollo-configservice/src/main/scripts/shutdown.sh
View file @
d6779624
#!/bin/bash
SERVICE_NAME
=
apollo-configservice
PATH_TO_JAR
=
$SERVICE_NAME
"-0.0.1-SNAPSHOT.jar"
LOG_PATH
=
/opt/logs/100003171/
source
bin/common.sh stop
\ No newline at end of file
cd
`
dirname
$0
`
/..
./
$SERVICE_NAME
".jar"
stop
\ No newline at end of file
apollo-configservice/src/main/scripts/startup.sh
View file @
d6779624
#!/bin/bash
SERVICE_NAME
=
apollo-configservice
PATH_TO_JAR
=
$SERVICE_NAME
"-0.0.1-SNAPSHOT.jar"
LOG_PATH
=
/opt/logs/100003171/
VERSION
=
0.0.1-SNAPSHOT
PATH_TO_JAR
=
$SERVICE_NAME
"-"
$VERSION
".jar"
cd
`
dirname
$0
`
/..
source
bin/common.sh start
if
[[
-f
$SERVICE_NAME
".jar"
]]
;
then
rm
-rf
$SERVICE_NAME
".jar"
fi
ln
$PATH_TO_JAR
$SERVICE_NAME
".jar"
./
$SERVICE_NAME
".jar"
start
exit
0
;
\ No newline at end of file
apollo-portal/pom.xml
View file @
d6779624
...
...
@@ -29,6 +29,9 @@
<plugin>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-maven-plugin
</artifactId>
<configuration>
<executable>
true
</executable>
</configuration>
</plugin>
<plugin>
<artifactId>
maven-assembly-plugin
</artifactId>
...
...
apollo-portal/src/assembly/assembly-descriptor.xml
View file @
d6779624
...
...
@@ -30,6 +30,18 @@
<fileSet>
<directory>
src/main/config
</directory>
<outputDirectory>
config
</outputDirectory>
<excludes>
<exclude>
apollo-portal.conf
</exclude>
</excludes>
<lineEnding>
unix
</lineEnding>
</fileSet>
<fileSet>
<directory>
src/main/config
</directory>
<outputDirectory>
/
</outputDirectory>
<includes>
<include>
apollo-portal.conf
</include>
</includes>
<lineEnding>
unix
</lineEnding>
</fileSet>
<!--artifact -->
<fileSet>
...
...
@@ -38,7 +50,7 @@
<includes>
<include>
${project.artifactId}-*.jar
</include>
</includes>
<fileMode>
0
444
</fileMode>
<fileMode>
0
755
</fileMode>
</fileSet>
</fileSets>
</sources>
...
...
apollo-portal/src/main/config/apollo-portal.conf
0 → 100644
View file @
d6779624
MODE
=
service
PID_FOLDER
=.
LOG_FOLDER
=/
opt
/
logs
/
100003173
/
apollo-portal/src/main/resources/logback.xml
0 → 100644
View file @
d6779624
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<include
resource=
"org/springframework/boot/logging/logback/defaults.xml"
/>
<property
name=
"LOG_FILE"
value=
"${LOG_FILE:-${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}/}apollo-portal.log}"
/>
<include
resource=
"org/springframework/boot/logging/logback/file-appender.xml"
/>
<root
level=
"INFO"
>
<appender-ref
ref=
"FILE"
/>
</root>
</configuration>
\ No newline at end of file
apollo-portal/src/main/scripts/env.sh
deleted
100644 → 0
View file @
39fb6a84
apollo-portal/src/main/scripts/shutdown.sh
View file @
d6779624
#!/bin/bash
SERVICE_NAME
=
apollo-portal
PATH_TO_JAR
=
$SERVICE_NAME
"-0.0.1-SNAPSHOT.jar"
LOG_PATH
=
/opt/logs/100003173/
cd
`
dirname
$0
`
/..
source
bin/common.sh stop
\ No newline at end of file
./
$SERVICE_NAME
".jar"
stop
\ No newline at end of file
apollo-portal/src/main/scripts/startup.sh
View file @
d6779624
#!/bin/bash
SERVICE_NAME
=
apollo-portal
PATH_TO_JAR
=
$SERVICE_NAME
"-0.0.1-SNAPSHOT.jar"
LOG_PATH
=
/opt/logs/100003173/
VERSION
=
0.0.1-SNAPSHOT
PATH_TO_JAR
=
$SERVICE_NAME
"-"
$VERSION
".jar"
cd
`
dirname
$0
`
/..
source
bin/common.sh start
if
[[
-f
$SERVICE_NAME
".jar"
]]
;
then
rm
-rf
$SERVICE_NAME
".jar"
fi
ln
$PATH_TO_JAR
$SERVICE_NAME
".jar"
./
$SERVICE_NAME
".jar"
start
exit
0
;
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment