Skip to content

Commit

Permalink
Merge pull request #2 from valory-xyz/fix/scripting
Browse files Browse the repository at this point in the history
Fix/scripting
  • Loading branch information
0xArdi authored Nov 20, 2024
2 parents 154f1c6 + 7f0aade commit 1964950
Show file tree
Hide file tree
Showing 6 changed files with 509 additions and 528 deletions.
8 changes: 4 additions & 4 deletions .api_keys.json.example
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"openai": [
"Your #1 OpenAI API key here",
"Your #2 OpenAI API key here"
"YOUR_#1_KEY_HERE",
"YOUR_#2_KEY_HERE"
],
"google_api_key": [
"Your #1 Google API key here",
"Your #2 Google API key here"
"YOUR_#1_KEY_HERE",
"YOUR_#2_KEY_HERE"
]
}
27 changes: 14 additions & 13 deletions operate/services/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -471,19 +471,20 @@ def _build_docker(
(build / volume).mkdir(exist_ok=True)
_volumes.append(f"./{volume}:{mount}:Z")

for node in deployment["services"]:
if "abci" in node:
deployment["services"][node]["volumes"].extend(_volumes)
if (
"SKILL_TRADER_ABCI_MODELS_PARAMS_ARGS_MECH_REQUEST_PRICE=0"
in deployment["services"][node]["environment"]
):
deployment["services"][node]["environment"].remove(
"SKILL_TRADER_ABCI_MODELS_PARAMS_ARGS_MECH_REQUEST_PRICE=0"
)
deployment["services"][node]["environment"].append(
"SKILL_TRADER_ABCI_MODELS_PARAMS_ARGS_MECH_REQUEST_PRICE=10000000000000000"
)
# not needed and causes issues
# for node in deployment["services"]:
# if "abci" in node:
# deployment["services"][node]["volumes"].extend(_volumes)
# if (
# "SKILL_TRADER_ABCI_MODELS_PARAMS_ARGS_MECH_REQUEST_PRICE=0"
# in deployment["services"][node]["environment"]
# ):
# deployment["services"][node]["environment"].remove(
# "SKILL_TRADER_ABCI_MODELS_PARAMS_ARGS_MECH_REQUEST_PRICE=0"
# )
# deployment["services"][node]["environment"].append(
# "SKILL_TRADER_ABCI_MODELS_PARAMS_ARGS_MECH_REQUEST_PRICE=10000000000000000"
# )

with (build / DOCKER_COMPOSE_YAML).open("w", encoding="utf-8") as stream:
yaml_dump(data=deployment, stream=stream)
Expand Down
Loading

0 comments on commit 1964950

Please sign in to comment.