From ba835ff564424ed0ca6e908e9060ada8daee4f4c Mon Sep 17 00:00:00 2001 From: yirenyishi Date: Sun, 5 Aug 2018 20:06:52 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E5=A4=9A=E4=BD=99=E7=9A=84?= =?UTF-8?q?=E6=B3=A8=E9=87=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sc-config/build.gradle | 6 ++++-- sc-config/src/main/resources/application.yml | 4 +--- sc-dashboard/build.gradle | 2 -- .../java/com/trgis/sb2sc/Sb2scDashboardApplication.java | 1 - .../src/main/java/com/trgis/sb2sc/Sb2scZuulApplication.java | 1 - sc-zuul/src/main/resources/bootstrap.yml | 3 +-- 6 files changed, 6 insertions(+), 11 deletions(-) diff --git a/sc-config/build.gradle b/sc-config/build.gradle index c6d56d2..f18f752 100644 --- a/sc-config/build.gradle +++ b/sc-config/build.gradle @@ -11,7 +11,6 @@ buildscript { } apply plugin: 'java' -apply plugin: 'eclipse' apply plugin: 'org.springframework.boot' apply plugin: 'io.spring.dependency-management' @@ -23,11 +22,14 @@ repositories { mavenCentral() } - ext { springCloudVersion = 'Finchley.RELEASE' } +jar{ + manifest {attributes 'Main-Class':'com.trgis.sb2sc.Sb2scConfigApplication'} +} + dependencies { compile('org.springframework.cloud:spring-cloud-config-server') compile('org.springframework.cloud:spring-cloud-starter-netflix-eureka-client') diff --git a/sc-config/src/main/resources/application.yml b/sc-config/src/main/resources/application.yml index 0ba935b..19029c5 100644 --- a/sc-config/src/main/resources/application.yml +++ b/sc-config/src/main/resources/application.yml @@ -21,7 +21,5 @@ eureka: defaultZone: http://root:booszy@localhost:8761/eureka/ instance: prefer-ip-address: true -# instance-id: ${spring.application.name}:${spring.cloud.client.ipAddress}:${spring.application.instance_id:${server.port}} instance-id: ${spring.application.name}:${spring.application.instance_id:${server.port}} - appname: sc-config-server - + appname: sc-config-server \ No newline at end of file diff --git a/sc-dashboard/build.gradle b/sc-dashboard/build.gradle index e951a06..8f725d7 100644 --- a/sc-dashboard/build.gradle +++ b/sc-dashboard/build.gradle @@ -31,11 +31,9 @@ ext { dependencies { compile('org.springframework.cloud:spring-cloud-starter-netflix-eureka-client') compile('org.springframework.boot:spring-boot-starter-actuator') - compile('org.springframework.cloud:spring-cloud-starter-netflix-hystrix') compile('org.springframework.cloud:spring-cloud-starter-netflix-hystrix-dashboard') compile('org.springframework.cloud:spring-cloud-starter-netflix-turbine') - //compile('org.springframework.cloud:spring-cloud-starter-netflix-turbine-stream') } dependencyManagement { diff --git a/sc-dashboard/src/main/java/com/trgis/sb2sc/Sb2scDashboardApplication.java b/sc-dashboard/src/main/java/com/trgis/sb2sc/Sb2scDashboardApplication.java index b9b1cd8..6c8e84e 100644 --- a/sc-dashboard/src/main/java/com/trgis/sb2sc/Sb2scDashboardApplication.java +++ b/sc-dashboard/src/main/java/com/trgis/sb2sc/Sb2scDashboardApplication.java @@ -11,7 +11,6 @@ import org.springframework.cloud.netflix.turbine.EnableTurbine; @EnableTurbine @EnableHystrixDashboard public class Sb2scDashboardApplication { - public static void main(String[] args) { SpringApplication.run(Sb2scDashboardApplication.class, args); } diff --git a/sc-zuul/src/main/java/com/trgis/sb2sc/Sb2scZuulApplication.java b/sc-zuul/src/main/java/com/trgis/sb2sc/Sb2scZuulApplication.java index 5820d6b..66e6d95 100644 --- a/sc-zuul/src/main/java/com/trgis/sb2sc/Sb2scZuulApplication.java +++ b/sc-zuul/src/main/java/com/trgis/sb2sc/Sb2scZuulApplication.java @@ -11,7 +11,6 @@ import org.springframework.cloud.netflix.zuul.EnableZuulProxy; @EnableZuulProxy @RefreshScope public class Sb2scZuulApplication { - public static void main(String[] args) { SpringApplication.run(Sb2scZuulApplication.class, args); } diff --git a/sc-zuul/src/main/resources/bootstrap.yml b/sc-zuul/src/main/resources/bootstrap.yml index 886fe21..69dfc01 100644 --- a/sc-zuul/src/main/resources/bootstrap.yml +++ b/sc-zuul/src/main/resources/bootstrap.yml @@ -18,5 +18,4 @@ spring: fail-fast: true username: root password: booszy - profile: csdn - + profile: csdn \ No newline at end of file