Compare commits

...

25 Commits
0.0.3 ... main

Author SHA1 Message Date
deployer3000 19889e9767 Merge pull request 'rc' (#33) from rc into main 2025-04-10 10:54:10 +03:00
yuobrezkov c24d18e6e1 pre last test4
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-10 10:52:48 +03:00
yuobrezkov 344d1a5055 pre last test3 2025-04-10 10:52:41 +03:00
deployer3000 846965c41e Merge pull request 'rc' (#32) from rc into main 2025-04-10 10:48:55 +03:00
yuobrezkov 9f288fb3fa pre last test2
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-10 10:46:56 +03:00
yuobrezkov 2f359f6b81 pre last test1
test-org/test-ci-cd/pipeline/pr-main Build succeeded
2025-04-10 10:46:44 +03:00
deployer3000 85bdd4c9ba Merge pull request 'rc' (#31) from rc into main 2025-04-10 10:44:38 +03:00
yuobrezkov ce255a692a 123123123
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-10 10:42:51 +03:00
yuobrezkov 415474e608 1 2025-04-10 10:42:42 +03:00
deployer3000 3b7cdda4e4 Merge pull request 'rc' (#30) from rc into main 2025-04-09 18:30:01 +03:00
yuobrezkov 20f2a86ccf 2
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-09 18:28:35 +03:00
yuobrezkov 10730582da 1 2025-04-09 18:28:25 +03:00
deployer3000 fddba6946d Merge pull request 'rc' (#29) from rc into main 2025-04-09 18:19:25 +03:00
yuobrezkov 4b099e73bf daa?????
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-09 18:17:47 +03:00
yuobrezkov d0aa52bf1d daa? 2025-04-09 18:17:36 +03:00
deployer3000 8660b8b2ac Merge pull request 'rc' (#28) from rc into main 2025-04-09 18:16:07 +03:00
yuobrezkov 0d51a0e332 da
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-09 18:14:46 +03:00
yuobrezkov 099692fc02 ili da?? 2025-04-09 18:14:37 +03:00
deployer3000 6e8e590ec9 Merge pull request 'ili da?' (#27) from rc into main 2025-04-09 18:12:31 +03:00
yuobrezkov b4dc7961ec ili da?
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-09 18:11:08 +03:00
deployer3000 99bccca3e6 Merge pull request 'ili net?' (#26) from rc into main
test-org/test-ci-cd/pipeline/pr-main Build succeeded
2025-04-09 18:08:19 +03:00
yuobrezkov 8a27e12eaa ili net?
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-09 18:06:35 +03:00
deployer3000 bdf085cebb Merge pull request 'final' (#25) from rc into main 2025-04-09 18:05:36 +03:00
yuobrezkov bc88fcf598 final
test-org/test-ci-cd/pipeline/pr-main This commit looks good Details
2025-04-09 18:04:04 +03:00
deployer3000 a89a5f3d28 Merge pull request 'rc' (#24) from rc into main 2025-04-09 18:02:56 +03:00
2 changed files with 9 additions and 6 deletions

12
Jenkinsfile vendored
View File

@ -96,15 +96,17 @@ pipeline {
-d '{"do":"merge"}' \ -d '{"do":"merge"}' \
http://git.entcor/api/v1/repos/deployer3000/${env.IMAGE_NAME}/pulls/${prId}/merge http://git.entcor/api/v1/repos/deployer3000/${env.IMAGE_NAME}/pulls/${prId}/merge
""" """
def commitHash = sh(script: "git rev-parse HEAD~1", returnStdout: true).trim() // необходим для корректного отображения статусов
echo "PR ${prId} merged successfully into main!" echo "PR ${prId} merged successfully into main!"
def commitHash = sh(script: "git rev-parse HEAD~1", returnStdout: true).trim() sleep(time: 15, unit: 'SECONDS')
def newCommitHash = sh(script: "git rev-parse HEAD", returnStdout: true).trim() sh "git checkout main && git pull origin main" // пробуем спуллить, чтобы последний мёрдж коммит получить
echo "COMMIT_HASH ${commitHash}"
echo "NEW_COMMIT_HASH ${newCommitHash} " def prCommitHash = sh(script: "git rev-parse HEAD", returnStdout: true).trim()
sh """ sh """
curl -v -X POST -u "${GITEA_USER}:${GITEA_PASS}" \ curl -v -X POST -u "${GITEA_USER}:${GITEA_PASS}" \
-H "Content-Type: application/json" \ -H "Content-Type: application/json" \
-d '{"tag_name": "${env.NEW_VERSION}", "name": "Release ${env.NEW_VERSION}", "target_commitish": "${newCommitHash}"}' \ -d '{"tag_name": "${env.NEW_VERSION}", "name": "Release ${env.NEW_VERSION}", "target_commitish": "${prCommitHash}"}' \
"${env.GITEA_REPOSITORY_URL}deployer3000/${env.IMAGE_NAME}/releases" "${env.GITEA_REPOSITORY_URL}deployer3000/${env.IMAGE_NAME}/releases"
""" """
echo "New release succeeded!" echo "New release succeeded!"

View File

@ -2,4 +2,5 @@
```bash ```bash
docker build -t test-ci-cd . docker build -t test-ci-cd .
docker run --rm --name test-ci-cd -p 8000:8080 test-ci-cd:latest docker run --rm --name test-ci-cd -p 8000:8080 test-ci-cd:latest
123