Compare commits
38 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| b739431651 | |||
| b78ed1bcf6 | |||
| 00154a9e93 | |||
| df13897a25 | |||
| 94db5c3efa | |||
| 17291abd2e | |||
| d72a06f005 | |||
| 0bd74fa092 | |||
| ac5c2b2106 | |||
| ddce6d49ac | |||
| ba406dd3a9 | |||
| 997013ad3f | |||
| 9fb3cfce01 | |||
| 58f1a5cf3e | |||
| ee4f86c17a | |||
| 94609f4347 | |||
| b10e682c11 | |||
| 12135903ab | |||
| 982fdd2438 | |||
| df3a84426f | |||
| b39bdc130f | |||
| 7002a942d3 | |||
| 5ee75f88dd | |||
| 6a2de89154 | |||
| f6850fa35f | |||
| 31ecf84171 | |||
| 9b90eae493 | |||
| 4056c657d3 | |||
| a5ed743178 | |||
| 8afb0e62a3 | |||
| 2b4921b5c8 | |||
| 4f06b352e5 | |||
| c425e899d4 | |||
| 15d6bf124f | |||
| b1440f702b | |||
| 90bb5d1ddf | |||
| 302893976c | |||
| a4a55e133b |
+1
-1
@@ -1,2 +1,2 @@
|
|||||||
.idea/*
|
.idea/*
|
||||||
target
|
target/
|
||||||
|
|||||||
Vendored
+9
-19
@@ -1,38 +1,28 @@
|
|||||||
def gv
|
#!/usr/bin/env groovy
|
||||||
|
|
||||||
pipeline {
|
pipeline {
|
||||||
agent any
|
agent any
|
||||||
stages {
|
stages {
|
||||||
stage("init") {
|
stage('test') {
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
gv = load "script.groovy"
|
echo "Testing the application..."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage("build jar") {
|
stage('build') {
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
echo "building jar"
|
echo "Building the application..."
|
||||||
//gv.buildJar()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage("build image") {
|
stage('deploy') {
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
echo "building image"
|
echo "Deploying the application..."
|
||||||
//gv.buildImage()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage("deploy") {
|
}
|
||||||
steps {
|
}
|
||||||
script {
|
|
||||||
echo "deploying"
|
|
||||||
//gv.deployApp()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -6,35 +6,7 @@
|
|||||||
|
|
||||||
<groupId>com.example</groupId>
|
<groupId>com.example</groupId>
|
||||||
<artifactId>java-maven-app</artifactId>
|
<artifactId>java-maven-app</artifactId>
|
||||||
<version>1.1.0-SNAPSHOT</version>
|
<version>1.0-SNAPSHOT</version>
|
||||||
|
|
||||||
<build>
|
|
||||||
<plugins>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.springframework.boot</groupId>
|
|
||||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
|
||||||
<version>2.3.5.RELEASE</version>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<goals>
|
|
||||||
<goal>repackage</goal>
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
|
|
||||||
<!-- to handle any Java version mismatch, add the following configuration for maven-compiler-plugin -->
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
|
||||||
<version>3.6.0</version>
|
|
||||||
<configuration>
|
|
||||||
<source>1.8</source>
|
|
||||||
<target>1.8</target>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
|||||||
@@ -1,19 +0,0 @@
|
|||||||
def buildJar() {
|
|
||||||
echo "building the application..."
|
|
||||||
sh 'mvn package'
|
|
||||||
}
|
|
||||||
|
|
||||||
def buildImage() {
|
|
||||||
echo "building the docker image..."
|
|
||||||
withCredentials([usernamePassword(credentialsId: 'docker-hub-repo', passwordVariable: 'PASS', usernameVariable: 'USER')]) {
|
|
||||||
sh 'docker build -t nanajanashia/demo-app:jma-2.0 .'
|
|
||||||
sh "echo $PASS | docker login -u $USER --password-stdin"
|
|
||||||
sh 'docker push nanajanashia/demo-app:jma-2.0'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
def deployApp() {
|
|
||||||
echo 'deploying the application...'
|
|
||||||
}
|
|
||||||
|
|
||||||
return this
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="UTF-8">
|
|
||||||
<title>MyApp</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<h1>Welcome to Java Maven Application</h1>
|
|
||||||
<!-- add image here <img src="" width="" /> -->
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
Reference in New Issue
Block a user