- Create
env.sh
containing your Aiven API token
cat > env.sh <<EOF
export TF_VAR_aiven_api_token=<your api key>
EOF
- Create infrastructure
Note: Update
terraform.tfvars
with your Aiven project name first.
$ source env.sh
$ terraform init
$ terraform plan
$ terraform apply
- Create Python 3 virtualenv and install dependencies
$ python3 -m venv venv
$ source venv/bin/activate
$ pip install -r requirements.txt
- Load reference data into PostgreSQL (requires
psql
to be installed)
$ avn service cli bigdataldn-demo-postgres
defaultdb=> \i scripts/create_postgres_schema.sql;
-
Create ClickHouse materialized view using SQL in
scripts/create_clickhouse_view.sql
-
Prepare environment variables for Python Notebook
$ cd notebooks
$ bash env.sh
Start your prefererred Notebook environment