2020-07-01 02:28:31 +00:00
|
|
|
import os
|
2020-04-30 13:14:32 +00:00
|
|
|
|
2022-10-04 07:52:12 +00:00
|
|
|
import yaml
|
2021-05-07 12:14:37 +00:00
|
|
|
|
2021-10-07 11:28:31 +00:00
|
|
|
CONTAINER_WAIT_INTERVAL = "1m"
|
|
|
|
|
2022-12-07 12:38:56 +00:00
|
|
|
SIMPLE_OBJECT_SIZE = os.getenv("SIMPLE_OBJECT_SIZE", "1000")
|
|
|
|
COMPLEX_OBJECT_CHUNKS_COUNT = os.getenv("COMPLEX_OBJECT_CHUNKS_COUNT", "3")
|
|
|
|
COMPLEX_OBJECT_TAIL_SIZE = os.getenv("COMPLEX_OBJECT_TAIL_SIZE", "1000")
|
2021-05-07 12:14:37 +00:00
|
|
|
|
2022-09-28 12:07:16 +00:00
|
|
|
MAINNET_BLOCK_TIME = os.getenv("MAINNET_BLOCK_TIME", "1s")
|
|
|
|
MAINNET_TIMEOUT = os.getenv("MAINNET_TIMEOUT", "1min")
|
|
|
|
MORPH_BLOCK_TIME = os.getenv("MORPH_BLOCK_TIME", "1s")
|
2023-01-09 12:46:03 +00:00
|
|
|
FROSTFS_CONTRACT_CACHE_TIMEOUT = os.getenv("FROSTFS_CONTRACT_CACHE_TIMEOUT", "30s")
|
2021-11-08 09:57:19 +00:00
|
|
|
|
2022-08-15 15:21:23 +00:00
|
|
|
# Time interval that allows a GC pass on storage node (this includes GC sleep interval
|
|
|
|
# of 1min plus 15 seconds for GC pass itself)
|
|
|
|
STORAGE_GC_TIME = os.getenv("STORAGE_GC_TIME", "75s")
|
2021-05-07 12:14:37 +00:00
|
|
|
|
2022-10-04 07:52:12 +00:00
|
|
|
GAS_HASH = os.getenv("GAS_HASH", "0xd2a4cff31913016155e38e474a2c06d08be276cf")
|
2021-04-20 09:51:53 +00:00
|
|
|
|
2023-01-09 12:46:03 +00:00
|
|
|
FROSTFS_CONTRACT = os.getenv("FROSTFS_IR_CONTRACTS_FROSTFS")
|
2021-04-25 10:43:39 +00:00
|
|
|
|
2022-08-25 10:57:55 +00:00
|
|
|
ASSETS_DIR = os.getenv("ASSETS_DIR", "TemporaryDir")
|
2023-02-27 17:34:50 +00:00
|
|
|
DEVENV_PATH = os.getenv("DEVENV_PATH", os.path.join("..", "frostfs-dev-env"))
|
2021-06-25 13:44:42 +00:00
|
|
|
|
2022-10-04 07:52:12 +00:00
|
|
|
# Password of wallet owned by user on behalf of whom we are running tests
|
|
|
|
WALLET_PASS = os.getenv("WALLET_PASS", "")
|
|
|
|
|
2022-10-18 22:01:42 +00:00
|
|
|
|
2022-10-09 20:01:59 +00:00
|
|
|
# Paths to CLI executables on machine that runs tests
|
2022-09-28 12:07:16 +00:00
|
|
|
NEOGO_EXECUTABLE = os.getenv("NEOGO_EXECUTABLE", "neo-go")
|
2023-01-09 12:46:03 +00:00
|
|
|
FROSTFS_CLI_EXEC = os.getenv("FROSTFS_CLI_EXEC", "frostfs-cli")
|
|
|
|
FROSTFS_AUTHMATE_EXEC = os.getenv("FROSTFS_AUTHMATE_EXEC", "frostfs-authmate")
|
|
|
|
FROSTFS_ADM_EXEC = os.getenv("FROSTFS_ADM_EXEC", "frostfs-adm")
|
2022-07-13 14:30:57 +00:00
|
|
|
|
2023-01-09 12:46:03 +00:00
|
|
|
# Config for frostfs-adm utility. Optional if tests are running against devenv
|
|
|
|
FROSTFS_ADM_CONFIG_PATH = os.getenv("FROSTFS_ADM_CONFIG_PATH")
|
2022-07-05 10:17:36 +00:00
|
|
|
|
2022-07-14 07:33:45 +00:00
|
|
|
FREE_STORAGE = os.getenv("FREE_STORAGE", "false").lower() == "true"
|
2022-08-08 14:49:08 +00:00
|
|
|
BIN_VERSIONS_FILE = os.getenv("BIN_VERSIONS_FILE")
|
2022-10-04 07:52:12 +00:00
|
|
|
|
2022-10-09 20:01:59 +00:00
|
|
|
HOSTING_CONFIG_FILE = os.getenv("HOSTING_CONFIG_FILE", ".devenv.hosting.yaml")
|
2022-10-18 22:01:42 +00:00
|
|
|
STORAGE_NODE_SERVICE_NAME_REGEX = r"s\d\d"
|
2022-10-28 00:09:24 +00:00
|
|
|
HTTP_GATE_SERVICE_NAME_REGEX = r"http-gate\d\d"
|
|
|
|
S3_GATE_SERVICE_NAME_REGEX = r"s3-gate\d\d"
|
2022-10-09 20:01:59 +00:00
|
|
|
|
2023-03-09 11:13:51 +00:00
|
|
|
CLI_DEFAULT_TIMEOUT = os.getenv("CLI_DEFAULT_TIMEOUT", None)
|
|
|
|
|
2022-10-04 07:52:12 +00:00
|
|
|
# Generate wallet configs
|
|
|
|
# TODO: we should move all info about wallet configs to fixtures
|
|
|
|
WALLET_CONFIG = os.path.join(os.getcwd(), "wallet_config.yml")
|
|
|
|
with open(WALLET_CONFIG, "w") as file:
|
|
|
|
yaml.dump({"password": WALLET_PASS}, file)
|