diff --git a/ci/pipeline.yml b/ci/pipeline.yml index 41e7582..43694fb 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -42,6 +42,7 @@ meta: repo: (( param "Please specify the name of the Github repository" )) branch: master pr_base_branch: (( grab meta.github.branch )) + release_branch: (( grab meta.github.branch )) private_key: (( param "Please generate an SSH Deployment Key for this repo and specify it here" )) access_token: (( param "Please generate a Personal Access Token and specify it here" )) @@ -59,8 +60,8 @@ meta: fail_moji: ":airplane_arriving:" upset_moji: ":sadpanda:" pipeline_url: (( concat meta.url "/teams/${BUILD_TEAM_NAME}/pipelines/${BUILD_PIPELINE_NAME}" )) - fail_link: (( concat "<" meta.slack.pipeline_url "/jobs/${BUILD_JOB_NAME}/builds/${BUILD_NAME}| Concourse Failure! " meta.slack.upset_moji ">" )) - fail_text: '(( concat meta.slack.fail_link " " meta.pipeline ": `${BUILD_JOB_NAME}` job failed" ))' + fail_link: (( concat "<" meta.slack.pipeline_url "/jobs/${BUILD_JOB_NAME}/builds/${BUILD_NAME}| Let's go fix it!>" )) + fail_text: '(( concat meta.pipeline ": `${BUILD_JOB_NAME}` job has failed " meta.slack.upset_moji " " meta.slack.fail_link " :hammer_and_wrench:" ))' groups: - name: (( grab meta.name )) @@ -101,6 +102,7 @@ jobs: on_failure: put: notify + no_get: true params: channel: (( grab meta.slack.channel )) username: (( grab meta.slack.username )) @@ -169,6 +171,7 @@ jobs: on_success: put: notify + no_get: true params: channel: (( grab meta.slack.channel )) username: (( grab meta.slack.username )) @@ -212,6 +215,7 @@ jobs: params: { file: version/number } on_failure: put: notify + no_get: true params: channel: (( grab meta.slack.channel )) username: (( grab meta.slack.username )) @@ -226,6 +230,7 @@ jobs: - { put: version, params: { file: version/number } } on_failure: put: notify + no_get: true params: channel: (( grab meta.slack.channel )) username: (( grab meta.slack.username )) @@ -240,6 +245,7 @@ jobs: - { put: version, params: { file: version/number } } on_failure: put: notify + no_get: true params: channel: (( grab meta.slack.channel )) username: (( grab meta.slack.username )) @@ -271,13 +277,14 @@ jobs: path: ./git/ci/scripts/release args: [] params: - REPO_ROOT: git - RELEASE_ROOT: gh - RELEASE_NAME: (( grab meta.release )) - REPO_OUT: pushme/git - VERSION_FROM: version/number - GIT_EMAIL: (( grab meta.git.email )) - GIT_NAME: (( grab meta.git.name )) + REPO_ROOT: git + RELEASE_ROOT: gh + RELEASE_NAME: (( grab meta.release )) + REPO_OUT: pushme/git + VERSION_FROM: version/number + GIT_EMAIL: (( grab meta.git.email )) + GIT_NAME: (( grab meta.git.name )) + RELEASE_BRANCH: (( grab meta.github.release_branch )) - load_var: version file: version/number @@ -315,6 +322,7 @@ jobs: body: gh/notes.md on_failure: put: notify + no_get: true params: channel: (( grab meta.slack.channel )) username: (( grab meta.slack.username )) diff --git a/ci/scripts/release b/ci/scripts/release index 2865e03..825456c 100755 --- a/ci/scripts/release +++ b/ci/scripts/release @@ -11,8 +11,13 @@ set -eu +: ${REPO_ROOT:?required} +: ${RELEASE_ROOT:?required} +: ${RELEASE_NAME:?required} : ${GIT_EMAIL:?required} : ${GIT_NAME:?required} +RELEASE_BRANCH=${RELEASE_BRANCH:-"master"} +: ${REPO_OUT:?required} if [[ ! -f ${REPO_ROOT}/ci/release_notes.md ]]; then echo >&2 "ci/release_notes.md not found. Did you forget to write them?" @@ -46,7 +51,7 @@ if [[ -z $(git config --global user.name) ]]; then fi (cd ${REPO_ROOT} - git merge --no-edit master + git merge --no-edit "${RELEASE_BRANCH}" git add -A git status git commit -m "release v${VERSION} [skip ci]") diff --git a/ci/settings.yml b/ci/settings.yml index c2e48fa..8ac5ab6 100644 --- a/ci/settings.yml +++ b/ci/settings.yml @@ -115,6 +115,7 @@ jobs: on_failure: put: notify + no_get: true params: channel: (( grab meta.slack.channel )) username: (( grab meta.slack.username )) @@ -154,7 +155,7 @@ jobs: type: registry-image source: repository: ${DOCKERHUB_REPOSITORY} - tag: "$(< version/number)" + tag: "$(< version/number)" \`\`\` EOF params: