Skip to content

Commit

Permalink
build: 젠킨스 파이프라인 작성
Browse files Browse the repository at this point in the history
  • Loading branch information
yeopto committed Oct 19, 2023
1 parent 5f4eef3 commit f404c9d
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
27 changes: 27 additions & 0 deletions jenkins/frontend-admin-develop.jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
pipeline {
agent any

stages {
stage('github') {
steps {
git branch: 'develop', credentialsId: 'repo-and-hook-access-token-username-and-password', url: 'https://github.com/woowacourse-teams/2023-haru-study/'
}
}
stage('build') {
steps {
dir('admin') {
nodejs('NodeJS 18.16.0') {
sh 'yarn && yarn build'
}
}
}
}
stage('deploy') {
steps {
dir('admin') {
sshPublisher(publishers: [sshPublisherDesc(configName: 'haru-study-develop', transfers: [sshTransfer(cleanRemote: false, excludes: '', execCommand: '', execTimeout: 120000, flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: '/2023-haru-study/develop/admin', remoteDirectorySDF: false, removePrefix: 'dist', sourceFiles: 'dist/*')], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false)])
}
}
}
}
}
27 changes: 27 additions & 0 deletions jenkins/frontend-admin-production.jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
pipeline {
agent any

stages {
stage('github') {
steps {
git branch: 'main', credentialsId: 'repo-and-hook-access-token-username-and-password', url: 'https://github.com/woowacourse-teams/2023-haru-study/'
}
}
stage('build') {
steps {
dir('admin') {
nodejs('NodeJS 18.16.0') {
sh 'yarn && yarn build'
}
}
}
}
stage('deploy') {
steps {
dir('admin') {
sshPublisher(publishers: [sshPublisherDesc(configName: 'haru-study-develop', transfers: [sshTransfer(cleanRemote: false, excludes: '', execCommand: '', execTimeout: 120000, flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: '/2023-haru-study/develop/admin', remoteDirectorySDF: false, removePrefix: 'dist', sourceFiles: 'dist/*')], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false)])
}
}
}
}
}

0 comments on commit f404c9d

Please sign in to comment.