Logstash container crashing on AWS Fargate

Hello,
Im using Below DockerFile and taskdefinition to deploy Logstash container on AWS Fargate.
Issue : Locally it works fine, logstash server start listening on 5044
On Fargate, container crashs with this message /
error: open /usr/share/logstash/config/logstash.yml: no such file or directory

DockerFile
FROM docker.elastic.co/logstash/logstash:8.7.1

TaskDefinition.json

{
    "taskDefinitionArn": "",
    "containerDefinitions": [
        {
            "name": "xxx",
            "image": "",
            "cpu": 4096,
            "memory": 8192,
            "portMappings": [
                {
                    "containerPort": 5044,
                    "hostPort": 5044,
                    "protocol": "tcp"
                }
            ],
            "essential": true,
            "environment": [],
            "mountPoints": [
                {
                    "sourceVolume": "service-storage",
                    "containerPath": "/usr/share/logstash"
                }
            ],
            "volumesFrom": [],
            "logConfiguration": {
                "logDriver": "awslogs",
                "options": {
                    "awslogs-group": "xxx",
                    "awslogs-region": "eu-central-1",
                    "awslogs-stream-prefix": "ecs"
                }
            }
        }
    ],
    "family": "xxx",
    "taskRoleArn": "",
    "executionRoleArn": "",
    "networkMode": "awsvpc",
    "revision": 2,
    "volumes": [
        {
            "name": "service-storage",
            "host": {}
        }
    ],
    "status": "ACTIVE",
    "requiresAttributes": [
        {
            "name": "com.amazonaws.ecs.capability.logging-driver.awslogs"
        },
        {
            "name": "ecs.capability.execution-role-awslogs"
        },
        {
            "name": "com.amazonaws.ecs.capability.ecr-auth"
        },
        {
            "name": "com.amazonaws.ecs.capability.docker-remote-api.1.19"
        },
        {
            "name": "com.amazonaws.ecs.capability.task-iam-role"
        },
        {
            "name": "ecs.capability.execution-role-ecr-pull"
        },
        {
            "name": "ecs.capability.extensible-ephemeral-storage"
        },
        {
            "name": "com.amazonaws.ecs.capability.docker-remote-api.1.18"
        },
        {
            "name": "ecs.capability.task-eni"
        }
    ],
    "placementConstraints": [],
    "compatibilities": [
        "EC2",
        "FARGATE"
    ],
    "requiresCompatibilities": [
        "FARGATE"
    ],
    "cpu": "4096",
    "memory": "8192",
    "ephemeralStorage": {
        "sizeInGiB": 21
    },
    "runtimePlatform": {
        "cpuArchitecture": "X86_64",
        "operatingSystemFamily": "LINUX"
    },
    "registeredAt": "2023-07-18T21:22:58.495Z",
    "registeredBy": "xxx",
    "tags": [
        {
            "key": "Name",
            "value": "xxx"
        }
    ]
}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.