group 'com.uas.erp' version '1.0.0' buildscript { ext { springBootVersion = '1.4.4.RELEASE' dockerVersion = '0.12.0' dockerRegistry = "10.1.81.48:5000" } repositories { maven { url "https://maven.ubtob.net/artifactory/libs-release-local" credentials { username 'admin' password 'Admin2020yourkj2021' } } maven { url "https://maven.ubtob.net/artifactory/libs-snapshot-local" credentials { username 'admin' password 'Admin2020yourkj2021' } } maven { url "http://maven.aliyun.com/nexus/content/groups/public/" } maven { url "https://plugins.gradle.org/m2/" } maven { url "https://repo.spring.io/libs-release" } mavenCentral() jcenter() } dependencies { classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}") classpath "gradle.plugin.com.palantir.gradle.docker:gradle-docker:${dockerVersion}" } } apply plugin: 'idea' apply plugin: 'java' apply plugin: 'maven' apply plugin: 'org.springframework.boot' apply plugin: "com.palantir.docker" jar { baseName = project.name version = '' } sourceCompatibility = 1.7 repositories { mavenLocal() maven { url "https://maven.ubtob.net/artifactory/libs-release-local" credentials { username 'admin' password 'Admin2020yourkj2021' } } maven { url "https://maven.ubtob.net/artifactory/ext-release-local" credentials { username 'admin' password 'Admin2020yourkj2021' } } maven { url "https://maven.ubtob.net/artifactory/libs-snapshot-local" credentials { username 'admin' password 'Admin2020yourkj2021' } } maven { url "https://maven.aliyun.com/nexus/content/groups/public/" } maven { url "https://repo.spring.io/libs-milestone" } maven { url "https://repo.spring.io/libs-release" } mavenCentral() } dependencyManagement { imports { mavenBom 'org.springframework.cloud:spring-cloud-dependencies:Camden.SR5' } } dependencies { compile 'org.springframework.boot:spring-boot-starter-data-jpa' compile "org.springframework.boot:spring-boot-starter-web" testCompile "org.springframework.boot:spring-boot-starter-test" compile "com.h2database:h2" compile "com.alibaba:fastjson:$fastjsonVersion" compile "com.uas.api:b2c-erp-api:$mallApiVersion" compile "org.projectlombok:lombok:1.18.4" compile "commons-io:commons-io:2.6" compile "com.usoft.framework:usoft-security-utils:dev-1.0-SNAPSHOT" } bootRun { addResources = true } docker { name "${dockerRegistry}/${project.name}:${project.version}" dockerfile "${projectDir}/src/main/docker/Dockerfile" files "${buildDir}/libs/${project.name}.jar" }.dependsOn build uploadArchives { repositories { mavenDeployer { repository(url: "https://maven.ubtob.net/artifactory/libs-release-local") { authentication(userName: "admin", password: "Admin2020yourkj2021") } } } }.dependsOn build