Skip to content

Commit

Permalink
feat: Add MongoDb datastore (#36)
Browse files Browse the repository at this point in the history
* feat: Added identities and DocDB
Co-authored-by: Xavier Basty-Kjellberg <[email protected]>
  • Loading branch information
Elyniss authored Jan 23, 2023
1 parent ce1ef82 commit 2edc95d
Show file tree
Hide file tree
Showing 53 changed files with 5,078 additions and 554 deletions.
8 changes: 8 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,11 @@ export AWS_SECRET_ACCESS_KEY=""
export AWS_REGION="eu-central-1"
export TF_VAR_grafana_endpoint=$(aws grafana list-workspaces | jq -r '.workspaces[] | select( .tags.Env == "prod") | .endpoint')
export GRAFANA_AUTH="https://grafana.dev.walletconnect.org/org/apikeys grab one here"

PORT=8080
LOG_LEVEL=ERROR
DATABASE_URL=mongodb://admin:admin@mongo:27017/keyserver?authSource=admin

# Telemetry
TELEMETRY_ENABLED=true
TELEMETRY_GRPC_URL=http://localhost:4317
25 changes: 25 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Description

<!--
Please include:
* summary of the changes and the related issue
* relevant motivation and context
-->

Resolves # (issue)

## How Has This Been Tested?

<!--
Please:
* describe the tests that you ran to verify your changes.
* provide instructions so we can reproduce.
-->

<!-- If valid for smoke test on feature add screenshots -->

## Due Diligence

* [ ] Breaking change
* [ ] Requires a documentation update
* [ ] Requires a e2e/integration test update
12 changes: 10 additions & 2 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@ on:
default: true
required: true
type: boolean
deploy_prod:
description: 'Whether to deploy to production environment after sucessfull staging deployment'
default: false
required: true
type: boolean
workflow_call:
inputs:
deploy_infra:
Expand All @@ -21,6 +26,9 @@ on:
deploy_app:
required: true
type: boolean
deploy_prod:
required: true
type: boolean
secrets:
AWS_ACCESS_KEY_ID:
required: true
Expand Down Expand Up @@ -119,7 +127,7 @@ jobs:
deploy-infra-prod:
# Only deploy if tests passed and deployment windows are open
# Ignore deployment windows if workflow was started manually
if: ${{ always() && inputs.deploy_infra && needs.validate.result == 'success' && (needs.deployment_windows.outputs.result == 'yes' || github.event_name == 'workflow_dispatch') }}
if: ${{ always() && inputs.deploy_infra && inputs.deploy_prod && needs.validate.result == 'success' && (needs.deployment_windows.outputs.result == 'yes' || github.event_name == 'workflow_dispatch') }}
needs: [validate, deployment_windows]
runs-on: ubuntu-latest
environment:
Expand All @@ -146,7 +154,7 @@ jobs:
deploy-app-prod:
# Only deploy if tests passed and deployment windows are open
# Ignore deployment windows if workflow was started manually
if: ${{ always() && inputs.deploy_app && needs.validate.result == 'success' && (needs.deployment_windows.outputs.result == 'yes' || github.event_name == 'workflow_dispatch') }}
if: ${{ always() && inputs.deploy_app && inputs.deploy_prod && needs.validate.result == 'success' && (needs.deployment_windows.outputs.result == 'yes' || github.event_name == 'workflow_dispatch') }}
needs: [validate, deployment_windows]
runs-on: ubuntu-latest
environment:
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -186,8 +186,9 @@ jobs:
kick-off-cd:
needs: [publish]
uses: ./.github/workflows/cd.yaml
uses: ./.github/workflows/cd.yml
with:
deploy_app: true
deploy_infra: false
deploy_prod: false
secrets: inherit
4 changes: 2 additions & 2 deletions .github/workflows/ci_terraform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,9 @@ jobs:
matrix:
source:
- 'terraform'
- 'terraform/docdb'
- 'terraform/ecs'
- 'terraform/monitoring'
- 'terraform/private_zone'
- 'terraform/redis'
steps:
- name: Checkout
uses: actions/checkout@v3
Expand Down Expand Up @@ -129,4 +128,5 @@ jobs:
with:
deploy_app: false
deploy_infra: true
deploy_prod: false
secrets: inherit
Loading

0 comments on commit 2edc95d

Please sign in to comment.