未验证 提交 9211694a 编写于 作者: I ImPerat0R_ 提交者: GitHub

Merge pull request #61 from zhongjiajie/change_filename

Change filename to Airflow source filename
......@@ -4,7 +4,7 @@
原文:
+ [在线阅读](https://airflow.apache.org/)
+ [在线阅读](https://airflow.apache.org/)
负责人:
......@@ -14,60 +14,59 @@
## 目录
+ [1 项目](zh/1.md)
+ [2 协议](zh/2.md)
+ [3 快速开始](zh/3.md)
+ [4 安装](zh/4.md)
+ [5 教程](zh/5.md)
+ [6 操作指南](zh/6.md)
+ [7 设置配置选项](zh/7.md)
+ [8 初始化数据库后端](zh/8.md)
+ [9 使用Operators](zh/9.md)
+ [10 管理连接](zh/10.md)
+ [11 保护连接](zh/11.md)
+ [12 写日志](zh/12.md)
+ [13 用Celery扩大规模](zh/13.md)
+ [14 用Dask扩展](zh/14.md)
+ [15 使用Mesos扩展(社区贡献)](zh/15.md)
+ [16 使用systemd运行Airflow](zh/16.md)
+ [17 用upstart运行Airflow](zh/17.md)
+ [18 使用测试模式配置](zh/18.md)
+ [19 UI /截图](zh/19.md)
+ [20 概念](zh/20.md)
+ [21 数据分析](zh/21.md)
+ [22 命令行界面](zh/22.md)
+ [23 调度和触发器](zh/23.md)
+ [24 插件](zh/24.md)
+ [25 安全](zh/25.md)
+ [26 时区](zh/26.md)
+ [27 实验性 Rest API](zh/27.md)
+ [28 集成](zh/28.md)
+ [29 Lineage](zh/29.md)
+ [30 常见问题](zh/30.md)
+ [31 API 参考](zh/31.md)
+ [项目](zh/project.md)
+ [协议](zh/license.md)
+ [快速开始](zh/start.md)
+ [安装](zh/installation.md)
+ [教程](zh/tutorial.md)
+ [操作指南](zh/howto/index.md)
+ [设置配置选项](zh/howto/set-config.md)
+ [初始化数据库后端](zh/howto/initialize-database.md)
+ [使用Operators](zh/howto/operator.md)
+ [管理连接](zh/howto/manage-connections.md)
+ [保护连接](zh/howto/secure-connections.md)
+ [写日志](zh/howto/write-logs.md)
+ [用Celery扩大规模](zh/howto/executor/use-celery.md)
+ [用Dask扩展](zh/howto/executor/use-dask.md)
+ [使用Mesos扩展(社区贡献)](zh/15.md)
+ [使用systemd运行Airflow](zh/howto/run-with-systemd.md)
+ [用upstart运行Airflow](zh/howto/run-with-upstart.md)
+ [使用测试模式配置](zh/howto/use-test-config.md)
+ [UI/截图](zh/ui.md)
+ [概念](zh/concepts.md)
+ [数据分析](zh/profiling.md)
+ [命令行界面](zh/cli.md)
+ [调度和触发器](zh/scheduler.md)
+ [插件](zh/plugins.md)
+ [安全](zh/security.md)
+ [时区](zh/timezone.md)
+ [实验性 Rest API](zh/api.md)
+ [集成](zh/integration.md)
+ [数据血缘](zh/lineage.md)
+ [常见问题](zh/faq.md)
+ [API 参考](zh/code.md)
## 流程
### 一、认领
首先查看[整体进度](https://github.com/apachecn/airflow-doc-zh/issues/1),确认没有人认领了你想认领的章节。
然后回复 ISSUE 来认领章节,注明“章节 + QQ 号”。
### 二、校对
校对:
+ 语法
+ 术语使用
+ 代码格式
+ 语法
+ 术语使用
+ 代码格式
### 三、提交
+ `fork` Github 项目
+ 修改`zh`下面的文档
+ `push`
+ `pull request`
+ `fork` Github 项目
+ 修改`zh`下面的文档
+ `push`
+ `pull request`
请见 [Github 入门指南](https://github.com/apachecn/kaggle/blob/master/docs/GitHub)
......@@ -16,6 +16,10 @@
* [@ImPerat0R\_](https://github.com/tssujt)
## 翻译进度
* Airflow 1.10.2 文档已翻译完成
## 贡献指南
[请见这里](CONTRIBUTING.md)
......
+ [项目](zh/1.md)
+ [协议](zh/2.md)
+ [快速开始](zh/3.md)
+ [安装](zh/4.md)
+ [教程](zh/5.md)
+ [操作指南](zh/6.md)
+ [设置配置选项](zh/7.md)
+ [初始化数据库后端](zh/8.md)
+ [使用Operators](zh/9.md)
+ [管理连接](zh/10.md)
+ [保护连接](zh/11.md)
+ [写日志](zh/12.md)
+ [使用Celery扩大规模](zh/13.md)
+ [使用Dask扩展](zh/14.md)
+ [使用Mesos扩展(社区贡献)](zh/15.md)
+ [使用systemd运行Airflow](zh/16.md)
+ [使用upstart运行Airflow](zh/17.md)
+ [使用测试模式配置](zh/18.md)
+ [UI /截图](zh/19.md)
+ [概念](zh/20.md)
+ [数据分析](zh/21.md)
+ [命令行接口](zh/22.md)
+ [调度和触发器](zh/23.md)
+ [插件](zh/24.md)
+ [安全](zh/25.md)
+ [时区](zh/26.md)
+ [实验性 Rest API](zh/27.md)
+ [集成](zh/28.md)
+ [Lineage](zh/29.md)
+ [常见问题](zh/30.md)
+ [API 参考](zh/31.md)
+ [项目](zh/project.md)
+ [协议](zh/license.md)
+ [快速开始](zh/start.md)
+ [安装](zh/installation.md)
+ [教程](zh/tutorial.md)
+ [操作指南](zh/howto/index.md)
+ [设置配置选项](zh/howto/set-config.md)
+ [初始化数据库后端](zh/howto/initialize-database.md)
+ [使用Operators](zh/howto/operator.md)
+ [管理连接](zh/howto/manage-connections.md)
+ [保护连接](zh/howto/secure-connections.md)
+ [写日志](zh/howto/write-logs.md)
+ [使用Celery扩大规模](zh/howto/executor/use-celery.md)
+ [使用Dask扩展](zh/howto/executor/use-dask.md)
+ [使用Mesos扩展(社区贡献)](zh/15.md)
+ [使用systemd运行Airflow](zh/howto/run-with-systemd.md)
+ [使用upstart运行Airflow](zh/howto/run-with-upstart.md)
+ [使用测试模式配置](zh/howto/use-test-config.md)
+ [UI/截图](zh/ui.md)
+ [概念](zh/concepts.md)
+ [数据分析](zh/profiling.md)
+ [命令行接口](zh/cli.md)
+ [调度和触发器](zh/scheduler.md)
+ [插件](zh/plugins.md)
+ [安全](zh/security.md)
+ [时区](zh/timezone.md)
+ [实验性 Rest API](zh/api.md)
+ [集成](zh/integration.md)
+ [数据血缘](zh/lineage.md)
+ [常见问题](zh/faq.md)
+ [API 参考](zh/code.md)
# 操作指南
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)
[快速开始](zh/3.md)部分设置沙箱很容易; 建设一个生产级环境则需要更多的工作!
这些操作指南将指导您完成使用和配置 Airflow 环境的常见任务。
* [设置配置选项](zh/7.md)
* [初始化数据库后端](zh/8.md)
* [使用Operators](zh/9.md)
* [BashOperator](zh/9.md)
* [PythonOperator](zh/9.md)
* [Google Cloud Platform Operators](zh/9.md)
* [管理连接](zh/10.md)
* [使用 UI 创建连接](zh/10.md)
* [使用 UI 编辑连接](zh/10.md)
* [使用环境变量创建连接](zh/10.md)
* [连接类型](zh/10.md)
* [保护连接](zh/11.md)
* [写日志](zh/12.md)
* [在本地编写日志](zh/12.md)
* [将日志写入 Amazon S3](zh/12.md)
* [将日志写入 Azure Blob 存储](zh/12.md)
* [将日志写入 Google 云端存储](zh/12.md)
* [用 Celery 扩大规模](zh/13.md)
* [用 Dask 扩展](zh/14.md)
* [使用 Mesos 扩展(社区贡献)](zh/15.md)
* [任务直接在 mesos 从站上执行](zh/15.md)
* [在 mesos 从站上的容器中执行的任务](zh/15.md)
* [使用 systemd 运行 Airflow](zh/16.md)
* [用 upstart 运行 Airflow](zh/17.md)
* [使用测试模式配置](zh/18.md)
# 概念
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt) [@zhongjiajie](https://github.com/zhongjiajie)
Airflow Platform 是用于描述,执行和监控工作流的工具。
......@@ -86,7 +86,7 @@ Airflow 为许多常见任务提供 Operator ,包括:
如果将 Operator 分配给 DAG,则 Operator 仅由 Airflow 加载。
请参阅[使用Operators](zh/9.md)了解如何使用 Airflow Operator 。
请参阅[使用Operators](zh/howto/operator.md)了解如何使用 Airflow Operator 。
#### DAG 分配
......@@ -224,9 +224,9 @@ Airflow 还能够通过操作系统中的环境变量引用连接。但它只支
如果在 Airflow 元数据数据库和环境变量中都定义了具有相同`conn_id`连接,则 Airflow 将仅引用环境变量中的连接(例如,给定`conn_id` `postgres_master`,在开始搜索元数据数据库之前,Airflow 将优先在环境变量中搜索`AIRFLOW_CONN_POSTGRES_MASTER`并直接引用它)。
许多钩子都有一个默认的`conn_id`,使用该挂钩的 Operator 不需要提供显式连接 ID。 例如,[`PostgresHook`](zh/31.md)的默认`conn_id``postgres_default`
许多钩子都有一个默认的`conn_id`,使用该挂钩的 Operator 不需要提供显式连接 ID。 例如,[`PostgresHook`](zh/code.md)的默认`conn_id``postgres_default`
请参阅[管理连接](zh/10.md)以了解如何创建和管理连接。
请参阅[管理连接](zh/howto/manage-connections.md)以了解如何创建和管理连接。
### 队列
......@@ -262,7 +262,7 @@ def pull_function(**context):
SELECT * FROM {{ task_instance.xcom_pull(task_ids='foo', key='table_name') }}
```
请注意,XCom 与[变量](zh/20.md)类似,但专门用于任务间通信而非全局设置。
请注意,XCom 与[变量](zh/concepts.md)类似,但专门用于任务间通信而非全局设置。
### 变量
......@@ -510,7 +510,7 @@ Here's a [url](www.airbnb.com)
### Jinja 模板
Airflow 充分利用了[Jinja Templating](http://jinja.pocoo.org/docs/dev/)的强大功能,这可以成为与宏结合使用的强大工具(参见[](zh/31.md)部分)。
Airflow 充分利用了[Jinja Templating](http://jinja.pocoo.org/docs/dev/)的强大功能,这可以成为与宏结合使用的强大工具(参见[](zh/code.md)部分)。
例如,假设您希望使用`BashOperator`将执行日期作为环境变量传递给 Bash 脚本。
......
# 常见问题
> 译者:[zhongjiajie](https://github.com/zhongjiajie)
> 译者:[@zhongjiajie](https://github.com/zhongjiajie)
## 为什么我的任务没有被调度?
......
# 操作指南
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)
[快速开始](zh/start.md)部分设置沙箱很容易; 建设一个生产级环境则需要更多的工作!
这些操作指南将指导您完成使用和配置 Airflow 环境的常见任务。
* [设置配置选项](zh/howto/set-config.md)
* [初始化数据库后端](zh/howto/initialize-database.md)
* [使用Operators](zh/howto/operator.md)
* [BashOperator](zh/howto/operator.md)
* [PythonOperator](zh/howto/operator.md)
* [Google Cloud Platform Operators](zh/howto/operator.md)
* [管理连接](zh/howto/manage-connections.md)
* [使用 UI 创建连接](zh/howto/manage-connections.md)
* [使用 UI 编辑连接](zh/howto/manage-connections.md)
* [使用环境变量创建连接](zh/howto/manage-connections.md)
* [连接类型](zh/howto/manage-connections.md)
* [保护连接](zh/howto/secure-connections.md)
* [写日志](zh/howto/write-logs.md)
* [在本地编写日志](zh/howto/write-logs.md)
* [将日志写入 Amazon S3](zh/howto/write-logs.md)
* [将日志写入 Azure Blob 存储](zh/howto/write-logs.md)
* [将日志写入 Google 云端存储](zh/howto/write-logs.md)
* [用 Celery 扩大规模](zh/howto/executor/use-celery.md)
* [用 Dask 扩展](zh/howto/executor/use-dask.md)
* [使用 Mesos 扩展(社区贡献)](zh/15.md)
* [任务直接在 mesos 从站上执行](zh/15.md)
* [在 mesos 从站上的容器中执行的任务](zh/15.md)
* [使用 systemd 运行 Airflow](zh/howto/run-with-systemd.md)
* [用 upstart 运行 Airflow](zh/howto/run-with-upstart.md)
* [使用测试模式配置](zh/howto/use-test-config.md)
# 管理连接
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)、[@ThinkingChen](https://github.com/cdmikechen)
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)、[@ThinkingChen](https://github.com/cdmikechen) [@zhongjiajie](https://github.com/zhongjiajie)
Airflow 需要知道如何连接到您的环境。其他系统和服务的主机名,端口,登录名和密码等信息在 UI 的`Admin->Connection`部分中处理。您编写的 pipeline(管道)代码将引用 Connection 对象的“conn_id”。
......@@ -8,7 +8,7 @@ Airflow 需要知道如何连接到您的环境。其他系统和服务的主机
可以使用 UI 或环境变量创建和管理连接。
有关更多信息,请参阅[Connenctions Concepts](zh/20.md)文档。
有关更多信息,请参阅[Connenctions Concepts](zh/concepts.md)文档。
## 使用 UI 创建连接
......@@ -39,7 +39,7 @@ Airflow 需要知道如何连接到您的环境。其他系统和服务的主机
### Google Cloud Platform
Google Cloud Platform 连接类型支持[GCP 集成](zh/28.md)
Google Cloud Platform 连接类型支持[GCP 集成](zh/integration.md)
#### 对 GCP 进行身份验证
......@@ -56,19 +56,19 @@ Google Cloud Platform 连接类型支持[GCP 集成](zh/28.md) 。
bigquery_default
```
[`BigQueryHook`](zh/28.md)钩子使用。
[`BigQueryHook`](zh/integration.md)钩子使用。
```py
google_cloud_datastore_default
```
[`DatastoreHook`](zh/28.md)钩子使用。
[`DatastoreHook`](zh/integration.md)钩子使用。
```py
google_cloud_default
```
[`GoogleCloudBaseHook`](zh/28.md)[`DataFlowHook`](zh/28.md)[`DataProcHook`](zh/31.md)[`MLEngineHook`](zh/28.md)[`GoogleCloudStorageHook`](zh/28.md)挂钩使用。
[`GoogleCloudBaseHook`](zh/integration.md)[`DataFlowHook`](zh/integration.md)[`DataProcHook`](zh/integration.md)[`MLEngineHook`](zh/integration.md)[`GoogleCloudStorageHook`](zh/integration.md)挂钩使用。
#### 配置连接
......@@ -84,7 +84,7 @@ google_cloud_default
##### Keyfile JSON
磁盘上的[服务帐户](https://cloud.google.com/docs/authentication/)密钥文件(JSON 格式)的内容。 如果使用此方法进行身份验证,建议[保护您的连接](zh/11.md)
磁盘上的[服务帐户](https://cloud.google.com/docs/authentication/)密钥文件(JSON 格式)的内容。 如果使用此方法进行身份验证,建议[保护您的连接](zh/howto/secure-connections.md)
如果使用应用程序默认凭据则不需要
......
# 使用 Operators(执行器)
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)、[@ThinkingChen](https://github.com/cdmikechen)
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)、[@ThinkingChen](https://github.com/cdmikechen) [@zhongjiajie](https://github.com/zhongjiajie)
operator(执行器)代表一个理想情况下是幂等的任务。operator(执行器)决定了 DAG 运行时实际执行的内容。
有关更多信息,请参阅[Operators Concepts](zh/20.md)文档和[Operators API Reference](zh/31.md)
* [BashOperator](zh/9.md)
* [模板](zh/9.md)
* [故障排除](zh/9.md)
* [找不到 Jinja 模板](zh/9.md)
* [PythonOperator](zh/9.md)
* [传递参数](zh/9.md)
* [模板](zh/9.md)
* [Google Cloud Platform Operators](zh/9.md)
* [GoogleCloudStorageToBigQueryOperator](zh/9.md)
* [GceInstanceStartOperator](zh/9.md)
* [GceInstanceStopOperator](zh/9.md)
* [GceSetMachineTypeOperator](zh/9.md)
* [GcfFunctionDeleteOperator](zh/9.md)
* [故障排除](zh/9.md)
* [GcfFunctionDeployOperator](zh/9.md)
* [故障排除](zh/9.md)
* [CloudSqlInstanceDatabaseCreateOperator](zh/9.md)
* [参数](zh/9.md)
* [使用执行器](zh/9.md)
* [模版](zh/9.md)
* [更多信息](zh/9.md)
* [CloudSqlInstanceDatabaseDeleteOperator](zh/9.md)
* [参数](zh/9.md)
* [使用执行器](zh/9.md)
* [模版](zh/9.md)
* [更多信息](zh/9.md)
* [CloudSqlInstanceDatabasePatchOperator](zh/9.md)
* [参数](zh/9.md)
* [使用执行器](zh/9.md)
* [模版](zh/9.md)
* [更多信息](zh/9.md)
* [CloudSqlInstanceDeleteOperator](zh/9.md)
* [参数](zh/9.md)
* [使用执行器](zh/9.md)
* [模版](zh/9.md)
* [更多信息](zh/9.md)
* [CloudSqlInstanceCreateOperator](zh/9.md)
* [参数](zh/9.md)
* [使用执行器](zh/9.md)
* [模版](zh/9.md)
* [更多信息](zh/9.md)
* [CloudSqlInstancePatchOperator](zh/9.md)
* [参数](zh/9.md)
* [使用执行器](zh/9.md)
* [模版](zh/9.md)
* [更多信息](zh/9.md)
有关更多信息,请参阅[Operators Concepts](zh/concepts.md)文档和[Operators API Reference](zh/code.md)
* [BashOperator](zh/howto/operator.md)
* [模板](zh/howto/operator.md)
* [故障排除](zh/howto/operator.md)
* [找不到 Jinja 模板](zh/howto/operator.md)
* [PythonOperator](zh/howto/operator.md)
* [传递参数](zh/howto/operator.md)
* [模板](zh/howto/operator.md)
* [Google Cloud Platform Operators](zh/howto/operator.md)
* [GoogleCloudStorageToBigQueryOperator](zh/howto/operator.md)
* [GceInstanceStartOperator](zh/howto/operator.md)
* [GceInstanceStopOperator](zh/howto/operator.md)
* [GceSetMachineTypeOperator](zh/howto/operator.md)
* [GcfFunctionDeleteOperator](zh/howto/operator.md)
* [故障排除](zh/howto/operator.md)
* [GcfFunctionDeployOperator](zh/howto/operator.md)
* [故障排除](zh/howto/operator.md)
* [CloudSqlInstanceDatabaseCreateOperator](zh/howto/operator.md)
* [参数](zh/howto/operator.md)
* [使用执行器](zh/howto/operator.md)
* [模版](zh/howto/operator.md)
* [更多信息](zh/howto/operator.md)
* [CloudSqlInstanceDatabaseDeleteOperator](zh/howto/operator.md)
* [参数](zh/howto/operator.md)
* [使用执行器](zh/howto/operator.md)
* [模版](zh/howto/operator.md)
* [更多信息](zh/howto/operator.md)
* [CloudSqlInstanceDatabasePatchOperator](zh/howto/operator.md)
* [参数](zh/howto/operator.md)
* [使用执行器](zh/howto/operator.md)
* [模版](zh/howto/operator.md)
* [更多信息](zh/howto/operator.md)
* [CloudSqlInstanceDeleteOperator](zh/howto/operator.md)
* [参数](zh/howto/operator.md)
* [使用执行器](zh/howto/operator.md)
* [模版](zh/howto/operator.md)
* [更多信息](zh/howto/operator.md)
* [CloudSqlInstanceCreateOperator](zh/howto/operator.md)
* [参数](zh/howto/operator.md)
* [使用执行器](zh/howto/operator.md)
* [模版](zh/howto/operator.md)
* [更多信息](zh/howto/operator.md)
* [CloudSqlInstancePatchOperator](zh/howto/operator.md)
* [参数](zh/howto/operator.md)
* [使用执行器](zh/howto/operator.md)
* [模版](zh/howto/operator.md)
* [更多信息](zh/howto/operator.md)
## BashOperator
使用[`BashOperator`](zh/31.md)[Bash](https://www.gnu.org/software/bash/) shell 中执行命令。
使用[`BashOperator`](zh/code.md)[Bash](https://www.gnu.org/software/bash/) shell 中执行命令。
```py
run_this = BashOperator(
......@@ -66,7 +66,7 @@ run_this = BashOperator(
### 模板
您可以使用[Jinja 模板](zh/20.md)来参数化`bash_command`参数。
您可以使用[Jinja 模板](zh/concepts.md)来参数化`bash_command`参数。
```py
also_run_this = BashOperator(
......@@ -96,7 +96,7 @@ t2 = BashOperator(
## PythonOperator
使用[`PythonOperator`](zh/31.md)执行 Python 回调。
使用[`PythonOperator`](zh/code.md)执行 Python 回调。
```py
def print_context ( ds , ** kwargs ):
......@@ -136,15 +136,15 @@ for i in range(5):
### 模板
当您将`provide_context`参数设置为`True`,Airflow 会传入一组额外的关键字参数:一个用于每个[Jinja 模板变量](zh/31.md)和一个`templates_dict`参数。
当您将`provide_context`参数设置为`True`,Airflow 会传入一组额外的关键字参数:一个用于每个[Jinja 模板变量](zh/code.md)和一个`templates_dict`参数。
`templates_dict`参数是模板化的,因此字典中的每个值都被评估为[Jinja 模板](zh/9.md)
`templates_dict`参数是模板化的,因此字典中的每个值都被评估为[Jinja 模板](zh/howto/operator.md)
## Google 云平台 Operators(执行器)
### GoogleCloudStorageToBigQueryOperator
使用[`GoogleCloudStorageToBigQueryOperator`](zh/28.md)执行 BigQuery 加载作业。
使用[`GoogleCloudStorageToBigQueryOperator`](zh/integration.md)执行 BigQuery 加载作业。
### GceInstanceStartOperator
......
# 使用测试模式配置
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)、[@ThinkingChen](https://github.com/cdmikechen)
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)、[@ThinkingChen](https://github.com/cdmikechen) [@zhongjiajie](https://github.com/zhongjiajie)
Airflow 具有一组固定的“test mode”配置选项。您可以随时通过调用`airflow.configuration.load_test_config()`来加载它们(注意此操作不可逆!)。但是,在您有机会调用 load_test_config()之前,会加载一些选项(如 DAG_FOLDER)。为了更快加载测试配置,请在 airflow.cfg 中设置 test_mode:
......@@ -9,4 +9,4 @@ Airflow 具有一组固定的“test mode”配置选项。您可以随时通过
unit_test_mode = True
```
由于 Airflow 的自动环境变量扩展(请参阅[设置配置选项](zh/7.md) ),您还可以设置环境变量`AIRFLOW__CORE__UNIT_TEST_MODE`以临时覆盖 airflow.cfg。
由于 Airflow 的自动环境变量扩展(请参阅[设置配置选项](zh/howto/set-config.md) ),您还可以设置环境变量`AIRFLOW__CORE__UNIT_TEST_MODE`以临时覆盖 airflow.cfg。
......@@ -59,7 +59,7 @@ pip install apache-airflow[postgres,gcp_api]
## 初始化 Airflow 数据库
在您运行任务之前,Airflow 需要初始化数据库。 如果您只是在试验和学习 Airflow,您可以坚持使用默认的 SQLite 选项。 如果您不想使用 SQLite,请查看[初始化数据库后端](zh/8.md)以设置其他数据库。
在您运行任务之前,Airflow 需要初始化数据库。 如果您只是在试验和学习 Airflow,您可以坚持使用默认的 SQLite 选项。 如果您不想使用 SQLite,请查看[初始化数据库后端](zh/howto/initialize-database.md)以设置其他数据库。
配置完成后,若您想要运行任务,需要先初始化数据库:
......
# 集成
> 贡献者:[@morefreeze](https://github.com/morefreeze)
> 贡献者:[@morefreeze](https://github.com/morefreeze) [@zhongjiajie](https://github.com/zhongjiajie)
* [反向代理](#反向代理)
* [Azure:Microsoft Azure](#azuremicrosoft-azure)
* [AWS:亚马逊网络服务](#aws亚马逊网络服务)
* [Databricks](#databricks)
* [GCP:Google云端平台](#gcpgoogle云端平台)
* [反向代理](#反向代理)
* [Azure:Microsoft Azure](#azuremicrosoft-azure)
* [AWS:亚马逊网络服务](#aws亚马逊网络服务)
* [Databricks](#databricks)
* [GCP:Google云端平台](#gcpgoogle云端平台)
## 反向代理
......@@ -432,7 +432,7 @@ load_string(string_data, share_name, directory_name, file_name, **kwargs)
### Logging
可以将 Airflow 配置为在 Azure Blob Storage 中读取和写入任务日志。 请参阅[将日志写入 Azure Blob Storage](zh/12.md#将日志写入azure-blob-storage)
可以将 Airflow 配置为在 Azure Blob Storage 中读取和写入任务日志。 请参阅[将日志写入 Azure Blob Storage](zh/howto/write-logs.md#将日志写入azure-blob-storage)
### Azure Data Lake
......
# 安全
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt)
> 贡献者:[@ImPerat0R\_](https://github.com/tssujt) [@zhongjiajie](https://github.com/zhongjiajie)
默认情况下,所有门都是打开的。限制对 Web 应用程序的访问的一种简单方法是在网络级别执行此操作,比如使用 SSH 隧道。
但也可以通过使用其中一个已提供的认证后端或创建自己的认证后端来打开身份验证。
请务必查看[Experimental Rest API](zh/27.md)以保护 API。
请务必查看[Experimental Rest API](zh/api.md)以保护 API。
## Web 身份验证
......@@ -22,7 +22,7 @@ auth_backend = airflow.contrib.auth.backends.password_auth
启用密码身份验证后,需要先创建初始用户凭据,然后才能登录其他人。未在此身份验证后端的迁移中创建初始用户,以防止默认 Airflow 安装受到攻击。必须通过安装 Airflow 的同一台机器上的 Python REPL 来创建新用户。
```py
```sh
# navigate to the airflow installation directory
$ cd ~/airflow
$ python
......
......@@ -40,4 +40,4 @@ airflow backfill example_bash_operator -s 2015-01-01 -e 2015-01-02
## 下一步是什么?
通过以上的学习,您可以前往[教程](zh/5.md)部分获取更多示例,或者前往[操作指南](zh/6.md)进行更进一步的实践。
通过以上的学习,您可以前往[教程](zh/tutorial.md)部分获取更多示例,或者前往[操作指南](zh/howto/index.md)进行更进一步的实践。
......@@ -179,7 +179,7 @@ t3 = BashOperator(
使用同样的 DAG 构造函数调用,可以使用`user_defined_macros`来定义您自己的变量。例如,将`dict(foo='bar')`传递给此参数允许您在模板中使用`{{ foo }}` 。此外,允许您指定`user_defined_filters`来注册自己的过滤器。例如,将`dict(hello=lambda name: 'Hello %s' % name)`传递给此参数可以允许您在你的模板中使用`{{ 'world' | hello }}`。有关自定义过滤器的更多信息,请查看[Jinja 文档](http://jinja.pocoo.org/docs/dev/api/#writing-filters)
有关可以在模板中引用的变量和宏的更多信息,请务必阅读[](zh/31.md)部分
有关可以在模板中引用的变量和宏的更多信息,请务必阅读[](zh/code.md)部分
## 设置依赖关系
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册