

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# 先决条件
<a name="jupyter-prereqs"></a>

开始之前，请设置以下各项：
+ 一个 Amazon 账户 — 如果你还没有，请从这里开始[设置一个新Amazon账户](setting-up-aws.md)。
+ 有权访问所需权限的 Amazon Identity and Access Management (IAM) 用户 DataBrew — 有关更多信息，请参阅[添加具有 DataBrew 权限的用户或群组](setting-up-iam-users-and-groups-for-databrew.md)。
+ 要在 DataBrew 操作中使用的 IAM 角色 — 您可以使用默认角色（如果`AwsGlueDataBrewDataAccessRole`已配置）。要设置其他 IAM 角色，请参阅[添加具有数据资源权限的 IAM 角色](setting-up-iam-role-to-use-in-databrew.md)。
+  JupyterLab 安装（版本 2.2.6 或更高版本）— 有关更多信息，请参阅[JupyterLab文档](https://JupyterLab.readthedocs.io/en/stable/index.html)中的以下主题：
  + [JupyterLab 先决条件](https://JupyterLab.readthedocs.io/en/stable/getting_started/installation.html#prerequisites)
  + [JupyterLab 安装](https://JupyterLab.readthedocs.io/en/stable/getting_started/installation.html) — 我们建议使用`pip install jupyterlab`。
+ 安装 Node.js（版本 12.0 或更高版本）。
+  Amazon Command Line Interface (Amazon CLI) 安装-有关更多信息，请参阅[设置Amazon CLI](setting-up-the-aws-cli.md)。
+  Amazon Jupyter 代理安装 (`pip install aws-jupyter-proxy`) — 此扩展与 Amazon 服务端点一起使用，可安全地传递您的 Amazon 凭据。有关更多信息，请参阅[aws-jupyter-proxy](https://github.com/aws/aws-jupyter-proxy)上的 GitHub。

要验证是否已安装必备组件，可以在命令行运行与下面类似的测试，如以下示例所示。

```
echo "
AWS CLI:"
which aws
aws --version 
aws configure list
aws sts get-caller-identity

echo "
Python (current environment):"
which python
python --version

echo "
Node.JS:"
which node
node --version 

echo "
Jupyter:"
where jupyter
jupyter --version
jupyter serverextension list
pip3 freeze | grep jupyter
```

输出应与以下内容类似。目录因操作系统和配置而异。

```
AWS CLI:
/usr/local/bin/aws 
aws-cli/2.1.2 Python/3.7.4 Darwin/19.6.0 exe/x86_64
      Name                    Value             Type    Location
      ----                    -----             ----    --------
   profile                <not set>             None    None
access_key     ****************VXW4 shared-credentials-file
secret_key     ****************MRJN shared-credentials-file
    region                us-east-1      config-file    ~/.aws/config
{
    "UserId": "",
    "Account": "111122223333",
    "Arn": "arn:aws:iam::111122223333:user/user2"
}

Python (current environment):
/usr/local/opt/python /libexec/bin/python
Python 3.8.5

Node.JS:
/usr/local/bin/node
v15.0.1

Jupyter:
/usr/local/bin/jupyter
jupyter core     : 4.6.3
jupyter-notebook : 6.0.3
qtconsole        : 4.7.5
ipython          : 7.16.1
ipykernel        : 5.3.2
jupyter client   : 6.1.6
jupyter lab      : 2.2.9
nbconvert        : 5.6.1
ipywidgets       : 7.5.1
nbformat         : 5.0.7
traitlets        : 4.3.3        

config dir: /usr/local/etc/jupyter
    aws_jupyter_proxy  enabled
    - Validating...
      aws_jupyter_proxy  OK
    jupyterlab  enabled
    - Validating...
      jupyterlab 2.2.9 OK

aws-jupyter-proxy==0.1.0
jupyter-client==6.1.7
jupyter-core==4.7.0
jupyterlab==2.2.9
jupyterlab-pygments==0.1.2
jupyterlab-server==1.2.0
```