-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
π :: [#508] - μ ν리μΌμ΄μ μ λ°°ν¬νλ μ€μ μ€ν¨νλ©΄ λλ ν 리λ₯Ό μμ νλλ‘ λ¦¬νν λ§ #509
Conversation
Walkthroughμ΄ PRμ Docker μ΄λ―Έμ§ λΉλ, 컨ν
μ΄λ μμ± λ° Dockerfile μμ± κ³Όμ μμ λ°μν μ μλ μ€ν¨ μν©μ λν μ€λ₯ μ²λ¦¬ λ° μ 리(cleanup) λ‘μ§μ μΆκ°ν©λλ€. κ° μλΉμ€ ν΄λμ€μμ μ λͺ
λ Ή μ€ν ν λ°νλλ exit codeλ₯Ό νμΈνκ³ , μ€ν¨ μ κ΄λ ¨ λλ ν°λ¦¬λ₯Ό μμ νλ λͺ
λ Ήμ΄( Changes
Sequence Diagram(s)sequenceDiagram
participant Service as DockerService
participant Shell
participant FS as Filesystem
Service->>Shell: μ€ν λͺ
λ Ήμ΄ (λΉλ/컨ν
μ΄λ μμ±/νμΌ μμ±)
Shell-->>Service: exit code λ°ν
alt exit code β 0 (μ€ν¨)
Service->>FS: κ΄λ ¨ λλ ν°λ¦¬ μμ (rm -rf)
else (μ±κ³΅)
Service->>Service: μ μ μ²λ¦¬ μ§ν
end
Possibly related PRs
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? πͺ§ TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
π§Ή Nitpick comments (1)
src/main/kotlin/com/dcd/server/core/domain/application/service/impl/BuildDockerImageServiceImpl.kt (1)
40-41
: μ΄λ―Έμ§ λΉλ μ€ν¨ μ μ 리(cleanup) λ‘μ§ μΆκ°μ΄λ―Έμ§ λΉλ μ€ν¨ μ λλ ν 리λ₯Ό μμ νλ λ‘μ§μ΄ μΆκ°λμμ΅λλ€. νμ§λ§ Spring Boot μ ν리μΌμ΄μ μ κ²½μ° Gradle λΉλ μ€ν¨ μμλ λλ ν 리λ₯Ό μμ νλ κ²μ΄ μ’μ κ² κ°μ΅λλ€.
λ€μκ³Ό κ°μ΄ Spring Boot Gradle λΉλ μ€ν¨ μμλ cleanupμ μννλλ‘ μμ μ μ μν©λλ€:
ApplicationType.SPRING_BOOT -> { commandPort.executeShellCommand("cd ./$directoryName && ./gradlew clean build") .run { if (this == 0) commandPort.executeShellCommand("cd ./$directoryName && docker build -t ${application.containerName}:latest .") - else this + else { + commandPort.executeShellCommand("rm -rf $directoryName") + this + } } }
π Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
π Files selected for processing (3)
src/main/kotlin/com/dcd/server/core/domain/application/service/impl/BuildDockerImageServiceImpl.kt
(2 hunks)src/main/kotlin/com/dcd/server/core/domain/application/service/impl/CreateContainerServiceImpl.kt
(1 hunks)src/main/kotlin/com/dcd/server/core/domain/application/service/impl/CreateDockerFileServiceImpl.kt
(2 hunks)
β° Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: Build and Test
π Additional comments (5)
src/main/kotlin/com/dcd/server/core/domain/application/service/impl/CreateContainerServiceImpl.kt (2)
26-27
: 컨ν μ΄λ μμ± μ€ν¨ μ μ 리(cleanup) λ‘μ§ μΆκ°μ»¨ν μ΄λ μμ±μ΄ μ€ν¨ν κ²½μ° ν΄λΉ μ ν리μΌμ΄μ λλ ν 리λ₯Ό μμ νλ λ‘μ§μ΄ μ μ νκ² κ΅¬νλμμ΅λλ€.
34-35
: λ€νΈμν¬ μ°κ²° μ€ν¨ μ μ 리(cleanup) λ‘μ§ μΆκ°λ€νΈμν¬ μ°κ²°μ΄ μ€ν¨ν κ²½μ°μλ μ ν리μΌμ΄μ λλ ν 리λ₯Ό μμ νλ λ‘μ§μ΄ μΌκ΄μ± μκ² κ΅¬νλμμ΅λλ€.
src/main/kotlin/com/dcd/server/core/domain/application/service/impl/BuildDockerImageServiceImpl.kt (1)
58-59
: buildImageByApplication λ©μλμ μ 리(cleanup) λ‘μ§ μΆκ°buildImageByApplication λ©μλμλ λμΌν cleanup λ‘μ§μ΄ μΌκ΄μ± μκ² κ΅¬νλμμ΅λλ€.
src/main/kotlin/com/dcd/server/core/domain/application/service/impl/CreateDockerFileServiceImpl.kt (2)
50-51
: λλ ν 리 μμ± μ€ν¨ μ μ 리(cleanup) λ‘μ§ μΆκ°λλ ν 리 μμ±μ΄ μ€ν¨ν κ²½μ° ν΄λΉ λλ ν 리λ₯Ό μμ νλ λ‘μ§μ΄ μ μ νκ² κ΅¬νλμμ΅λλ€.
77-77
: Dockerfile μμ± μ€ν¨ μ μ 리(cleanup) λ‘μ§ μΆκ°IOException λ°μ μ λλ ν 리λ₯Ό μμ νλ λ‘μ§μ΄ μ μ νκ² κ΅¬νλμμ΅λλ€.
κ°μ
μμ λ΄μ©
Summary by CodeRabbit