Deploy to Heroku

Heroku is the easiest way to get started with EventNative. If you don't have an active Heroku account you can signup here!

Getting Running on Heroku

  • Make sure you have an AWS S3 bucket setup. If you don't you can see out tutorial here.

  • Pick a destination for your event data, we recommend starting with Redshift.

  • Click our Deploy to Heroku link.

  • Depending on your destination (Redshift or BigQuery), copy content of corresponding tabto DESTINATIONS_JSON

DESTINATIONS_JSON

Make sure to update all values in <> with your credentials. You can see where to get these from the corresponding guides (Redshift, BigQuery)

Redshift
BigQuery
Postgres
ClickHouse
Redshift
{
"destinations": {
"redshift": {
"datasource": {
"host": "<your_host>",
"db": "<your_db>",
"username": "<your_username>",
"password": "<your_password>"
},
"s3": {
"access_key_id": "<your_access_key>",
"secret_access_key": "<your_secret_access_key>",
"bucket": "<your_bucket>",
"region": "<your_region>"
},
"data_layout": {
"table_name_template": "events"
}
}
}
}
BigQuery
{
"destinations": {
"bigquery": {
"google": {
"gcs_bucket": "<your_bucket>",
"bq_project": "<your_project>",
"key_file": "{place a content of your JSON key here}"
},
"data_layout": {
"table_name_template": "events"
}
}
}
}
Postgres
{
"destinations": {
"postgres": {
"datasource": {
"host": "<your_host>",
"db": "<your_db>",
"username": "<your_username>",
"password": "<your_password>"
},
"data_layout": {
"table_name_template": "events"
}
}
}
}
ClickHouse
{
"destinations": {
"my_clickhouse": {
"type": "clickhouse",
"clickhouse": {
"dsn": "http://username:[email protected]t:port/db?read_timeout=5m&timeout=5m&enable_http_compression=1&other_clickhouse_parameters",
"db": "your_db"
},
"table_name_template": "events"
}
}
}

If you're using BigQuery, please copy JSON content of BigQuery key file and place it under key_file node!

Other parameters

  • GEO_MAXMIND_PATH is not required, however if you want to enable geo resolution of your requests you can learn how to get this setup here.

  • SERVER_AUTH requires you to enter a UUID. You can use the following generator.

  • SERVER_PUBLIC_URL requires you to enter your Heroku app URL in the following format: [your_app].herokuapp.com

  • Click Deploy App and you're live!

  • After your app is deployed, you can visit the following link to confirm deployment https://[your_app].herokuapp.com/

Once your backend is set up, place the following code on your web-app. (See our JavaScript guide for fine-tuning):

<script src="https://[your_app].herokuapp.com/t/inline.js?key=<SERVER_AUTH>" async >
</script>