Skip to content

Commit

Permalink
fix: add git user configuration for commits in Jenkinsfile
Browse files Browse the repository at this point in the history
  • Loading branch information
Ganthepro committed Dec 24, 2024
1 parent f705b64 commit c0095cf
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ pipeline {
withCredentials([string(credentialsId: 'edusaig-manifest-repo', variable: 'MANIFEST_REPO')]) {
sh "git clone $MANIFEST_REPO"
sh 'sed -i "s/^\\([[:space:]]*tag:[[:space:]]*\\).*/\\1\\"$BUILD_NUMBER\\"/" edusaig-manifests/values.yaml'
sh 'git config --global user.email "ganzazamar@gmail.com"'
sh 'git config --global user.name "ganthepro"'
sh "cd edusaig-manifests && git add . && git commit -m 'Update tag to $BUILD_NUMBER' && git push"
// ใช้คำสั่ง git clone เพื่อทำการ clone โปรเจคของเรา และใช้คำสั่ง sed เพื่อทำการแก้ไขไฟล์ values.yaml ในโปรเจคของเรา
}
Expand Down

0 comments on commit c0095cf

Please sign in to comment.