opentf-toolkit-nightly 0.50.0.dev769__py3-none-any.whl → 0.50.0.dev775__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- opentf/scripts/startup.py +36 -1
- {opentf_toolkit_nightly-0.50.0.dev769.dist-info → opentf_toolkit_nightly-0.50.0.dev775.dist-info}/METADATA +1 -1
- {opentf_toolkit_nightly-0.50.0.dev769.dist-info → opentf_toolkit_nightly-0.50.0.dev775.dist-info}/RECORD +6 -6
- {opentf_toolkit_nightly-0.50.0.dev769.dist-info → opentf_toolkit_nightly-0.50.0.dev775.dist-info}/LICENSE +0 -0
- {opentf_toolkit_nightly-0.50.0.dev769.dist-info → opentf_toolkit_nightly-0.50.0.dev775.dist-info}/WHEEL +0 -0
- {opentf_toolkit_nightly-0.50.0.dev769.dist-info → opentf_toolkit_nightly-0.50.0.dev775.dist-info}/top_level.txt +0 -0
opentf/scripts/startup.py
CHANGED
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
|
|
17
17
|
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
18
18
|
|
|
19
|
+
from datetime import datetime
|
|
19
20
|
from importlib.metadata import version
|
|
20
21
|
|
|
21
22
|
import base64
|
|
@@ -28,6 +29,7 @@ import sys
|
|
|
28
29
|
import tempfile
|
|
29
30
|
import time
|
|
30
31
|
|
|
32
|
+
|
|
31
33
|
import requests
|
|
32
34
|
import yaml
|
|
33
35
|
|
|
@@ -43,6 +45,7 @@ else:
|
|
|
43
45
|
|
|
44
46
|
########################################################################
|
|
45
47
|
|
|
48
|
+
BOM_FILE = 'BOM.json'
|
|
46
49
|
SERVICEFILE_NAME = 'init_services.json'
|
|
47
50
|
|
|
48
51
|
ENVIRONMENT_VARIABLES = {
|
|
@@ -57,6 +60,7 @@ ENVIRONMENT_VARIABLES = {
|
|
|
57
60
|
'OPENTF_EVENTBUS_WARMUPDELAY': 2,
|
|
58
61
|
'OPENTF_EVENTBUS_WARMUPURL': 'http://127.0.0.1:38368/subscriptions',
|
|
59
62
|
'OPENTF_EVENTBUSCONFIG': 'conf/eventbus.yaml',
|
|
63
|
+
'OPENTF_BASE_URL': None,
|
|
60
64
|
'OPENTF_HEALTHCHECK_DELAY': 60,
|
|
61
65
|
'OPENTF_LAUNCHERMANIFEST': 'squashtf.yaml',
|
|
62
66
|
'OPENTF_PLUGINMANIFEST': 'plugin.yaml',
|
|
@@ -71,7 +75,7 @@ ENVIRONMENT_VARIABLES = {
|
|
|
71
75
|
'HTTPS_PROXY': None,
|
|
72
76
|
'NO_PROXY': None,
|
|
73
77
|
'CURL_CA_BUNDLE': None,
|
|
74
|
-
'
|
|
78
|
+
'PYTHONPATH': None,
|
|
75
79
|
}
|
|
76
80
|
ENVIRONMENT_SECRETS = set()
|
|
77
81
|
|
|
@@ -467,12 +471,43 @@ def check_environment():
|
|
|
467
471
|
)
|
|
468
472
|
|
|
469
473
|
|
|
474
|
+
def maybe_show_bom():
|
|
475
|
+
"""Show BOM if present."""
|
|
476
|
+
try:
|
|
477
|
+
with open(BOM_FILE, 'r', encoding='utf-8') as f:
|
|
478
|
+
bom = json.load(f)
|
|
479
|
+
stats = os.stat(BOM_FILE)
|
|
480
|
+
except Exception:
|
|
481
|
+
logging.warning('Could not read BOM.json, ignoring.')
|
|
482
|
+
return
|
|
483
|
+
logging.info('Image name: %s', bom.get('name', 'Unknown'))
|
|
484
|
+
logging.info('Image build date: %s', datetime.fromtimestamp(stats.st_mtime))
|
|
485
|
+
if base_images := bom.get('base-images'):
|
|
486
|
+
for image in base_images:
|
|
487
|
+
logging.info(
|
|
488
|
+
'Base image: %s (version: %s)', image.get('name'), image.get('version')
|
|
489
|
+
)
|
|
490
|
+
if external_components := bom.get('external-components'):
|
|
491
|
+
logging.debug('External components:')
|
|
492
|
+
for component in external_components:
|
|
493
|
+
logging.debug(
|
|
494
|
+
' %s (version: %s)', component.get('name'), component.get('version')
|
|
495
|
+
)
|
|
496
|
+
if internal_components := bom.get('internal-components'):
|
|
497
|
+
logging.debug('Internal components:')
|
|
498
|
+
for component in internal_components:
|
|
499
|
+
logging.debug(
|
|
500
|
+
' %s (version: %s)', component.get('name'), component.get('version')
|
|
501
|
+
)
|
|
502
|
+
|
|
503
|
+
|
|
470
504
|
########################################################################
|
|
471
505
|
# Main
|
|
472
506
|
|
|
473
507
|
|
|
474
508
|
def main():
|
|
475
509
|
"""Starting all services, as defined in ./squashtf.yaml, waiting."""
|
|
510
|
+
maybe_show_bom()
|
|
476
511
|
try:
|
|
477
512
|
logging.info(
|
|
478
513
|
'OpenTestFactory orchestrator version: %s', version('opentf-orchestrator')
|
|
@@ -41,12 +41,12 @@ opentf/schemas/opentestfactory.org/v1beta1/ServiceConfig.json,sha256=m5ZgWAKbutu
|
|
|
41
41
|
opentf/schemas/opentestfactory.org/v1beta1/Workflow.json,sha256=QZ8mM9PhzsI9gTmwmKTWYNoRn--rtcM3L0PzgnPBfMU,15424
|
|
42
42
|
opentf/schemas/opentestfactory.org/v1beta2/ServiceConfig.json,sha256=rEvK2YWL5lG94_qYgR_GnLWNsaQhaQ-2kuZdWJr5NnY,3517
|
|
43
43
|
opentf/scripts/launch_java_service.sh,sha256=S0jAaCuv2sZy0Gf2NGBuPX-eD531rcM-b0fNyhmzSjw,2423
|
|
44
|
-
opentf/scripts/startup.py,sha256=
|
|
44
|
+
opentf/scripts/startup.py,sha256=R5cUFPDo_LVu-mroctGv2eVFMMfcf9OlufHS-rdfmPY,20016
|
|
45
45
|
opentf/toolkit/__init__.py,sha256=dgT6vRa0kwp9gJ-CNTGk7RPGE6RLfLl1k-QNOC_mwYo,18348
|
|
46
46
|
opentf/toolkit/channels.py,sha256=mgxQbGluL6QLmbmqABELzyoJYCOncxC5XCCbnLH97GY,16763
|
|
47
47
|
opentf/toolkit/core.py,sha256=40S-pUKXWidbI4JwkmQjGq46WlxJshj6d-wEl4e5TxU,7312
|
|
48
|
-
opentf_toolkit_nightly-0.50.0.
|
|
49
|
-
opentf_toolkit_nightly-0.50.0.
|
|
50
|
-
opentf_toolkit_nightly-0.50.0.
|
|
51
|
-
opentf_toolkit_nightly-0.50.0.
|
|
52
|
-
opentf_toolkit_nightly-0.50.0.
|
|
48
|
+
opentf_toolkit_nightly-0.50.0.dev775.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
49
|
+
opentf_toolkit_nightly-0.50.0.dev775.dist-info/METADATA,sha256=HX73VOo0p2IeTxw2QapBYVx-7IYCcQokg8si0OAV5x0,1965
|
|
50
|
+
opentf_toolkit_nightly-0.50.0.dev775.dist-info/WHEEL,sha256=yQN5g4mg4AybRjkgi-9yy4iQEFibGQmlz78Pik5Or-A,92
|
|
51
|
+
opentf_toolkit_nightly-0.50.0.dev775.dist-info/top_level.txt,sha256=_gPuE6GTT6UNXy1DjtmQSfCcZb_qYA2vWmjg7a30AGk,7
|
|
52
|
+
opentf_toolkit_nightly-0.50.0.dev775.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|