@devtion/backend 0.0.0-ed314b8 → 0.0.0-f784f3a

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +26 -0
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -100,6 +100,32 @@ yarn firebase:init
100
100
 
101
101
  ### Deployment
102
102
 
103
+ #### AWS Infrastructure
104
+
105
+ 0. Login or create a [new AWS Account](https://portal.aws.amazon.com/billing/signup?nc2=h_ct&src=header_signup&redirect_url=https%3A%2F%2Faws.amazon.com%2Fregistration-confirmation#/start/email).
106
+ - The AWS free tier account will cover a good number of requests for ceremonies but there could be some costs based on your ceremony circuits size.
107
+ 1. Create an access key for a user with Admin privileges (__NOT ROOT USER__)
108
+ 2. Setup the `awscli` ([docs](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)) and add the keys for this user.
109
+ 3. Install `terraform` ([docs](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli))
110
+ 4. Decide on an AWS region (by default this is **us-east-1**) - if you want to change you will need to do the following:
111
+ 1. update **aws/lambda/index.mjs** ([exact line](https://github.com/privacy-scaling-explorations/p0tion/blob/dev/packages/backend/aws/lambda/index.mjs#L3)) to the new region
112
+ 2. update **main.tf** ([exact line](https://github.com/privacy-scaling-explorations/p0tion/blob/dev/packages/backend/aws/main.tf#L2)) to the new region
113
+ 5. zip the Lambda folder:
114
+ 1. `cd lambda`
115
+ 2. `zip -r ../lambda.zip .`
116
+ 6. Run terraform:
117
+ 1. `terraform init`
118
+ 2. `terraform plan`
119
+ 3. `terraform apply`
120
+ 4. `terraform output secret_key`
121
+ - To print the secret access key for the IAM user
122
+ 6. Store the other values (sns_topic_arn etc.)
123
+ - These will be needed for the .env file configuration
124
+
125
+ The IAM user created with the steps above can be used for all p0tion's features.
126
+
127
+ #### Firebase
128
+
103
129
  Deploy the current configuration to the `prod` project running
104
130
 
105
131
  ```bash
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devtion/backend",
3
- "version": "0.0.0-ed314b8",
3
+ "version": "0.0.0-f784f3a",
4
4
  "description": "MPC Phase 2 backend for Firebase services management",
5
5
  "repository": "git@github.com:privacy-scaling-explorations/p0tion.git",
6
6
  "homepage": "https://github.com/privacy-scaling-explorations/p0tion",
@@ -85,5 +85,5 @@
85
85
  "publishConfig": {
86
86
  "access": "public"
87
87
  },
88
- "gitHead": "939c38be7a996fab9ec750ac63b70c5b11471809"
88
+ "gitHead": "21133270effb74eced1e8625dc502fff5603593b"
89
89
  }