Skip to content

Commit

Permalink
Merge branch 'master' into auth/pm-3000/desktop-account-switcher-urls
Browse files Browse the repository at this point in the history
  • Loading branch information
rr-bw committed Oct 26, 2023
2 parents 4d32a4a + 782f592 commit 81e9ae8
Show file tree
Hide file tree
Showing 647 changed files with 37,256 additions and 3,088 deletions.
5 changes: 1 addition & 4 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,7 @@
]
}
],
"no-restricted-imports": [
"error",
{ "patterns": ["src/**/*"], "paths": ["@fluffy-spoon/substitute"] }
]
"no-restricted-imports": ["error", { "patterns": ["src/**/*"] }]
}
},
{
Expand Down
6 changes: 6 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,9 @@ apps/web/src/locales/en/messages.json

## DevOps team files ##
/.github/workflows @bitwarden/dept-devops

# DevOps for Docker changes.
**/Dockerfile @bitwarden/dept-devops
**/*.Dockerfile @bitwarden/dept-devops
**/.dockerignore @bitwarden/dept-devops
**/entrypoint.sh @bitwarden/dept-devops
10 changes: 1 addition & 9 deletions .github/renovate.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,5 @@
"matchUpdateTypes": "major"
}
],
"ignoreDeps": [
"@types/koa-bodyparser",
"bootstrap",
"electron-builder",
"electron",
"node-ipc",
"regedit",
"zone.js"
]
"ignoreDeps": ["@types/koa-bodyparser", "bootstrap", "node-ipc", "regedit", "zone.js"]
}
2 changes: 1 addition & 1 deletion .github/workflows/brew-bump-cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "brew-bump-workflow-pat"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/brew-bump-desktop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "brew-bump-workflow-pat"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-browser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "crowdin-api-token"
Expand Down Expand Up @@ -437,7 +437,7 @@ jobs:
- name: Retrieve secrets
id: retrieve-secrets
if: failure()
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "devops-alerts-slack-webhook-url"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ jobs:
- name: Retrieve secrets
id: retrieve-secrets
if: failure()
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "devops-alerts-slack-webhook-url"
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/build-desktop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ jobs:
node-gyp install $(node -v)
- name: Install AST
uses: bitwarden/gh-actions/install-ast@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/install-ast@master

- name: Set up environmentF
run: choco install checksum --no-progress
Expand All @@ -312,7 +312,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "code-signing-vault-url,
Expand Down Expand Up @@ -1204,7 +1204,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "crowdin-api-token"
Expand Down Expand Up @@ -1283,7 +1283,7 @@ jobs:
- name: Retrieve secrets
id: retrieve-secrets
if: failure()
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "devops-alerts-slack-webhook-url"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/build-web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ jobs:

- name: Retrieve github PAT secrets
id: retrieve-secret-pat
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "github-pat-bitwarden-devops-bot-repo-scope"
Expand Down Expand Up @@ -273,7 +273,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "crowdin-api-token"
Expand Down Expand Up @@ -334,7 +334,7 @@ jobs:
- name: Retrieve secrets
id: retrieve-secrets
if: failure()
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "devops-alerts-slack-webhook-url"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/crowdin-pull.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "crowdin-api-token, github-gpg-private-key, github-gpg-private-key-passphrase"

- name: Download translations
uses: bitwarden/gh-actions/crowdin@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/crowdin@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CROWDIN_API_TOKEN: ${{ steps.retrieve-secrets.outputs.crowdin-api-token }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/deploy-eu-prod-web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ jobs:

- name: Retrieve Storage Account connection string
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: webvault-westeurope-prod
secrets: "sa-bitwarden-web-vault-dev-key-temp"

- name: Download latest cloud asset
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-web.yml
path: apps/web
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/deploy-eu-qa-web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ jobs:

- name: Retrieve Storage Account connection string
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: webvaulteu-westeurope-qa
secrets: "sa-bitwarden-web-vault-dev-key-temp"

- name: Download latest cloud asset
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-web.yml
path: apps/web
Expand Down
50 changes: 47 additions & 3 deletions .github/workflows/deploy-non-prod-web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,55 @@ jobs:
echo "environment-branch=cf-pages-$ENV_NAME_LOWER" >> $GITHUB_OUTPUT
echo "environment-artifact=web-*-cloud-${{ inputs.environment }}.zip" >> $GITHUB_OUTPUT
artifact-check:
name: Check if Web artifact is present
runs-on: ubuntu-22.04
needs: setup
env:
_ENVIRONMENT_ARTIFACT: ${{ needs.setup.outputs.environment-artifact }}
steps:
- name: Download latest cloud asset
uses: bitwarden/gh-actions/download-artifacts@master
id: download-artifacts
continue-on-error: true
with:
workflow: build-web.yml
path: apps/web
workflow_conclusion: success
branch: ${{ github.ref_name }}
artifacts: ${{ env._ENVIRONMENT_ARTIFACT }}

- name: Login to Azure
if: ${{ steps.download-artifacts.outcome == 'failure' }}
uses: Azure/login@92a5484dfaf04ca78a94597f4f19fea633851fa2 # v1.4.7
with:
creds: ${{ secrets.AZURE_KV_CI_SERVICE_PRINCIPAL }}

- name: Retrieve secrets for Build trigger
if: ${{ steps.download-artifacts.outcome == 'failure' }}
id: retrieve-secret
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "github-pat-bitwarden-devops-bot-repo-scope"

- name: Build server missing branch
if: ${{ steps.download-artifacts.outcome == 'failure' }}
uses: convictional/trigger-workflow-and-wait@f69fa9eedd3c62a599220f4d5745230e237904be # v1.6.5
with:
owner: bitwarden
repo: clients
github_token: ${{ steps.retrieve-secret.outputs.github-pat-bitwarden-devops-bot-repo-scope }}
workflow_file_name: build-web.yml
ref: ${{ github.ref_name }}
wait_interval: 100

cfpages-deploy:
name: Deploy Web Vault to ${{ inputs.environment }} CloudFlare Pages branch
needs: setup
runs-on: ubuntu-20.04
needs:
- setup
- artifact-check
runs-on: ubuntu-22.04
env:
_ENVIRONMENT: ${{ needs.setup.outputs.environment }}
_ENVIRONMENT_URL: ${{ needs.setup.outputs.environment-url }}
Expand All @@ -67,7 +111,7 @@ jobs:
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3

- name: Download latest cloud asset
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-web.yml
path: apps/web
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/release-browser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
- name: Check Release Version
id: version
uses: bitwarden/gh-actions/release-version-check@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/release-version-check@master
with:
release-type: ${{ github.event.inputs.release_type }}
project-type: ts
Expand Down Expand Up @@ -103,7 +103,7 @@ jobs:

- name: Download latest Release build artifacts
if: ${{ github.event.inputs.release_type != 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-browser.yml
workflow_conclusion: success
Expand All @@ -116,7 +116,7 @@ jobs:

- name: Dry Run - Download latest master build artifacts
if: ${{ github.event.inputs.release_type == 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-browser.yml
workflow_conclusion: success
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/release-cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:
- name: Check Release Version
id: version
uses: bitwarden/gh-actions/release-version-check@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/release-version-check@master
with:
release-type: ${{ github.event.inputs.release_type }}
project-type: ts
Expand All @@ -78,7 +78,7 @@ jobs:

- name: Download all Release artifacts
if: ${{ github.event.inputs.release_type != 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli
Expand All @@ -87,7 +87,7 @@ jobs:

- name: Dry Run - Download all artifacts
if: ${{ github.event.inputs.release_type == 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli
Expand Down Expand Up @@ -150,7 +150,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "snapcraft-store-token"
Expand All @@ -160,7 +160,7 @@ jobs:

- name: Download artifacts
if: ${{ github.event.inputs.release_type != 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli
Expand All @@ -170,7 +170,7 @@ jobs:

- name: Dry Run - Download artifacts
if: ${{ github.event.inputs.release_type == 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli
Expand Down Expand Up @@ -204,7 +204,7 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "cli-choco-api-key"
Expand All @@ -220,7 +220,7 @@ jobs:

- name: Download artifacts
if: ${{ github.event.inputs.release_type != 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli/dist
Expand All @@ -230,7 +230,7 @@ jobs:

- name: Dry Run - Download artifacts
if: ${{ github.event.inputs.release_type == 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli/dist
Expand Down Expand Up @@ -263,14 +263,14 @@ jobs:

- name: Retrieve secrets
id: retrieve-secrets
uses: bitwarden/gh-actions/get-keyvault-secrets@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/get-keyvault-secrets@master
with:
keyvault: "bitwarden-ci"
secrets: "npm-api-key"

- name: Download artifacts
if: ${{ github.event.inputs.release_type != 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli/build
Expand All @@ -280,7 +280,7 @@ jobs:

- name: Dry Run - Download artifacts
if: ${{ github.event.inputs.release_type == 'Dry Run' }}
uses: bitwarden/gh-actions/download-artifacts@f1125802b1ccae8c601d7c4f61ce39ea254b10c8
uses: bitwarden/gh-actions/download-artifacts@master
with:
workflow: build-cli.yml
path: apps/cli/build
Expand Down
Loading

0 comments on commit 81e9ae8

Please sign in to comment.