[♻️] Jenkins 동작 로직 수정

This commit is contained in:
SEAN-59 2025-05-22 10:25:15 +09:00
parent 197e2007ce
commit 0eaf1eae79
2 changed files with 19 additions and 4 deletions

16
Jenkinsfile vendored
View File

@ -9,6 +9,22 @@ pipeline {
APP_VOLUME = '/src'
}
stages {
stage('Clear Repository') {
steps {
script {
sh """
echo 'Clearing Front directory'
docker run --rm -v /volume1/AcaMate/PROJECT/Application/Back:/back alpine \
sh -c "find /back -mindepth 1 -maxdepth 1 \\
! -name 'private' \\
! -name 'publish' \\
! -name 'wwwroot' \\
-exec rm -rf {} +"
echo 'Clean complete'
"""
}
}
}
stage('Clone Repository') {
steps {
git url: 'https://git.ipstein.myds.me/AcaMate/AcaMate_API.git', branch: env.GIT_BRANCH

View File

@ -179,9 +179,8 @@ var app = builder.Build();
string staticRoot;
if (isLocal)
{
staticRoot = app.Environment.IsDevelopment() ?
Path.Combine(Directory.GetCurrentDirectory(), "publish", "debug", "wwwroot") :
Path.Combine(Directory.GetCurrentDirectory(), "publish", "release", "wwwroot") ;
staticRoot = app.Environment.IsDevelopment() ? //"/publish/debug/wwwroot" : "/publish/release/wwwroot" ;
Path.Combine(Directory.GetCurrentDirectory(), "publish", "debug", "wwwroot") : Path.Combine(Directory.GetCurrentDirectory(), "publish", "release", "wwwroot") ;
}
else
{
@ -225,8 +224,8 @@ app.UseWebSockets();
app.UseEndpoints(end =>
{
ControllerEndpointRouteBuilderExtensions.MapControllers(end);
end.MapFallbackToFile("index.html");
end.MapHub<ChatHub>("/chatHub");
end.MapFallbackToFile("index.html");
});