[FOLIO-3905] folio-ansible: Container environment variables set from configuration clobber all defaults Created: 06/Oct/23  Updated: 10/Oct/23

Status: Open
Project: FOLIO
Components: None
Affects versions: None
Fix versions: None

Type: Bug Priority: TBD
Reporter: Wayne Schneider Assignee: Wayne Schneider
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original estimate: Not Specified

Issue links:
Blocks
is blocked by FOLIO-3906 Upgrade Ansible to v2.15 in Jenkins D... Open
Sprint: DevOps Sprint 160
Development Team: FOLIO DevOps
RCA Group: TBD

 Description   

It appears there is a long-standing bug with the okapi-deployment role in folio-ansible. One of the features of this role is to allow custom container environment variables set in Ansible configuration variables for any given module to be combined with the environment variables that are defined in the launchDescriptor key of the module's module descriptor.

What happens instead is that defining custom environment variables for a module launches the module with ONLY the custom variables defined. The other environment variables defined in the module descriptor are clobbered. This results in confusing behavior, as some of those default variables may be required for a module to work correctly.

It seems likely that FOLIO-3171 Closed was related to this problem; along with other puzzling issues we've had with adding custom environment variables to reference builds.



 Comments   
Comment by Wayne Schneider [ 06/Oct/23 ]

One solution involves using the list_merge feature of the Ansible combine filter. Unfortunately, support for this parameter was added in Ansible 2.10, and we are currently running 2.9 (which is actually past EOL).

Comment by David Crossley [ 09/Oct/23 ]

At FOLIO-3906 Open a new test image Jenkins Docker is ready, using Ansible 2.10.7 (agent: label: jenkins-agent-java17-test).

Used this test image via folio-snapshot-test/509 – success.

Generated at Thu Feb 08 23:31:39 UTC 2024 using Jira 1001.0.0-SNAPSHOT#100246-sha1:7a5c50119eb0633d306e14180817ddef5e80c75d.