Allows user to define BUILD_ variables

This commit is contained in:
Arsenii Petrovich 2019-06-23 16:50:04 +03:00
parent e2357c3807
commit 620d14ba65
2 changed files with 8 additions and 1 deletions

View File

@ -47,4 +47,4 @@ env_vars:
#SPANDEX_SYNC_THRESHOLD: # Spandex and Datadog configuration setting.
#BLOCK_COUNT_CACHE_PERIOD: 600 #Time to live of block count cache in milliseconds
#ALLOWED_EVM_VERSIONS: "homestead, tangerineWhistle, spuriousDragon, byzantium, constantinople, petersburg" # the comma-separated list of allowed EVM versions for contracts verification
#BUILD_* - redefine variables with BUILD_ prefix to override parameters used for building the dev server

View File

@ -115,6 +115,13 @@
server_env: "{{ upper_env | combine({'NETWORK_PATH':'/','PORT':server_port}) }}"
tags:
- build
- name: Override build variables
set_fact:
server_env: "{{ server_env | combine({item.key|regex_replace('BUILD_'):item.value}) if item.key | search('BUILD_') else server_env }}"
with_dict: "{{ server_env }}"
tags:
- build
- name: Compile BlockScout
command: "mix do {{ item }}"