Skip to content

Commit

Permalink
Merge branch 'feature/cognito-support' of https://github.com/avantife…
Browse files Browse the repository at this point in the history
…llows/plio-analytics into feature/cognito-support
  • Loading branch information
rathorevaibhav committed May 18, 2021
2 parents 3464a3e + d574a9a commit 3d7e5de
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ CUBEJS_SCHEDULED_REFRESH_TIMER=false

# authentication in production mode
CUBEJS_JWK_URL=
CUBEJS_JWT_AUDIENCE=
CUBEJS_JWT_ISSUER=
CUBEJS_JWT_ALGS=
CUBEJS_JWT_CLAIMS_NAMESPACE=
CUBEJS_JWT_AUDIENCE=
10 changes: 5 additions & 5 deletions docs/AUTHENTICATION.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## Authentication
Plio Analytics is based on Cube.js for analytical data storage and querying. As Cube.js relies on external Identity Providers (IdP) for authentication, and so does Plio Analytics.
Plio Analytics is based on Cube.js for analytical data storage and querying. As Cube.js relies on external Identity Providers (IdP) for authentication, so does Plio Analytics.

The following IdP supports are available:
- [Auth0](#auth0)
Expand Down Expand Up @@ -53,12 +53,12 @@ The claim namespace should be your app url. In this case, it would be same as th
Use the steps below to configure Auth0:
1. Log in to your [AWS console](https://aws.amazon.com/console/).
2. Navigate to AWS Cognito console.
3. Choose Manage User Pools and then create a new user pool.
3. Choose `Manage User Pools` and then create a new user pool.
4. Enter the pool name and then click on `Review defaults`.
5. Click on `Create pool`.
6. On the navigation bar on the left-side of the page, choose `App clients` under General settings.
7. Click on `Add an app client`.
1. Enter your app name. You can use `plio-analytics-production`.
1. Enter your app name. You can use `plio-analytics-staging` or `plio-analytics-production` based on the environment you are setting up.
2. (Optional) update settings for token expiration.
3. Make sure to keep the `Generate client secret` option checked.
4. Keep the default `Auth Flows Configuration` values selected.
Expand Down Expand Up @@ -103,13 +103,13 @@ CUBEJS_JWT_CLAIMS_NAMESPACE=<CLAIMS_NAMESPACE>
```

##### `CUBEJS_JWK_URL`
This is the url to fetch the JSON web keys details. Replace the `<USER-POOL-ID>` by the pool id of your user pool. This can be determined from `Your User Pool > General Settings > Pool Id`.
This is the url to fetch the JSON Web Token details. Replace the `<USER-POOL-ID>` by the pool id of your user pool. This can be determined from `Your User Pool > General Settings > Pool Id`.

##### `CUBEJS_JWT_ISSUER`
JWT issuer should be the domain for your Auth0 app. Replace the `<USER-POOL-ID>` by the pool id of your user pool. This can be determined from `Your User Pool > General Settings > Pool Id`.

##### `CUBEJS_JWT_ALGS`
This should be set to RS256 to decode the access token generated by same algorithm.
This should be set to `RS256` to decode the access token generated by same algorithm.

##### `CUBEJS_JWT_CLAIMS_NAMESPACE`
The claim namespace should be your app url. For example, if your Plio analytics app runs at `http://localhost:4000`, use this in the variable.
Expand Down

0 comments on commit 3d7e5de

Please sign in to comment.