forked from confluentinc/demo-scene
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
52 lines (41 loc) · 1.36 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
build:
docker-compose build --force-rm
cluster:
docker-compose up -d
sqldw:
sed -i '' 's/_SERVER_/${SERVER}/g' azure.sqldw.json
sed -i '' 's/_ADMIN_USER_/${ADMIN_USER}/g' azure.sqldw.json
sed -i '' 's/_ADMIN_PASS_/${ADMIN_PASS}/g' azure.sqldw.json
sed -i '' 's/_DWNAME_/${DWNAME}/g' azure.sqldw.json
az sql server create \
--name ${SERVER} \
--resource-group ${RESOURCE_GROUP} \
--location ${REGION} \
--admin-user ${ADMIN_USER} \
--admin-password ${ADMIN_PASS}
az sql server firewall-rule create \
--name quickstartFirewallRule \
--resource-group ${RESOURCE_GROUP} \
--server ${SERVER} \
--start-ip-address ${IP_ADDRESS} \
--end-ip-address ${IP_ADDRESS}
az sql dw create \
--name ${DWNAME} \
--resource-group ${RESOURCE_GROUP} \
--server ${SERVER}
ps:
docker-compose ps
down:
docker-compose down
az group delete --name ${RESOURCE_GROUP}
topic:
docker exec -it connect kafka-topics --bootstrap-server broker:29092 --create --topic clickstream --partitions 1 --replication-factor 1
connect:
docker exec -it connect curl -d "@/project/azure.sqldw.json" \
-X PUT \
-H "Content-Type: application/json" \
http://connect:8083/connectors/azure-sqldw-sink/config
docker exec -it connect curl -d "@/project/clickstream-connector.json" \
-X PUT \
-H "Content-Type: application/json" \
http://connect:8083/connectors/clickstream/config