From 840f6f58b61b6e81c225e0a1632980b55505dfc8 Mon Sep 17 00:00:00 2001 From: Ryan Williams Date: Fri, 13 Feb 2026 12:28:40 +0000 Subject: [PATCH 1/3] move yaci store start sync point to env file --- .env.example | 14 ++++++++++++++ .example.env | 6 ------ README.md | 13 +++++++------ indexer/README.md | 10 +++++----- indexer/application.properties | 4 ---- indexer/application.render.properties | 4 ---- 6 files changed, 26 insertions(+), 25 deletions(-) create mode 100644 .env.example delete mode 100644 .example.env diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..bc9610e --- /dev/null +++ b/.env.example @@ -0,0 +1,14 @@ +# Treasury instance within treasury metadata transactions +# this is used to filter out metadata and transactions which are not relevant + +# 9e65e4ed7d6fd86fc4827d2b45da6d2c601fb920e8bfd794b8ecc619 = Intersect 2025 budget instance + +TREASURY_INSTANCE= + +# Sync start point (slot and block hash) +# The indexer will start syncing from this point on first run + +# 160964954 and 560c7537831007f9670d287b15a69ba18a322b1edc39c0c23ccab3c12ad77b9f are good for Intersect 2025 budget instance + +STORE_CARDANO_SYNC_START_SLOT= +STORE_CARDANO_SYNC_START_BLOCKHASH= \ No newline at end of file diff --git a/.example.env b/.example.env deleted file mode 100644 index 44ce2a6..0000000 --- a/.example.env +++ /dev/null @@ -1,6 +0,0 @@ -# Treasury instance within treasury metadata transactions -# this is used to filter out metadata and transactions which are not relevant - -# 9e65e4ed7d6fd86fc4827d2b45da6d2c601fb920e8bfd794b8ecc619 = Intersect 2025 budget instance - -TREASURY_INSTANCE= diff --git a/README.md b/README.md index 954a0b4..2177786 100644 --- a/README.md +++ b/README.md @@ -180,13 +180,14 @@ This environment variable is passed to the indexer container via `docker-compose ### Sync Configuration -| Property | Value | -|----------|-------| -| Network | Mainnet | -| Start Slot | 160964954 | -| Start Block | 12125945 | +The sync start point is configured via environment variables in `.env`: + +```bash +STORE_CARDANO_SYNC_START_SLOT=160964954 +STORE_CARDANO_SYNC_START_BLOCKHASH=560c7537831007f9670d287b15a69ba18a322b1edc39c0c23ccab3c12ad77b9f +``` -Edit `indexer/application.properties` to modify sync settings. +Network settings (host, port, protocol magic) are in `indexer/application.properties`. ## Development Commands diff --git a/indexer/README.md b/indexer/README.md index 3932cec..c9b566e 100644 --- a/indexer/README.md +++ b/indexer/README.md @@ -51,14 +51,14 @@ store.cardano.protocol-magic=764824073 ### Sync Start Point -To start syncing from a specific point: +The sync start point is configured via environment variables in `.env`: -```properties -store.cardano.sync-start-slot=160964954 -store.cardano.sync-start-blockhash=560c7537831007f9670d287b15a69ba18a322b1edc39c0c23ccab3c12ad77b9f +```bash +STORE_CARDANO_SYNC_START_SLOT=160964954 +STORE_CARDANO_SYNC_START_BLOCKHASH=560c7537831007f9670d287b15a69ba18a322b1edc39c0c23ccab3c12ad77b9f ``` -Remove these lines to sync from genesis. +Remove these from `.env` to sync from genesis. ### Enabled Stores diff --git a/indexer/application.properties b/indexer/application.properties index 0af5d55..0b741e3 100644 --- a/indexer/application.properties +++ b/indexer/application.properties @@ -3,10 +3,6 @@ store.cardano.host=backbone.cardano.iog.io store.cardano.port=3001 store.cardano.protocol-magic=764824073 -# Sync Start Point (mainnet slot and block hash) -store.cardano.sync-start-slot=160964954 -store.cardano.sync-start-blockhash=560c7537831007f9670d287b15a69ba18a322b1edc39c0c23ccab3c12ad77b9f - # Database Configuration - Use yaci_store schema spring.datasource.url=jdbc:postgresql://postgres:5432/administration_data?currentSchema=yaci_store spring.datasource.username=postgres diff --git a/indexer/application.render.properties b/indexer/application.render.properties index 2551f5e..d43c03a 100644 --- a/indexer/application.render.properties +++ b/indexer/application.render.properties @@ -3,10 +3,6 @@ store.cardano.host=backbone.cardano.iog.io store.cardano.port=3001 store.cardano.protocol-magic=764824073 -# Sync Start Point (mainnet slot and block hash) -store.cardano.sync-start-slot=160964954 -store.cardano.sync-start-blockhash=560c7537831007f9670d287b15a69ba18a322b1edc39c0c23ccab3c12ad77b9f - # Database Configuration - Uses environment variables from Render # URL is set via SPRING_DATASOURCE_URL env var (converted to JDBC format by entrypoint) spring.datasource.username=${SPRING_DATASOURCE_USERNAME:postgres} From e973a332d9de59ac954ef37a1dd548945b615ee7 Mon Sep 17 00:00:00 2001 From: Ryan Williams Date: Fri, 13 Feb 2026 12:38:58 +0000 Subject: [PATCH 2/3] adjust labelling in env example --- .env.example | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.example b/.env.example index bc9610e..db1bf7f 100644 --- a/.env.example +++ b/.env.example @@ -5,7 +5,7 @@ TREASURY_INSTANCE= -# Sync start point (slot and block hash) +# Sync mainnet start point (slot and block hash) # The indexer will start syncing from this point on first run # 160964954 and 560c7537831007f9670d287b15a69ba18a322b1edc39c0c23ccab3c12ad77b9f are good for Intersect 2025 budget instance From 2556aa77d304dd27af73c91a036a1490b320954c Mon Sep 17 00:00:00 2001 From: Ryan Williams Date: Fri, 13 Feb 2026 12:44:18 +0000 Subject: [PATCH 3/3] update base readme --- README.md | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 2177786..9ad38d0 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Intersect Budget Administration Data -A system to collect on-chain Budget administration data +A system to collect on-chain Budget administration data for instances of [treasury-contracts](https://github.com/SundaeSwap-finance/treasury-contracts) and offer a simple API. Using YACI Store for blockchain indexing, @@ -65,6 +65,7 @@ administration-data/ ### Prerequisites - Docker and Docker Compose +- Create a `.env` based on [`.env.example`](./.env.example) ### Start All Services @@ -172,14 +173,10 @@ TREASURY_INSTANCE=9e65e4ed7d6fd86fc4827d2b45da6d2c601fb920e8bfd794b8ecc619 This environment variable is passed to the indexer container via `docker-compose.yml` and used by the `treasury-filter.mvel` plugin script to filter metadata. -| Property | Value | -|----------|-------| -| Payment Address | `addr1xxzc8pt7fgf0lc0x7eq6z7z6puhsxmzktna7dluahrj6g6v9swzhujsjlls7dajp59u95re0qdk9vh8mumlemw89535s4ecqxj` | -| Stake Address | `stake17xzc8pt7fgf0lc0x7eq6z7z6puhsxmzktna7dluahrj6g6ghh5qjr` | -| Script Hash | `8583857e4a12ffe1e6f641a1785a0f2f036c565cfbe6ff9db8e5a469` | - ### Sync Configuration +Limitation: this is only configured for Mainnet currently + The sync start point is configured via environment variables in `.env`: ```bash