update fescar samples for docker (#80)

diff --git a/springboot-dubbo-fescar/pom.xml b/springboot-dubbo-fescar/pom.xml
index 09cb461..70968a6 100644
--- a/springboot-dubbo-fescar/pom.xml
+++ b/springboot-dubbo-fescar/pom.xml
@@ -36,7 +36,7 @@
 
     <properties>
         <java.version>1.8</java.version>
-        <fescar.version>0.2.1</fescar.version>
+        <fescar.version>0.4.1</fescar.version>
         <druid.version>1.1.10</druid.version>
         <mybatis.version>1.3.2</mybatis.version>
         <mybatis-plus.version>2.3</mybatis-plus.version>
diff --git a/springboot-dubbo-fescar/samples-account/Dockerfile b/springboot-dubbo-fescar/samples-account/Dockerfile
new file mode 100644
index 0000000..cc0d8a7
--- /dev/null
+++ b/springboot-dubbo-fescar/samples-account/Dockerfile
@@ -0,0 +1,12 @@
+# 选择JDK
+FROM openjdk:8u212-jre-slim-stretch
+VOLUME /tmp
+ADD target/samples-account-1.0.0-SNAPSHOT.jar app.jar
+RUN sh -c 'touch /app.jar'
+ENV JAVA_OPTS=""
+ENTRYPOINT [ "sh", "-c", "java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -jar /app.jar" ]
+# 命令行
+# 构建 docker build -t samples-account:1.0.0 .
+# 测试运行 docker run --net=host samples-account:1.0.0 /bin/bash
+# 进入bash docker exec -it [container_id] bash
+# 后台运行(开发) docker run -d --net=host samples-account:1.0.0
diff --git a/springboot-dubbo-fescar/samples-account/pom.xml b/springboot-dubbo-fescar/samples-account/pom.xml
index 62b1ae6..dd79efc 100644
--- a/springboot-dubbo-fescar/samples-account/pom.xml
+++ b/springboot-dubbo-fescar/samples-account/pom.xml
@@ -95,6 +95,14 @@
             <plugin>
                 <groupId>org.springframework.boot</groupId>
                 <artifactId>spring-boot-maven-plugin</artifactId>
+                <version>${springboot.version}</version>
+                <executions>
+                    <execution>
+                        <goals>
+                            <goal>repackage</goal>
+                        </goals>
+                    </execution>
+                </executions>
             </plugin>
         </plugins>
     </build>
diff --git a/springboot-dubbo-fescar/samples-account/src/main/resources/application.properties b/springboot-dubbo-fescar/samples-account/src/main/resources/application.properties
index 40a4ec7..f502812 100644
--- a/springboot-dubbo-fescar/samples-account/src/main/resources/application.properties
+++ b/springboot-dubbo-fescar/samples-account/src/main/resources/application.properties
@@ -7,18 +7,18 @@
 dubbo.protocol.id=dubbo
 dubbo.protocol.name=dubbo
 dubbo.registry.id=dubbo-account-fescar
-dubbo.registry.address=nacos://127.0.0.1:8848
+dubbo.registry.address=nacos://nacos:8848
 dubbo.protocol.port=20880
 dubbo.application.qosEnable=false
 
 #===================================registry config==========================================
 #Nacos\u6CE8\u518C\u4E2D\u5FC3
-spring.cloud.nacos.discovery.server-addr=127.0.0.1:8848
+spring.cloud.nacos.discovery.server-addr=nacos:8848
 management.endpoints.web.exposure.include=*
 
 #====================================mysql config============================================
 spring.datasource.driver-class-name=com.mysql.jdbc.Driver
-spring.datasource.url=jdbc:mysql://127.0.0.1:3306/db_gts_fescar?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
+spring.datasource.url=jdbc:mysql://mysql:3306/db_gts_fescar?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
 spring.datasource.username=root
 spring.datasource.password=root
 
diff --git a/springboot-dubbo-fescar/samples-account/src/main/resources/file.conf b/springboot-dubbo-fescar/samples-account/src/main/resources/file.conf
index 6c8fb0d..2b1a8c0 100644
--- a/springboot-dubbo-fescar/samples-account/src/main/resources/file.conf
+++ b/springboot-dubbo-fescar/samples-account/src/main/resources/file.conf
@@ -24,7 +24,7 @@
   #vgroup->rgroup
   vgroup_mapping.my_test_tx_group = "default"
   #only support single node
-  default.grouplist = "127.0.0.1:8091"
+  default.grouplist = "fescar:8091"
   #degrade current not support
   enableDegrade = false
   #disable
diff --git a/springboot-dubbo-fescar/samples-account/src/main/resources/registry.conf b/springboot-dubbo-fescar/samples-account/src/main/resources/registry.conf
index 18c6109..60ca973 100644
--- a/springboot-dubbo-fescar/samples-account/src/main/resources/registry.conf
+++ b/springboot-dubbo-fescar/samples-account/src/main/resources/registry.conf
@@ -3,7 +3,7 @@
   type = "file"
 
   nacos {
-    serverAddr = "localhost"
+    serverAddr = "nacos"
     namespace = "public"
     cluster = "default"
   }
diff --git a/springboot-dubbo-fescar/samples-dubbo-business-call/Dockerfile b/springboot-dubbo-fescar/samples-dubbo-business-call/Dockerfile
new file mode 100644
index 0000000..bffb496
--- /dev/null
+++ b/springboot-dubbo-fescar/samples-dubbo-business-call/Dockerfile
@@ -0,0 +1,12 @@
+# 选择JDK
+FROM openjdk:8u212-jre-slim-stretch
+VOLUME /tmp
+ADD target/samples-dubbo-business-call-1.0.0-SNAPSHOT.jar app.jar
+RUN sh -c 'touch /app.jar'
+ENV JAVA_OPTS=""
+ENTRYPOINT [ "sh", "-c", "java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -jar /app.jar" ]
+# 命令行
+# 构建 docker build -t samples-dubbo-business-call:1.0.0 .
+# 测试运行 docker run --net=host samples-dubbo-business-call:1.0.0 /bin/bash
+# 进入bash docker exec -it [container_id] bash
+# 后台运行(开发) docker run -d --net=host samples-dubbo-business-call:1.0.0
diff --git a/springboot-dubbo-fescar/samples-dubbo-business-call/pom.xml b/springboot-dubbo-fescar/samples-dubbo-business-call/pom.xml
index ee4b785..b341ed6 100644
--- a/springboot-dubbo-fescar/samples-dubbo-business-call/pom.xml
+++ b/springboot-dubbo-fescar/samples-dubbo-business-call/pom.xml
@@ -83,6 +83,14 @@
             <plugin>
                 <groupId>org.springframework.boot</groupId>
                 <artifactId>spring-boot-maven-plugin</artifactId>
+                <version>${springboot.version}</version>
+                <executions>
+                    <execution>
+                        <goals>
+                            <goal>repackage</goal>
+                        </goals>
+                    </execution>
+                </executions>
             </plugin>
         </plugins>
     </build>
diff --git a/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/application.properties b/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/application.properties
index 5a16855..c7896e5 100644
--- a/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/application.properties
+++ b/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/application.properties
@@ -8,11 +8,11 @@
 dubbo.protocol.name=dubbo
 dubbo.protocol.port=10001
 dubbo.registry.id=dubbo-gts-fescar
-dubbo.registry.address=nacos://127.0.0.1:8848
+dubbo.registry.address=nacos://nacos:8848
 dubbo.provider.version=1.0.0
 dubbo.application.qosEnable=false
 
 #==================================nacos==============================================
-spring.cloud.nacos.discovery.server-addr=127.0.0.1:8848
+spring.cloud.nacos.discovery.server-addr=nacos:8848
 management.endpoints.web.exposure.include=*
 
diff --git a/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/file.conf b/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/file.conf
index 6c8fb0d..2b1a8c0 100644
--- a/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/file.conf
+++ b/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/file.conf
@@ -24,7 +24,7 @@
   #vgroup->rgroup
   vgroup_mapping.my_test_tx_group = "default"
   #only support single node
-  default.grouplist = "127.0.0.1:8091"
+  default.grouplist = "fescar:8091"
   #degrade current not support
   enableDegrade = false
   #disable
diff --git a/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/registry.conf b/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/registry.conf
index 18c6109..60ca973 100644
--- a/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/registry.conf
+++ b/springboot-dubbo-fescar/samples-dubbo-business-call/src/main/resources/registry.conf
@@ -3,7 +3,7 @@
   type = "file"
 
   nacos {
-    serverAddr = "localhost"
+    serverAddr = "nacos"
     namespace = "public"
     cluster = "default"
   }
diff --git a/springboot-dubbo-fescar/samples-order/Dockerfile b/springboot-dubbo-fescar/samples-order/Dockerfile
new file mode 100644
index 0000000..9c3bf88
--- /dev/null
+++ b/springboot-dubbo-fescar/samples-order/Dockerfile
@@ -0,0 +1,12 @@
+# 选择JDK
+FROM openjdk:8u212-jre-slim-stretch
+VOLUME /tmp
+ADD target/samples-order-1.0.0-SNAPSHOT.jar app.jar
+RUN sh -c 'touch /app.jar'
+ENV JAVA_OPTS=""
+ENTRYPOINT [ "sh", "-c", "java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -jar /app.jar" ]
+# 命令行
+# 构建 docker build -t samples-order:1.0.0 .
+# 测试运行 docker run --net=host samples-order:1.0.0 /bin/bash
+# 进入bash docker exec -it [container_id] bash
+# 后台运行(开发) docker run -d --net=host samples-order:1.0.0
diff --git a/springboot-dubbo-fescar/samples-order/pom.xml b/springboot-dubbo-fescar/samples-order/pom.xml
index 9c2fd26..6059de7 100644
--- a/springboot-dubbo-fescar/samples-order/pom.xml
+++ b/springboot-dubbo-fescar/samples-order/pom.xml
@@ -100,6 +100,14 @@
             <plugin>
                 <groupId>org.springframework.boot</groupId>
                 <artifactId>spring-boot-maven-plugin</artifactId>
+                <version>${springboot.version}</version>
+                <executions>
+                    <execution>
+                        <goals>
+                            <goal>repackage</goal>
+                        </goals>
+                    </execution>
+                </executions>
             </plugin>
         </plugins>
     </build>
diff --git a/springboot-dubbo-fescar/samples-order/src/main/resources/application.properties b/springboot-dubbo-fescar/samples-order/src/main/resources/application.properties
index 3583780..59734fb 100644
--- a/springboot-dubbo-fescar/samples-order/src/main/resources/application.properties
+++ b/springboot-dubbo-fescar/samples-order/src/main/resources/application.properties
@@ -7,18 +7,18 @@
 dubbo.protocol.id=dubbo
 dubbo.protocol.name=dubbo
 dubbo.registry.id=dubbo-order-fescar
-dubbo.registry.address=nacos://127.0.0.1:8848
+dubbo.registry.address=nacos://nacos:8848
 dubbo.protocol.port=20881
 dubbo.application.qosEnable=false
 
 #===================================registry config==========================================
 #Nacos\u6CE8\u518C\u4E2D\u5FC3
-spring.cloud.nacos.discovery.server-addr=127.0.0.1:8848
+spring.cloud.nacos.discovery.server-addr=nacos:8848
 management.endpoints.web.exposure.include=*
 
 #====================================mysql =============================================
 spring.datasource.driver-class-name=com.mysql.jdbc.Driver
-spring.datasource.url=jdbc:mysql://127.0.0.1:3306/db_gts_fescar?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
+spring.datasource.url=jdbc:mysql://mysql:3306/db_gts_fescar?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
 spring.datasource.username=root
 spring.datasource.password=root
 
diff --git a/springboot-dubbo-fescar/samples-order/src/main/resources/file.conf b/springboot-dubbo-fescar/samples-order/src/main/resources/file.conf
index 6c8fb0d..2b1a8c0 100644
--- a/springboot-dubbo-fescar/samples-order/src/main/resources/file.conf
+++ b/springboot-dubbo-fescar/samples-order/src/main/resources/file.conf
@@ -24,7 +24,7 @@
   #vgroup->rgroup
   vgroup_mapping.my_test_tx_group = "default"
   #only support single node
-  default.grouplist = "127.0.0.1:8091"
+  default.grouplist = "fescar:8091"
   #degrade current not support
   enableDegrade = false
   #disable
diff --git a/springboot-dubbo-fescar/samples-order/src/main/resources/registry.conf b/springboot-dubbo-fescar/samples-order/src/main/resources/registry.conf
index 18c6109..60ca973 100644
--- a/springboot-dubbo-fescar/samples-order/src/main/resources/registry.conf
+++ b/springboot-dubbo-fescar/samples-order/src/main/resources/registry.conf
@@ -3,7 +3,7 @@
   type = "file"
 
   nacos {
-    serverAddr = "localhost"
+    serverAddr = "nacos"
     namespace = "public"
     cluster = "default"
   }
diff --git a/springboot-dubbo-fescar/samples-storage/Dockerfile b/springboot-dubbo-fescar/samples-storage/Dockerfile
new file mode 100644
index 0000000..dfb0e55
--- /dev/null
+++ b/springboot-dubbo-fescar/samples-storage/Dockerfile
@@ -0,0 +1,12 @@
+# 选择JDK
+FROM openjdk:8u212-jre-slim-stretch
+VOLUME /tmp
+ADD target/samples-storage-1.0.0-SNAPSHOT.jar app.jar
+RUN sh -c 'touch /app.jar'
+ENV JAVA_OPTS=""
+ENTRYPOINT [ "sh", "-c", "java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -jar /app.jar" ]
+# 命令行
+# 构建 docker build -t samples-storage:1.0.0 .
+# 测试运行 docker run --net=host samples-storage:1.0.0 /bin/bash
+# 进入bash docker exec -it [container_id] bash
+# 后台运行(开发) docker run -d --net=host samples-storage:1.0.0
diff --git a/springboot-dubbo-fescar/samples-storage/pom.xml b/springboot-dubbo-fescar/samples-storage/pom.xml
index c695b01..cc1adf7 100644
--- a/springboot-dubbo-fescar/samples-storage/pom.xml
+++ b/springboot-dubbo-fescar/samples-storage/pom.xml
@@ -100,6 +100,14 @@
             <plugin>
                 <groupId>org.springframework.boot</groupId>
                 <artifactId>spring-boot-maven-plugin</artifactId>
+                <version>${springboot.version}</version>
+                <executions>
+                    <execution>
+                        <goals>
+                            <goal>repackage</goal>
+                        </goals>
+                    </execution>
+                </executions>
             </plugin>
         </plugins>
     </build>
diff --git a/springboot-dubbo-fescar/samples-storage/src/main/resources/application.properties b/springboot-dubbo-fescar/samples-storage/src/main/resources/application.properties
index cb7a0e2..c12e923 100644
--- a/springboot-dubbo-fescar/samples-storage/src/main/resources/application.properties
+++ b/springboot-dubbo-fescar/samples-storage/src/main/resources/application.properties
@@ -7,18 +7,18 @@
 dubbo.protocol.id=dubbo
 dubbo.protocol.name=dubbo
 dubbo.registry.id=dubbo-storage-fescar
-dubbo.registry.address=nacos://127.0.0.1:8848
+dubbo.registry.address=nacos://nacos:8848
 dubbo.protocol.port=20882
 dubbo.application.qosEnable=false
 
 #===================================registry config==========================================
 #Nacos\u6CE8\u518C\u4E2D\u5FC3
-spring.cloud.nacos.discovery.server-addr=127.0.0.1:8848
+spring.cloud.nacos.discovery.server-addr=nacos:8848
 management.endpoints.web.exposure.include=*
 
 #====================================mysql config===========================================
 spring.datasource.driver-class-name=com.mysql.jdbc.Driver
-spring.datasource.url=jdbc:mysql://127.0.0.1:3306/db_gts_fescar?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
+spring.datasource.url=jdbc:mysql://mysql:3306/db_gts_fescar?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
 spring.datasource.username=root
 spring.datasource.password=root
 
diff --git a/springboot-dubbo-fescar/samples-storage/src/main/resources/file.conf b/springboot-dubbo-fescar/samples-storage/src/main/resources/file.conf
index 6c8fb0d..2b1a8c0 100644
--- a/springboot-dubbo-fescar/samples-storage/src/main/resources/file.conf
+++ b/springboot-dubbo-fescar/samples-storage/src/main/resources/file.conf
@@ -24,7 +24,7 @@
   #vgroup->rgroup
   vgroup_mapping.my_test_tx_group = "default"
   #only support single node
-  default.grouplist = "127.0.0.1:8091"
+  default.grouplist = "fescar:8091"
   #degrade current not support
   enableDegrade = false
   #disable
diff --git a/springboot-dubbo-fescar/samples-storage/src/main/resources/registry.conf b/springboot-dubbo-fescar/samples-storage/src/main/resources/registry.conf
index 18c6109..60ca973 100644
--- a/springboot-dubbo-fescar/samples-storage/src/main/resources/registry.conf
+++ b/springboot-dubbo-fescar/samples-storage/src/main/resources/registry.conf
@@ -3,7 +3,7 @@
   type = "file"
 
   nacos {
-    serverAddr = "localhost"
+    serverAddr = "nacos"
     namespace = "public"
     cluster = "default"
   }