1
1
#! /usr/bin/env bash
2
- cd ../../..
3
- echo " Attempting to remove previous Airbyte installation..."
4
- docker-compose down -v
5
- docker-compose up -d
6
- cd resources/examples/airflow || exit
7
- echo " Attempting to remove previous Airflow installation..."
8
- docker-compose -f docker-compose-airflow.yaml down -v
9
- docker-compose -f docker-compose-airflow.yaml up -d
10
- # Create Postgres Database to replicate to.
11
- docker run --rm --name airbyte-destination -e POSTGRES_PASSWORD=password -p 2000:5432 -d postgres
2
+ trap ' kill $ABID; kill $AFID; kill $SSID; kill $PGID; exit' INT
3
+ (
4
+ cd ../../..
5
+ echo " Starting Airbyte..."
6
+ docker-compose down -v
7
+ docker-compose up -d
8
+ )&
9
+ ABID=$!
10
+ (
11
+ echo " Starting Airflow..."
12
+ docker-compose -f docker-compose-airflow.yaml down -v
13
+ docker-compose -f docker-compose-airflow.yaml up -d
14
+ )&
15
+ AFID=$!
16
+ (
17
+ echo " Starting Superset..."
18
+ docker-compose -f superset/docker-compose-superset.yaml down -v
19
+ docker-compose -f superset/docker-compose-superset.yaml up -d
20
+ )&
21
+ SSID=$!
22
+ (
23
+ echo " Creating PG destination (localhost:2000 postgres/password)"
24
+ docker rm --force airbyte-destination
25
+ docker run --rm --name airbyte-destination -e POSTGRES_PASSWORD=password -p 2000:5432 -d postgres
26
+ )&
27
+ PGID=$!
28
+ echo " Waiting for applications to start..."
29
+ wait
12
30
echo " Access Airbyte at http://localhost:8000 and set up a connection."
13
31
echo " Enter your Airbyte connection ID: "
14
32
read connection_id
15
33
# Set connection ID for DAG.
16
34
docker exec -ti airflow_webserver airflow variables set ' AIRBYTE_CONNECTION_ID' " $connection_id "
17
35
docker exec -ti airflow_webserver airflow connections add ' airbyte_example' --conn-uri ' airbyte://host.docker.internal:8000'
18
36
echo " Access Airflow at http://localhost:8085 to kick off your Airbyte sync DAG."
19
- echo " Attempting to remove previous Superset installation."
20
- docker-compose -f superset/docker-compose-superset.yaml down -v
21
- docker-compose -f superset/docker-compose-superset.yaml up -d
22
37
echo " Access Superset at http://localhost:8088 to set up your dashboards."
0 commit comments