forked from bitwarden/server
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from vgrassia/test
No PR
- Loading branch information
Showing
1 changed file
with
1 addition
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -67,39 +67,6 @@ jobs: | |
with: | ||
ref: main | ||
|
||
- name: Log in to Azure - CI subscription | ||
uses: Azure/login@e15b166166a8746d1a47596803bd8c1b595455cf # v1.6.0 | ||
with: | ||
creds: ${{ secrets.AZURE_KV_CI_SERVICE_PRINCIPAL }} | ||
|
||
- name: Retrieve secrets | ||
id: retrieve-secrets | ||
uses: bitwarden/gh-actions/get-keyvault-secrets@main | ||
with: | ||
keyvault: "bitwarden-ci" | ||
secrets: "github-gpg-private-key, | ||
github-gpg-private-key-passphrase" | ||
|
||
- name: Import GPG key | ||
uses: crazy-max/ghaction-import-gpg@01dd5d3ca463c7f10f7f4f7b4f177225ac661ee4 # v6.1.0 | ||
with: | ||
gpg_private_key: ${{ steps.retrieve-secrets.outputs.github-gpg-private-key }} | ||
passphrase: ${{ steps.retrieve-secrets.outputs.github-gpg-private-key-passphrase }} | ||
git_user_signingkey: true | ||
git_commit_gpgsign: true | ||
|
||
- name: Set up Git | ||
run: | | ||
git config --local user.email "[email protected]" | ||
git config --local user.name "bitwarden-devops-bot" | ||
- name: Create version branch | ||
id: create-branch | ||
run: | | ||
NAME=version_bump_${{ github.ref_name }}_$(date +"%Y-%m-%d") | ||
git switch -c $NAME | ||
echo "name=$NAME" >> $GITHUB_OUTPUT | ||
- name: Install xmllint | ||
run: | | ||
sudo apt-get update | ||
|
@@ -168,9 +135,7 @@ jobs: | |
run: git commit -m "Bumped version to ${{ steps.set-final-version-output.outputs.version }}" -a | ||
|
||
- name: Push changes | ||
env: | ||
PR_BRANCH: ${{ steps.create-branch.outputs.name }} | ||
run: git push -u origin $PR_BRANCH | ||
run: git push | ||
|
||
- name: Generate GH App token | ||
uses: actions/create-github-app-token@5d869da34e18e7287c1daad50e0b8ea0f506ce69 # v1.11.0 | ||
|
@@ -180,42 +145,6 @@ jobs: | |
private-key: ${{ secrets.BW_GHAPP_KEY }} | ||
owner: ${{ github.repository_owner }} | ||
|
||
- name: Create version PR | ||
id: create-pr | ||
env: | ||
GH_TOKEN: ${{ steps.app-token.outputs.token }} | ||
PR_BRANCH: ${{ steps.create-branch.outputs.name }} | ||
TITLE: "Bump version to ${{ steps.set-final-version-output.outputs.version }}" | ||
run: | | ||
PR_URL=$(gh pr create --title "$TITLE" \ | ||
--base "main" \ | ||
--head "$PR_BRANCH" \ | ||
--label "version update" \ | ||
--label "automated pr" \ | ||
--body " | ||
## Type of change | ||
- [ ] Bug fix | ||
- [ ] New feature development | ||
- [ ] Tech debt (refactoring, code cleanup, dependency upgrades, etc) | ||
- [ ] Build/deploy pipeline (DevOps) | ||
- [X] Other | ||
## Objective | ||
Automated version bump to ${{ steps.set-final-version-output.outputs.version }}") | ||
echo "pr_number=${PR_URL##*/}" >> $GITHUB_OUTPUT | ||
- name: Approve PR | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
PR_NUMBER: ${{ steps.create-pr.outputs.pr_number }} | ||
run: gh pr review $PR_NUMBER --approve | ||
|
||
- name: Merge PR | ||
env: | ||
GH_TOKEN: ${{ steps.app-token.outputs.token }} | ||
PR_NUMBER: ${{ steps.create-pr.outputs.pr_number }} | ||
run: gh pr merge $PR_NUMBER --squash --auto --delete-branch | ||
|
||
|
||
cherry_pick: | ||
name: Cherry-Pick Commit(s) | ||
|