Skip to content

Commit

Permalink
Revert "Merge pull request #141 from UMC5th-bias/main"
Browse files Browse the repository at this point in the history
This reverts commit 318503f, reversing
changes made to 6eb93cc.
  • Loading branch information
ppparkta committed Sep 19, 2024
1 parent fe4e9df commit 22b8600
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 41 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,13 @@ jobs:
uses: actions/checkout@v3

# (2) JDK 11 세팅
- name: Set up JDK 17
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'

# (3) Gradle build (Test 제외)
- name: Grant execute permission for gradlew
run: chmod +x ./gradlew

- name: Build with Gradle
uses: gradle/gradle-build-action@0d13054264b0bb894ded474f08ebb30921341cee
with:
Expand Down Expand Up @@ -67,5 +64,4 @@ jobs:
--application-name ${{ env.CODE_DEPLOY_APPLICATION_NAME }} \
--deployment-config-name CodeDeployDefault.AllAtOnce \
--deployment-group-name ${{ env.CODE_DEPLOY_DEPLOYMENT_GROUP_NAME }} \
--s3-location bucket=$S3_BUCKET_NAME,key=$GITHUB_SHA.zip,bundleType=zip \
--file-exists-behavior OVERWRITE
--s3-location bucket=$S3_BUCKET_NAME,key=$GITHUB_SHA.zip,bundleType=zip
26 changes: 9 additions & 17 deletions appspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,13 @@ permissions:
group: ubuntu

hooks:
# ApplicationStart:
# - location: scripts/run_new_was.sh
# timeout: 180
# runas: ubuntu
# - location: scripts/health_check.sh
# timeout: 180
# runas: ubuntu
# - location: scripts/switch.sh
# timeout: 180
# runas: ubuntu
AfterInstall:
- location: scripts/stop.sh
timeout: 60
runas: ubuntu
ApplicationStart:
- location: scripts/start.sh
timeout: 60
runas: ubuntu
- location: scripts/run_new_was.sh
timeout: 180
runas: ubuntu
- location: scripts/health_check.sh
timeout: 180
runas: ubuntu
- location: scripts/switch.sh
timeout: 180
runas: ubuntu
2 changes: 1 addition & 1 deletion scripts/health_check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ echo "> Start health check of WAS at 'http://127.0.0.1:${TARGET_PORT}' ..."
for RETRY_COUNT in 1 2 3 4 5 6 7 8 9 10
do
echo "> #${RETRY_COUNT} trying..."
RESPONSE_CODE=$(curl -s -o /dev/null -w "%{http_code}" http://127.0.0.1:${TARGET_PORT}/hello)
RESPONSE_CODE=$(curl -s -o /dev/null -w "%{http_code}" http://127.0.0.1:${TARGET_PORT}/health)

if [ ${RESPONSE_CODE} -eq 200 ]; then
echo "> New WAS successfully running"
Expand Down
14 changes: 0 additions & 14 deletions src/main/java/com/favoriteplace/HelloController.java

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
package com.favoriteplace.app.controller;

import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/health")
public class HealthCheckController {

@GetMapping()
@GetMapping("/health")
public String health(){
return "hello success!";
}
Expand Down

0 comments on commit 22b8600

Please sign in to comment.