File tree 27 files changed +82
-88
lines changed
src/main/java/com/alibabacloud/mse/demo
src/main/java/com/alibabacloud/mse/demo
src/main/java/com/alibabacloud/mse/demo/service
27 files changed +82
-88
lines changed Original file line number Diff line number Diff line change 1
1
# syntax=docker/dockerfile:1.3-labs
2
2
3
- FROM maven:3-eclipse-temurin-8-alpine
3
+ FROM maven:3-eclipse-temurin-8-alpine as build
4
4
5
5
# copy arthas
6
6
COPY --from=hengyunabc/arthas:latest /opt/arthas /opt/arthas
@@ -15,14 +15,9 @@ COPY <<EOF /root/.m2/settings.xml
15
15
<mirror>
16
16
<id>alimaven</id>
17
17
<name>aliyun maven</name>
18
- <url>http ://maven.aliyun.com/nexus/content/groups/public/</url>
18
+ <url>https ://maven.aliyun.com/nexus/content/groups/public/</url>
19
19
<mirrorOf>central</mirrorOf>
20
20
</mirror>
21
- <mirror>
22
- <id>maven-default-http-blocker</id>
23
- <mirrorOf>!*</mirrorOf>
24
- <url>http://0.0.0.0/</url>
25
- </mirror>
26
21
</mirrors>
27
22
</settings>
28
23
EOF
@@ -34,6 +29,14 @@ COPY ./ ./
34
29
RUN --mount=type=cache,target=/root/.m2/repository/ \
35
30
mvn clean package --batch-mode
36
31
32
+
33
+ FROM dragonwell-registry.cn-hangzhou.cr.aliyuncs.com/dragonwell/dragonwell:8-extended-ga-centos
34
+
35
+ # copy arthas
36
+ COPY --from=hengyunabc/arthas:latest /opt/arthas /opt/arthas
37
+
38
+ COPY --from=build /app/target/A.jar /app/target/A.jar
39
+
37
40
EXPOSE 20001
38
41
ENTRYPOINT ["sh" , "-c" ]
39
42
CMD ["java -jar /app/target/A.jar" ]
Original file line number Diff line number Diff line change 3
3
4
4
cd " $( dirname " $0 " ) "
5
5
6
- docker build . -t ${REGISTRY} spring-cloud-a:1.1 .0
6
+ docker build . -t ${REGISTRY} spring-cloud-a:1.2 .0
7
7
8
8
if [ -n " ${REGISTRY} " ]; then
9
- docker push ${REGISTRY} spring-cloud-a:1.1 .0
9
+ docker push ${REGISTRY} spring-cloud-a:1.2 .0
10
10
fi
Original file line number Diff line number Diff line change 5
5
6
6
<groupId >com.alibabacloud.mse.demo</groupId >
7
7
<artifactId >A</artifactId >
8
- <version >1.1 .0</version >
8
+ <version >1.2 .0</version >
9
9
<packaging >jar</packaging >
10
10
11
11
<name >A</name >
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ class AController {
46
46
@ Autowired
47
47
InetUtils inetUtils ;
48
48
49
- @ Reference (application = "${dubbo.application.id}" , version = "1.1 .0" )
49
+ @ Reference (application = "${dubbo.application.id}" , version = "1.2 .0" )
50
50
private HelloServiceB helloServiceB ;
51
51
52
52
@ Autowired
Original file line number Diff line number Diff line change 6
6
import org .springframework .beans .factory .annotation .Autowired ;
7
7
import org .springframework .cloud .commons .util .InetUtils ;
8
8
9
- @ Service (version = "1.1 .0" )
9
+ @ Service (version = "1.2 .0" )
10
10
public class HelloServiceAImpl implements HelloServiceA {
11
11
12
12
@ Autowired
13
13
InetUtils inetUtils ;
14
14
15
- @ Reference (application = "${dubbo.application.id}" , version = "1.1 .0" )
15
+ @ Reference (application = "${dubbo.application.id}" , version = "1.2 .0" )
16
16
private HelloServiceB helloServiceB ;
17
17
18
18
@ Autowired
Original file line number Diff line number Diff line change @@ -15,14 +15,9 @@ COPY <<EOF /root/.m2/settings.xml
15
15
<mirror>
16
16
<id>alimaven</id>
17
17
<name>aliyun maven</name>
18
- <url>http ://maven.aliyun.com/nexus/content/groups/public/</url>
18
+ <url>https ://maven.aliyun.com/nexus/content/groups/public/</url>
19
19
<mirrorOf>central</mirrorOf>
20
20
</mirror>
21
- <mirror>
22
- <id>maven-default-http-blocker</id>
23
- <mirrorOf>!*</mirrorOf>
24
- <url>http://0.0.0.0/</url>
25
- </mirror>
26
21
</mirrors>
27
22
</settings>
28
23
EOF
Original file line number Diff line number Diff line change 2
2
3
3
cd " $( dirname " $0 " ) "
4
4
5
- docker build . -t ${REGISTRY} spring-cloud-b:1.1 .0
5
+ docker build . -t ${REGISTRY} spring-cloud-b:1.2 .0
6
6
7
7
if [ -n " ${REGISTRY} " ]; then
8
- docker push ${REGISTRY} spring-cloud-b:1.1 .0
8
+ docker push ${REGISTRY} spring-cloud-b:1.2 .0
9
9
fi
Original file line number Diff line number Diff line change 5
5
6
6
<groupId >com.alibabacloud.mse.demo</groupId >
7
7
<artifactId >B</artifactId >
8
- <version >1.1 .0</version >
8
+ <version >1.2 .0</version >
9
9
<packaging >jar</packaging >
10
10
11
11
<name >B</name >
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ class BController {
33
33
@ Qualifier ("restTemplate" )
34
34
private RestTemplate restTemplate ;
35
35
36
- @ Reference (application = "${dubbo.application.id}" , version = "1.1 .0" )
36
+ @ Reference (application = "${dubbo.application.id}" , version = "1.2 .0" )
37
37
private HelloServiceC helloServiceC ;
38
38
39
39
@ Autowired
Original file line number Diff line number Diff line change 5
5
import org .springframework .beans .factory .annotation .Autowired ;
6
6
import org .springframework .cloud .commons .util .InetUtils ;
7
7
8
- @ Service (version = "1.1 .0" )
8
+ @ Service (version = "1.2 .0" )
9
9
public class HelloServiceBImpl implements HelloServiceB {
10
10
11
11
@ Autowired
@@ -14,7 +14,7 @@ public class HelloServiceBImpl implements HelloServiceB {
14
14
@ Autowired
15
15
String serviceTag ;
16
16
17
- @ Reference (application = "${dubbo.application.id}" , version = "1.1 .0" )
17
+ @ Reference (application = "${dubbo.application.id}" , version = "1.2 .0" )
18
18
private HelloServiceC helloServiceC ;
19
19
20
20
@ Override
Original file line number Diff line number Diff line change @@ -11,14 +11,9 @@ COPY <<EOF /root/.m2/settings.xml
11
11
<mirror>
12
12
<id>alimaven</id>
13
13
<name>aliyun maven</name>
14
- <url>http ://maven.aliyun.com/nexus/content/groups/public/</url>
14
+ <url>https ://maven.aliyun.com/nexus/content/groups/public/</url>
15
15
<mirrorOf>central</mirrorOf>
16
16
</mirror>
17
- <mirror>
18
- <id>maven-default-http-blocker</id>
19
- <mirrorOf>!*</mirrorOf>
20
- <url>http://0.0.0.0/</url>
21
- </mirror>
22
17
</mirrors>
23
18
</settings>
24
19
EOF
Original file line number Diff line number Diff line change 3
3
4
4
cd " $( dirname " $0 " ) "
5
5
6
- docker build . -t ${REGISTRY} spring-cloud-c:1.1 .0
6
+ docker build . -t ${REGISTRY} spring-cloud-c:1.2 .0
7
7
8
8
if [ -n " ${REGISTRY} " ]; then
9
- docker push ${REGISTRY} spring-cloud-c:1.1 .0
9
+ docker push ${REGISTRY} spring-cloud-c:1.2 .0
10
10
fi
Original file line number Diff line number Diff line change 5
5
6
6
<groupId >com.alibabacloud.mse.demo</groupId >
7
7
<artifactId >C</artifactId >
8
- <version >1.1 .0</version >
8
+ <version >1.2 .0</version >
9
9
<packaging >jar</packaging >
10
10
11
11
<name >C</name >
Original file line number Diff line number Diff line change 14
14
import java .nio .charset .StandardCharsets ;
15
15
16
16
@ Slf4j
17
- @ DubboService (version = "1.1 .0" )
17
+ @ DubboService (version = "1.2 .0" )
18
18
@ RequiredArgsConstructor
19
19
public class HelloServiceCImpl implements HelloServiceC {
20
20
Original file line number Diff line number Diff line change @@ -14,11 +14,6 @@ COPY <<EOF /root/.m2/settings.xml
14
14
<url>https://maven.aliyun.com/nexus/content/groups/public/</url>
15
15
<mirrorOf>central</mirrorOf>
16
16
</mirror>
17
- <mirror>
18
- <id>maven-default-http-blocker</id>
19
- <mirrorOf>!*</mirrorOf>
20
- <url>http://0.0.0.0/</url>
21
- </mirror>
22
17
</mirrors>
23
18
</settings>
24
19
EOF
Original file line number Diff line number Diff line change 3
3
4
4
cd " $( dirname " $0 " ) "
5
5
6
- docker build . -t ${REGISTRY} spring-cloud-zuul:1.1 .0
6
+ docker build . -t ${REGISTRY} spring-cloud-zuul:1.2 .0
7
7
8
8
if [ -n " ${REGISTRY} " ]; then
9
- docker push ${REGISTRY} spring-cloud-zuul:1.1 .0
9
+ docker push ${REGISTRY} spring-cloud-zuul:1.2 .0
10
10
fi
Original file line number Diff line number Diff line change 5
5
6
6
<groupId >com.alibabacloud.mse.demo</groupId >
7
7
<artifactId >gateway</artifactId >
8
- <version >1.1 .0</version >
8
+ <version >1.2 .0</version >
9
9
<packaging >jar</packaging >
10
10
11
11
<parent >
Original file line number Diff line number Diff line change 1
1
apiVersion : v2
2
2
name : mse-simple-demo
3
- version : " 1.1 .0"
4
- appVersion : " 1.1 .0"
3
+ version : " 1.2 .0"
4
+ appVersion : " 1.2 .0"
5
5
home : https://mse.console.aliyun.com/
6
6
keywords :
7
7
- mse
Original file line number Diff line number Diff line change @@ -12,11 +12,12 @@ spec:
12
12
metadata :
13
13
labels :
14
14
msePilotAutoEnable : " on"
15
- appName : " {{ .Values.mse.namePrefix }}spring-cloud-zuul"
15
+ msePilotCreateAppName : " spring-cloud-zuul"
16
+ mseNamespace : " {{ .Values.mse.namespace }}"
16
17
app : spring-cloud-zuul
17
18
spec :
18
19
containers :
19
- - image : " {{ .Values.registry }}spring-cloud-zuul:1.1 .0"
20
+ - image : " {{ .Values.registry }}spring-cloud-zuul:1.2 .0"
20
21
imagePullPolicy : Always
21
22
env :
22
23
- name : nacos.host
@@ -26,11 +27,11 @@ spec:
26
27
name : " spring-cloud-zuul"
27
28
resources :
28
29
requests :
29
- cpu : 2
30
- memory : 4Gi
30
+ cpu : 1
31
+ memory : 2Gi
31
32
limits :
32
- cpu : 2
33
- memory : 4Gi
33
+ cpu : 1
34
+ memory : 2Gi
34
35
ports :
35
36
- containerPort : 20000
36
37
affinity :
File renamed without changes.
Original file line number Diff line number Diff line change @@ -12,12 +12,13 @@ spec:
12
12
metadata :
13
13
labels :
14
14
msePilotAutoEnable : " on"
15
- appName : " {{ .Values.mse.namePrefix }}spring-cloud-a"
15
+ msePilotCreateAppName : " spring-cloud-a"
16
+ mseNamespace : " {{ .Values.mse.namespace }}"
16
17
app : " spring-cloud-a"
17
18
spec :
18
19
containers :
19
20
- name : spring-cloud-a
20
- image : " {{ .Values.registry }}spring-cloud-a:1.1 .0"
21
+ image : " {{ .Values.registry }}spring-cloud-a:1.2 .0"
21
22
imagePullPolicy : Always
22
23
env :
23
24
- name : nacos.host
@@ -26,11 +27,11 @@ spec:
26
27
value : " {{ .Values.nacos.namespace }}"
27
28
resources :
28
29
requests :
29
- cpu : 2
30
- memory : 4Gi
30
+ cpu : 1
31
+ memory : 2Gi
31
32
limits :
32
- cpu : 2
33
- memory : 4Gi
33
+ cpu : 1
34
+ memory : 2Gi
34
35
ports :
35
36
- name : http-port
36
37
containerPort : 20001
Original file line number Diff line number Diff line change @@ -12,15 +12,16 @@ spec:
12
12
template :
13
13
metadata :
14
14
labels :
15
+ msePilotAutoEnable : " on"
16
+ msePilotCreateAppName : " spring-cloud-a"
17
+ mseNamespace : " {{ .Values.mse.namespace }}"
18
+ alicloud.service.tag : gray
15
19
app : " spring-cloud-a"
16
20
version : gray
17
- alicloud.service.tag : gray
18
- msePilotAutoEnable : " on"
19
- appName : " {{ .Values.mse.namePrefix }}spring-cloud-a"
20
21
spec :
21
22
containers :
22
23
- name : spring-cloud-a
23
- image : " {{ .Values.registry }}spring-cloud-a:1.1 .0"
24
+ image : " {{ .Values.registry }}spring-cloud-a:1.2 .0"
24
25
imagePullPolicy : Always
25
26
env :
26
27
- name : nacos.host
@@ -29,11 +30,11 @@ spec:
29
30
value : " {{ .Values.nacos.namespace }}"
30
31
resources :
31
32
requests :
32
- cpu : 2
33
- memory : 4Gi
33
+ cpu : 1
34
+ memory : 2Gi
34
35
limits :
35
- cpu : 2
36
- memory : 4Gi
36
+ cpu : 1
37
+ memory : 2Gi
37
38
ports :
38
39
- name : http-port
39
40
containerPort : 20001
Original file line number Diff line number Diff line change @@ -12,12 +12,13 @@ spec:
12
12
metadata :
13
13
labels :
14
14
msePilotAutoEnable : " on"
15
- appName : " {{ .Values.mse.namePrefix }}spring-cloud-b"
15
+ msePilotCreateAppName : " spring-cloud-b"
16
+ mseNamespace : " {{ .Values.mse.namespace }}"
16
17
app : " spring-cloud-b"
17
18
spec :
18
19
containers :
19
20
- name : spring-cloud-b
20
- image : " {{ .Values.registry }}spring-cloud-b:1.1 .0"
21
+ image : " {{ .Values.registry }}spring-cloud-b:1.2 .0"
21
22
imagePullPolicy : Always
22
23
env :
23
24
- name : nacos.host
@@ -26,11 +27,11 @@ spec:
26
27
value : " {{ .Values.nacos.namespace }}"
27
28
resources :
28
29
requests :
29
- cpu : 2
30
- memory : 4Gi
30
+ cpu : 1
31
+ memory : 2Gi
31
32
limits :
32
- cpu : 2
33
- memory : 4Gi
33
+ cpu : 1
34
+ memory : 2Gi
34
35
ports :
35
36
- name : http-port
36
37
containerPort : 20002
Original file line number Diff line number Diff line change @@ -12,12 +12,13 @@ spec:
12
12
metadata :
13
13
labels :
14
14
msePilotAutoEnable : " on"
15
- appName : " {{ .Values.mse.namePrefix }}spring-cloud-c"
15
+ msePilotCreateAppName : " spring-cloud-c"
16
+ mseNamespace : " {{ .Values.mse.namespace }}"
16
17
app : " spring-cloud-c"
17
18
spec :
18
19
containers :
19
20
- name : spring-cloud-c
20
- image : " {{ .Values.registry }}spring-cloud-c:1.1 .0"
21
+ image : " {{ .Values.registry }}spring-cloud-c:1.2 .0"
21
22
imagePullPolicy : Always
22
23
env :
23
24
- name : nacos.host
@@ -26,11 +27,11 @@ spec:
26
27
value : " {{ .Values.nacos.namespace }}"
27
28
resources :
28
29
requests :
29
- cpu : 2
30
- memory : 4Gi
30
+ cpu : 1
31
+ memory : 2Gi
31
32
limits :
32
- cpu : 2
33
- memory : 4Gi
33
+ cpu : 1
34
+ memory : 2Gi
34
35
ports :
35
36
- name : http-port
36
37
containerPort : 20003
You can’t perform that action at this time.
0 commit comments