-
Notifications
You must be signed in to change notification settings - Fork 62
/
pipeline.yaml
62 lines (54 loc) · 2.17 KB
/
pipeline.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---
resources: ~
dag:
# [Required] Specify the Airflow version of the operators used by the DAG.
airflow_version: 2
# The DAG acronym stands for directed acyclic graph. This block represents
# your data pipeline along with every property and configuration it needs to
# onboard your data.
initialize:
dag_id: copy_gcs_bucket
default_args:
owner: "Google"
# When set to True, keeps a task from getting triggered if the previous schedule for the task hasn’t succeeded
depends_on_past: False
start_date: '2021-03-01'
max_active_runs: 1
schedule_interval: "@once"
catchup: False
default_view: graph
tasks:
- operator: "CloudDataTransferServiceGCSToGCSOperator"
description: "Task to run a GCS to GCS operation using Google resources"
args:
task_id: "gnomad_gcs_bucket_transfer"
timeout: 43200 # 12 hours
retries: 0
wait: True
project_id: bigquery-public-data
source_bucket: "gnomad-public-requester-pays"
destination_bucket: "gcp-public-data--gnomad"
google_impersonation_chain: "{{ var.json.gnomad.service_account }}"
transfer_options:
deleteObjectsUniqueInSink: False
graph_paths:
# This is where you specify the relationships (i.e. directed paths/edges)
# among the tasks specified above. Use the bitshift operator to define the
# relationships and the `task_id` value above to represent tasks.
#
# For more info, see
# https://airflow.apache.org/docs/apache-airflow/stable/tutorial.html#setting-up-dependencies
- "gnomad_gcs_bucket_transfer"