diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f02131ce..a6fa9603 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -4,8 +4,7 @@ on: pull_request: branches: [ main ] -env: - DATREE_TOKEN: ${{ secrets.DATREE_TOKEN }} + jobs: build: @@ -24,21 +23,3 @@ jobs: run: chmod +x gradlew - name: Build with Gradle run: ./gradlew build - - name: SonarQube Scan - uses: sonarsource/sonarqube-scan-action@master - env: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} - - name: SonarQube Quality Gate check - uses: sonarsource/sonarqube-quality-gate-action@master - # Force to fail step after specific time - timeout-minutes: 5 - env: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - - name: Install Datree - run: curl https://get.datree.io | /bin/bash - - - name: Run Datree's policy check - run: datree test kube.yaml - - diff --git a/Dockerfile b/Dockerfile index f9c20863..917d1e94 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,3 @@ -# this is multi stage FROM openjdk:11 as base WORKDIR /app COPY . . diff --git a/README.md b/README.md index 93676f58..4d8765e5 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# CICD_Java_gradle_application + This application is java spring boot web application @@ -8,4 +8,4 @@ when we build the code using command ```./gradlew build ``` it will generate war code is integrated with sonarqube plugin which help us in static code analysis -``` ./gradlew sonarqube ``` \ No newline at end of file +``` ./gradlew sonarqube ``` diff --git a/kube.yaml b/kube.yaml index d0058111..a7fcb1f7 100644 --- a/kube.yaml +++ b/kube.yaml @@ -46,7 +46,7 @@ spec: - name: registry-secret containers: - name: myapp - image: imagename + image: nginx:1.0 command: ["/bin/sh"] args: ["-c","sh /usr/local/tomcat/bin/startup.sh;while true; do echo hello; sleep 10;done"] imagePullPolicy: IfNotPresent