Skip to content

Commit 90e7c6c

Browse files
committed
Update authentication section to mention example IAM policies with minimum permissions to deploy and destroy Nebari
1 parent 79229c6 commit 90e7c6c

File tree

1 file changed

+32
-4
lines changed

1 file changed

+32
-4
lines changed

docs/docs/how-tos/nebari-aws.md

Lines changed: 32 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ title: Deploy Nebari on AWS
44
description: A basic overview of how to deploy Nebari on AWS
55
---
66

7+
import CodeBlock from '@theme/CodeBlock';
8+
import DeployPolicy from '!!raw-loader!../../static/policies/aws/deploy.json';
9+
import DestroyPolicy from '!!raw-loader!../../static/policies/aws/destroy.json';
10+
import Tabs from '@theme/Tabs';
11+
import TabItem from '@theme/TabItem';
12+
713
## Introduction
814

915
This guide is to help first-time users set up an Amazon Web Services (AWS) account specifically for the purpose of using and deploying Nebari at a production scale. In this guide
@@ -41,11 +47,33 @@ happens.
4147
## Authentication
4248

4349
In order for Nebari to make requests against the AWS API and create its infrastructure, an authentication method with the appropriate permissions will be required. The best way
44-
to do this is using an [IAM user](https://docs.aws.amazon.com/IAM/latest/UserGuide/introduction.html) with suitable permissions for your AWS account and Elastic Kubernetes Service (EKS).
50+
to do this is using an [IAM user](https://docs.aws.amazon.com/IAM/latest/UserGuide/introduction.html) with all the necessary permissions.
51+
52+
Below are two sets of minimal IAM permissions required to deploy and destroy Nebari. You may either [create separate IAM policies](https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_create-console.html) for each action or combine them into a single policy that includes all permissions.
53+
54+
<details>
55+
<summary>AWS IAM Policies to deploy and destroy Nebari</summary>
56+
<Tabs>
57+
<TabItem value="deploy" label="Deploy Nebari" default>
58+
<CodeBlock language="js">{DeployPolicy}</CodeBlock>
59+
</TabItem>
60+
<TabItem value="destroy" label="Destroy Nebari">
61+
<CodeBlock language="js">{DestroyPolicy}</CodeBlock>
62+
</TabItem>
63+
</Tabs>
64+
</details>
65+
66+
:::note
67+
68+
Make sure to replace the following placeholders in the policies with your own values:
69+
- `REGION`: The AWS region where you want to deploy Nebari (e.g., `us-west-2`)
70+
- `ACCOUNT_ID`: Your AWS account ID (e.g., `123456789012`)
71+
- `PROJECT_NAME`: The name of your Nebari project, specified under the `project_name` field in your `nebari-config.yaml` file (e.g., `my-nebari-project`)
72+
- `NAMESPACE`: The namespace you want to use for your Nebari deployment, specified under the `namespace` field in your `nebari-config.yaml` file (e.g., `dev`)
73+
:::
4574

4675
As a [best practice](https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#lock-away-credentials), do not use the AWS account `root` user for any task where it's not
47-
required. Instead, create a new IAM user for each person that requires administrator access. Then make those users administrators by placing them into an "Administrators" user
48-
group, to which you attach the `AdministratorAccess` managed policy.
76+
required. Instead, create a new IAM user for each person that requires administrator access. Then make those users administrators by placing them into an "Administrators" (or any other name) user group, to which you attach the policies outlined above.
4977

5078
If you are using an already existing IAM user, please refer to
5179
[Managing access keys for IAM users](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html#Using_CreateAccessKey) for detailed information on how to
@@ -63,7 +91,7 @@ Follow these steps to set up your access keys and user accounts:
6391

6492
![Account setup steps for setting your first IAM user on AWS, the image contains an input for creating your username and two item boxes for selecting the type of credential needed for this account](/img/how-tos/how-tos-aws-new-iam-user.png "Creating your IAM user account")
6593

66-
4. Select **Attach existing policies directly**, then select `AdministratorAccess` from the list of policies. For more information, please refer to
94+
4. Select **Attach existing policies directly**, then select the previously created policies to deploy and destroy Nebari from the list of policies. For more information, please refer to
6795
[Policies and permissions in IAM](https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html);
6896
5. Then proceed with the new user creation setup.
6997

0 commit comments

Comments
 (0)