Overwriting ECS Fargate volumesFrom Mounts

0

Is it possible to overwrite a mount that was created via volumesFrom?

We have an nginx container that imports all of the volumes from a php container using volumeFrom. This process auto-mounts all of the volumes defined in the php container to their same paths within the nginx container. For the nginx container, I would like some of those paths to be readonly mounts. I believe I should be able to specify a new mountPoint with the same sourceVolume and containerPath, but set it to read only.

This is not working, so I would appreciate the help.

soleson
질문됨 3년 전497회 조회
1개 답변
0

I was able to resolve this by not using volumesFrom. I was unaware that the volumes introduced via the VOLUMES instruction within a Dockerfile could be made available to other containers in the same task just by mounting it in the initial container and using the same sourceVolume value in another container. By doing this, it allowed for us to mount some volumes readOnly and/or change the containerPath to any value we needed.

soleson
답변함 3년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠