Skip to content

Service in extends option should be optional #1361

@aanm

Description

@aanm

I think it would be better if the service option to be optional.
compose would look through extends' file and find if there's a service with the same name of the service where the extends option is.

#docker-compose.yml
web:
  extends:
    file: common-services.yml
    #service: web
  environment:
    - DEBUG=1
  cpu_shares: 5
#common-services.yml
web:
  build: .
  ports:
    - "8000:8000"
  volumes:
    - "/data"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions