node: Add env var to disable block ingestor
@@ -399,6 +399,7 @@ fn async_main() -> impl Future<Item = (), Error = ()> + Send + 'static {
let mut subscription_server =
GraphQLSubscriptionServer::new(&logger, graphql_runner.clone(), store.clone());
+ if env::var_os("DISABLE_BLOCK_INGESTOR").unwrap_or("".into()) != "true" {
// Create Ethereum block ingestor
let block_ingestor = graph_datasource_ethereum::BlockIngestor::new(
store.clone(),
@@ -411,6 +412,7 @@ fn async_main() -> impl Future<Item = (), Error = ()> + Send + 'static {
// Run the Ethereum block ingestor in the background
tokio::spawn(block_ingestor.into_polling_stream());
+ }
// Prepare a block stream builder for subgraphs
let block_stream_builder = BlockStreamBuilder::new(
