Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
80 commits
Select commit Hold shift + click to select a range
80739ed
Create jenkinsfilek8s
Kidunnu Feb 22, 2022
fc8084d
Update pom.xml
Kidunnu Feb 22, 2022
17da58e
Update pom.xml
Kidunnu Feb 22, 2022
51536e9
Update pom.xml
Kidunnu Feb 22, 2022
30c55c5
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
0a804e8
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
4090c19
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
29e1290
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
a591712
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
37c2b10
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
6cc62ca
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
c082dce
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
446c701
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
c50367f
Update pom.xml
Kidunnu Feb 22, 2022
f990850
Update pom.xml
Kidunnu Feb 22, 2022
4abf21a
Update pom.xml
Kidunnu Feb 22, 2022
94fde3f
Update pom.xml
Kidunnu Feb 22, 2022
095ddef
Update pom.xml
Kidunnu Feb 22, 2022
eced9d7
Update pom.xml
Kidunnu Feb 22, 2022
e30f5f4
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
b0e0dae
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
ddf2fb4
Update jenkinsfilek8s
Kidunnu Feb 22, 2022
faa4504
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
9de4b17
Update springapp.yml
Kidunnu Feb 23, 2022
366b9ee
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
f1fe239
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
1ef6c4a
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
e32eb6b
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
8f2ce97
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
f85c8b2
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
b660c15
Update springBootMongo.yml
Kidunnu Feb 23, 2022
6061060
Update jenkinsfilek8s
Kidunnu Feb 23, 2022
a7a8a7d
Update pom.xml
Kidunnu Feb 27, 2022
715a5d6
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
9d98082
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
560cf77
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
9123419
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
900fab5
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
fe378d7
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
8b094c2
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
350559c
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
3b37f4b
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
c6086ee
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
13f8b67
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
93c141b
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
9440e9f
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
f6c3bd4
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
947f1b7
Update jenkinsfilek8s
Kidunnu Feb 27, 2022
40e56be
Update jenkinsfilek8s
Kidunnu Mar 12, 2022
01cc284
Update jenkinsfilek8s
Kidunnu Mar 12, 2022
102ac5a
Update jenkinsfilek8s
Kidunnu Mar 12, 2022
f5d4c0b
Update jenkinsfilek8s
Kidunnu Mar 12, 2022
c4d0377
Update jenkinsfilek8s
Kidunnu Mar 12, 2022
f5eb91c
Update jenkinsfilek8s
Kidunnu Mar 12, 2022
58f5d79
Update pom.xml
Kidunnu Mar 12, 2022
00798c7
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
6915588
Update pom.xml
Kidunnu Mar 15, 2022
03e9069
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
28dc6bb
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
f15025a
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
faa6690
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
3f877f4
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
095671c
Update pom.xml
Kidunnu Mar 15, 2022
0564e56
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
7010265
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
c836597
Update jenkinsfilek8s
Kidunnu Mar 15, 2022
ca7ad39
Create mymaven.yml
Kidunnu Apr 24, 2022
953fcbb
Update mymaven.yml
Kidunnu Apr 24, 2022
df74ab2
Update mymaven.yml
Kidunnu Apr 24, 2022
0d2740f
Update pom.xml
Kidunnu Apr 30, 2022
b0e9f20
Update pom.xml
Kidunnu Apr 30, 2022
8c308d7
Update pom.xml
Kidunnu Apr 30, 2022
39e9761
Update pom.xml
Kidunnu Apr 30, 2022
6275a12
Update pom.xml
Kidunnu Apr 30, 2022
cdafb1b
Update pom.xml
Kidunnu Apr 30, 2022
2fee3ef
Update jenkinsfilek8s
Kidunnu Apr 30, 2022
880d5f0
Update mymaven.yml
Kidunnu Apr 30, 2022
bc5adce
Update mymaven.yml
Kidunnu Apr 30, 2022
8584dff
Update mymaven.yml
Kidunnu Apr 30, 2022
cc3d572
Update mymaven.yml
Kidunnu Apr 30, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions .github/workflows/mymaven.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven

name: Java CI with Maven

on:
push:
branches: [ sandbox ]
pull_request:
branches: [ sandbox ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven
- name: Build with Maven
run: mvn -B package --file pom.xml

- name: Build & push Docker image
uses: mr-smithers-excellent/docker-build-push@v5
with:
image: kidunnu/springappmongo4
tags: v1, latest
registry: docker.io
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: send slack notification
uses: docker://technosophos/slack-notify
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_MESSAGE: Run succesfully


51 changes: 51 additions & 0 deletions jenkinsfilek8s
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@

pipeline{
agent any
tools{
maven "maven3.8.4"
}
stages{
stage('SCM Checkout'){
steps{
git 'https://github.com/Kidunnu/spring-boot-docker.git'
}
}
stage('maven-Build'){
steps{
sh "mvn clean package"
}
}
/*stage('code quality'){
steps{
sh "mvn sonar:sonar"
}
}*/

stage('approval'){
steps{
timeout (time:5, unit:'HOURS'){
input message: "please verify and approve"
}
}
}
stage('Build Docker Image'){
steps{
sh "docker build -t kidunnu/spring-boot-mongo ."
}
}
stage('Push Docker Image'){
steps{
withCredentials([string(credentialsId: 'DockerHubCredential', variable: 'DockerHubCredential')]) {
sh "docker login -u kidunnu -p ${DockerHubCredential}"
}
sh "docker push kidunnu/spring-boot-mongo"
}
}
stage("Deploy To Kuberates Cluster"){
steps{withKubeConfig(caCertificate: '', clusterName: '', contextName: '', credentialsId: 'k8ss', namespace: '', serverUrl: '') {
sh "kubectl apply -f springBootMongo.yml"
}
}
}
}
}
28 changes: 27 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@
<spring-boot.version>2.1.5.RELEASE</spring-boot.version>
<spring-cloud.version>Greenwich.RELEASE</spring-cloud.version>
<logstash-logback-encoder.version>6.1</logstash-logback-encoder.version>
<jdk.version>1.8</jdk.version>
<spring.version>5.1.2.RELEASE</spring.version>
<junit.version>4.11</junit.version>
<log4j.version>1.2.17</log4j.version>
<sonar.host.url>http://localhost:8000</sonar.host.url>
<sonar.login>admin</sonar.login>
<sonar.password>admin123</sonar.password>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
</properties>

<dependencyManagement>
Expand Down Expand Up @@ -83,12 +92,29 @@
<scope>test</scope>
</dependency>
</dependencies>

<distributionManagement>
<repository>
<id>nexus</id>
<name>Landmark Technologies Releases Nexus Repository</name>
<url>http://54.175.166.158:7079/repository/team_release</url>
</repository>

<snapshotRepository>
<id>nexus</id>
<name>Landmark Technologies Snapshot Nexus Repository </name>
<url>http://54.175.166.158:7079/repository/team_snapshot</url>
</snapshotRepository>

</distributionManagement>

<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>

</build>
</project>
</project>
2 changes: 1 addition & 1 deletion springBootMongo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ spec:
app: springboot
spec:
containers:
- image: mylandmarktech/springapp
- image: kidunnu/spring-boot-mongo
name: springboot
ports:
- containerPort: 8080
Expand Down
2 changes: 1 addition & 1 deletion springapp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ spec:
spec:
containers:
- name: springappcontainer
image: mylandmarktech/spring-boot-mongo
image: kidunnu/spring-boot-mongo
ports:
- containerPort: 8080
env:
Expand Down