Skip to content

ECS Compatible env checks for Splunk-Ansible for Docker Support #888

@mattc-splunk

Description

@mattc-splunk

In splunk-ansible/inventory/environ.py

line 98 in the current revision

The system checks for the presence of certain files to allow startup to run

"if os.path.isfile("/.dockerenv") or os.path.isfile("/run/.containerenv") or os.path.isdir("/var/run/secrets/kubernetes.io") or os.environ.get("KUBERNETES_SERVICE_HOST"):"

ECS does not seed these files, so we are required to drop a blank copy of one of these files into the file structure to get it to run properly

Our Dockerfile:


RUN mkdir -p /run

COPY ./images/.containerenv /run/

Please add a check, or change this dependency, so the container will function on ECS

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions