The Wayback Machine - https://web.archive.org/web/20210711113016/https://github.com/docker/compose/issues/7004
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ending slash in container path volume handling is buggy #7004

Closed
kiorky opened this issue Nov 6, 2019 · 15 comments
Closed

Ending slash in container path volume handling is buggy #7004

kiorky opened this issue Nov 6, 2019 · 15 comments

Comments

@kiorky
Copy link

@kiorky kiorky commented Nov 6, 2019

Description of the issue

Ending slash in container path volume handling is buggy when merging configs and duplicate mountpoings paths since 1.24.1.

Context information (for bug reports)

Output of docker-compose version

>= 1.24.1

Consider those two configs:

version: "3.7"
services:
  test:
    image: ubuntu
    volumes:
    - prod:/prod
volumes:
  prod:
version: "3.7"
services:
  test:
    volumes:
    - ./dev:/prod/

take care to /prod/

This will fail with Output of docker-compose config

ERROR: Duplicate mount points: [prod:/prod:rw, /home/kiorky/for-tests/fail3/dev:/prod:rw]

But if you remove the ending slash: / in the second config:

version: "3.7"
services:
  test:
    volumes:
    - ./dev:/prod

It will return the expected result

services:
  test:
    image: ubuntu
    volumes:
    - /home/kiorky/for-tests/fail3/dev:/prod:rw
version: '3.7'
volumes:
  prod: {}
@kiorky kiorky added the kind/bug label Nov 6, 2019
@kiorky
Copy link
Author

@kiorky kiorky commented Nov 6, 2019

That was my original issue when i registered #7003

@jcsirot
Copy link
Contributor

@jcsirot jcsirot commented Nov 12, 2019

Hello @kiorky
Thank you for opening this issue
Indeed docker compose behavior indeed changed between 1.23.1 and 1.24.0. We are going to investigate to understand why.

@jcsirot
Copy link
Contributor

@jcsirot jcsirot commented Nov 12, 2019

It seems that docker-compose config with compose 1.23.1 produced a invalid output

services:
  test:
    image: ubuntu
    volumes:
    - /home/jcs/for-tests/issue7004/dev:/prod:rw
    - prod:/prod:rw
version: '3.7'
volumes:
  prod: {}
@kiorky
Copy link
Author

@kiorky kiorky commented Nov 12, 2019

@jcsirot it's tied to the late "duplicate mountpoints" related MRs :

#5948

@kiorky
Copy link
Author

@kiorky kiorky commented Nov 12, 2019

( & #6406 )

@stale
Copy link

@stale stale bot commented May 10, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label May 10, 2020
@stale
Copy link

@stale stale bot commented May 17, 2020

This issue has been automatically closed because it had not recent activity during the stale period.

@stale stale bot closed this May 17, 2020
@kiorky
Copy link
Author

@kiorky kiorky commented May 19, 2020

the bug is still there.

@thaJeztah thaJeztah reopened this May 19, 2020
@stale
Copy link

@stale stale bot commented May 19, 2020

This issue has been automatically marked as not stale anymore due to the recent activity.

@stale stale bot removed the stale label May 19, 2020
@stale
Copy link

@stale stale bot commented Nov 15, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Nov 15, 2020
@kiorky
Copy link
Author

@kiorky kiorky commented Nov 15, 2020

not stale

@stale
Copy link

@stale stale bot commented Nov 15, 2020

This issue has been automatically marked as not stale anymore due to the recent activity.

@stale stale bot removed the stale label Nov 15, 2020
@stale
Copy link

@stale stale bot commented Jun 2, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jun 2, 2021
@stale
Copy link

@stale stale bot commented Jun 10, 2021

This issue has been automatically closed because it had not recent activity during the stale period.

@stale stale bot closed this Jun 10, 2021
@kiorky
Copy link
Author

@kiorky kiorky commented Jun 10, 2021

not stale

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.