-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
121 lines (101 loc) · 3.4 KB
/
Makefile
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
SHELL := /bin/bash
# set default target
DBT_TARGET ?= dev
AWS_LAMBDA_ROLE ?= aws_lambda_flow_api_dev
INVOKE_STREAMS ?= True
dbt-console:
docker-compose run dbt_console
.PHONY: dbt-console
sl-flow-api:
dbt run-operation create_aws_flow_api \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt/
udfs:
dbt run-operation create_udfs \
--vars '{"UPDATE_UDFS_AND_SPS":True}' \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt/
udf_2:
dbt run-operation create_udf_bulk_grpc_us_east_2 \
--vars '{"UPDATE_UDFS_AND_SPS":True}' \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt/
complete:
dbt run \
--vars '{"STREAMLINE_INVOKE_STREAMS":True, "STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/core/complete \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt
grant-streamline-privileges:
dbt run-operation grant_streamline_privileges \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt/ \
--args '{role: $(AWS_LAMBDA_ROLE)}'
streamline: sl-flow-api udfs grant-streamline-privileges streamline_bronze
streamline_bronze:
dbt run \
--vars '{"STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/bronze \
--profiles-dir ~/.dbt \
--target $(DBT_TARGET) \
--profile flow
blocks_history:
dbt run \
--vars '{"STREAMLINE_INVOKE_STREAMS":True, "STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/core/history/blocks/streamline__get_blocks_history_mainnet22.sql \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt
collections_history:
dbt run \
--vars '{"STREAMLINE_INVOKE_STREAMS":True, "STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/core/history/collections/streamline__get_collections_history_mainnet22.sql \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt
tx_history:
dbt run \
--vars '{"STREAMLINE_INVOKE_STREAMS":True, "STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/core/history/transactions/streamline__get_transactions_history_mainnet22.sql \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt
tx_results_history:
dbt run \
--vars '{"STREAMLINE_INVOKE_STREAMS":True, "STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/core/history/transaction_results/streamline__get_transaction_results_history_mainnet_18.sql \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt
tx_results_batch_history:
dbt run \
--vars '{"STREAMLINE_INVOKE_STREAMS": $(INVOKE_STREAMS), "STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/core/history/transaction_results/batch/streamline__get_batch_transaction_results_history_mainnet_19.sql \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt
tx_batch_history:
dbt run \
--vars '{"STREAMLINE_INVOKE_STREAMS": $(INVOKE_STREAMS), "STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
-m 1+models/streamline/core/history/transactions/batch/streamline__get_batch_transactions_mainnet_18.sql \
--profile flow \
--target dev \
--profiles-dir ~/.dbt
lq_overloads:
dbt run \
-s models/deploy/core/ \
--profile flow \
--target $(DBT_TARGET) \
--profiles-dir ~/.dbt \
--vars '{"UPDATE_EPHEMERAL_UDFS":True}'
bronze:
dbt run \
-s bronze__streamline_transaction_results_history \
--vars '{"STREAMLINE_USE_DEV_FOR_EXTERNAL_TABLES": True}' \
--profiles-dir ~/.dbt \
--target $(DBT_TARGET)