Skip to content

Commit f14aaa1

Browse files
authored
fix: set licensing timeout environment variables to address persistent connection issues (#547)
* set license timeout env vars and use correct mapdl image * fix error with container args
1 parent d20b679 commit f14aaa1

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ env:
1717
DOC_BUILD_SYC_VERSION: 25_2
1818
FLUENT_IMAGE_VERSION: "v25.2.0"
1919
SYC_IMAGE_VERSION: "v25.2.0"
20-
MAPDL_IMAGE_VERSION: "v25.1-ubuntu"
20+
MAPDL_IMAGE_VERSION: "v25.1-ubuntu-cicd" # TODO: update to 25.2
2121

2222
permissions: {} # Zero permissions can be granted at the workflow level if not all jobs require permissions.
2323
# As a good rule of thumb, this normally includes jobs that don't use secrets.

src/ansys/systemcoupling/core/client/syc_container.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,20 @@ def start_container(
9191

9292
license_server = os.getenv("ANSYSLMD_LICENSE_FILE")
9393
if license_server:
94+
# This is especially necessary in the SYC_CONTAINER_USER case
95+
# because licensing can't log to default location if user is
96+
# not the default 'root'. However it might also be useful
97+
# in other cases to help diagnose license problems as it makes
98+
# the log files accessible on host.
9499
idx = run_args.index("-e")
100+
run_args.insert(idx, f"ANSYSLC_APPLOGDIR={mounted_to}")
101+
run_args.insert(idx, "-e")
102+
# timeout settings fix some license errors we were seeing
103+
run_args.insert(idx, "ANSYSCL_TIMEOUT_RESPONSE=300")
104+
run_args.insert(idx, "-e")
105+
run_args.insert(idx, "ANSYSLI_TIMEOUT_FLEXLM=60")
106+
run_args.insert(idx, "-e")
107+
95108
run_args.insert(idx, f"ANSYSLMD_LICENSE_FILE={license_server}")
96109
run_args.insert(idx, "-e")
97110

0 commit comments

Comments
 (0)