Skip to content

Commit

Permalink
Merge pull request #44 from DDD-Community/feature/ITDS-68-refactor-v1
Browse files Browse the repository at this point in the history
Feature/itds 68 refactor v1
  • Loading branch information
kikingki authored Dec 9, 2024
2 parents abf1ecd + 4b40b77 commit 2df9a01
Show file tree
Hide file tree
Showing 100 changed files with 618 additions and 755 deletions.
28 changes: 14 additions & 14 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@ jobs:
- name: Setup Gradle
uses: gradle/gradle-build-action@v2

# 배포 시작 알림 전송
- name: Start Deployment
continue-on-error: true
run: |
curl -X POST -H "Content-Type: application/json" --data '{"content":"🚀 Deployment has started."}' ${{ secrets.DISCORD_WEBHOOK }}
# Docker Hub 로그인
- name: Login to Docker Hub
uses: docker/login-action@v1
Expand Down Expand Up @@ -66,12 +72,6 @@ jobs:
run: |
aws ec2 authorize-security-group-ingress --group-id ${{ secrets.AWS_SG_ID }} --protocol tcp --port 22 --cidr ${{ steps.ip.outputs.ipv4 }}/32
# 배포 시작 알림 전송
- name: Start Deployment
continue-on-error: true
run: |
curl -X POST -H "Content-Type: application/json" --data '{"content":"Deployment started!"}' ${{ secrets.DISCORD_WEBHOOK }}
# ssh로 접속해 재배포
- name: Deploy
uses: appleboy/ssh-action@master
Expand All @@ -85,18 +85,18 @@ jobs:
docker-compose pull
docker-compose up -d
# 배포 후 보안 그룹에서 github ip 삭제
- name: Remove Github Actions IP From Security Group
if: always()
run: |
aws ec2 revoke-security-group-ingress --group-id ${{ secrets.AWS_SG_ID }} --protocol tcp --port 22 --cidr ${{ steps.ip.outputs.ipv4 }}/32
# 배포 완료 알림 전송
- name: Notify Deployment Completed
if: success()
run: |
curl -X POST -H "Content-Type: application/json" --data '{"content":"Deployment completed successfully!"}' ${{ secrets.DISCORD_WEBHOOK }}
curl -X POST -H "Content-Type: application/json" --data '{"content":"Deployment completed successfully!"}' ${{ secrets.DISCORD_WEBHOOK }}
- name: Notify Deployment Failed
if: failure()
run: |
curl -X POST -H "Content-Type: application/json" --data '{"content":"Deployment failed!"}' ${{ secrets.DISCORD_WEBHOOK }}
# 배포 후 보안 그룹에서 github ip 삭제
- name: Remove Github Actions IP From Security Group
if: always()
run: |
aws ec2 revoke-security-group-ingress --group-id ${{ secrets.AWS_SG_ID }} --protocol tcp --port 22 --cidr ${{ steps.ip.outputs.ipv4 }}/32
curl -X POST -H "Content-Type: application/json" --data '{"content":"❌ Deployment failed...😢 Check the logs and try again!"}' ${{ secrets.DISCORD_WEBHOOK }}
6 changes: 3 additions & 3 deletions src/main/java/com/dissonance/itit/DissonanceApplication.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
@SpringBootApplication
public class DissonanceApplication {

public static void main(String[] args) {
SpringApplication.run(DissonanceApplication.class, args);
}
public static void main(String[] args) {
SpringApplication.run(DissonanceApplication.class, args);
}

}
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
package com.dissonance.itit.domain.entity;
package com.dissonance.itit.bookmark.domain;

import com.dissonance.itit.post.domain.InfoPost;
import com.dissonance.itit.user.domain.User;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
Expand All @@ -9,7 +12,6 @@
import jakarta.persistence.JoinColumn;
import jakarta.persistence.ManyToOne;
import jakarta.persistence.Table;
import jakarta.validation.constraints.Size;
import lombok.AccessLevel;
import lombok.AllArgsConstructor;
import lombok.Builder;
Expand All @@ -21,8 +23,8 @@
@AllArgsConstructor(access = AccessLevel.PRIVATE)
@NoArgsConstructor(access = AccessLevel.PROTECTED)
@Entity
@Table(name = "report")
public class Report {
@Table(name = "bookmark")
public class Bookmark {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = "id")
Expand All @@ -33,10 +35,6 @@ public class Report {
private User user;

@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "info_post_id")
private InfoPost infoPost;

@Size(max = 255)
@Column(name = "content")
private String content;
@JoinColumn(name = "post_id")
private InfoPost post;
}

This file was deleted.

This file was deleted.

This file was deleted.

31 changes: 0 additions & 31 deletions src/main/java/com/dissonance/itit/config/S3Config.java

This file was deleted.

25 changes: 0 additions & 25 deletions src/main/java/com/dissonance/itit/domain/entity/Bookmark.java

This file was deleted.

28 changes: 0 additions & 28 deletions src/main/java/com/dissonance/itit/domain/entity/Category.java

This file was deleted.

28 changes: 0 additions & 28 deletions src/main/java/com/dissonance/itit/domain/entity/FeaturedPost.java

This file was deleted.

12 changes: 0 additions & 12 deletions src/main/java/com/dissonance/itit/domain/enums/Directory.java

This file was deleted.

13 changes: 0 additions & 13 deletions src/main/java/com/dissonance/itit/domain/enums/Role.java

This file was deleted.

This file was deleted.

This file was deleted.

18 changes: 0 additions & 18 deletions src/main/java/com/dissonance/itit/dto/response/GeneratedToken.java

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.dissonance.itit.common.annotation;
package com.dissonance.itit.global.common.annotation;

import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
Expand Down
Loading

0 comments on commit 2df9a01

Please sign in to comment.