Skip to content

[BUG] Kompose should raise and error when profiles are required #1748

@s33kers

Description

@s33kers

Expected Behavior

Resources generated with compose

kompose convert -f docker-compose.yaml -c -v (version 1.29)
output

kompose convert -f docker-compose.yaml -c -v
DEBU Checking validation of provider: kubernetes
DEBU Checking validation of controller:
INFO Network ***-default is detected at Source, shall be converted to equivalent NetworkPolicy at Destination
DEBU Target Dir: docker-compose
INFO Kubernetes file "docker-compose/templates/web-service.yaml" created
INFO Kubernetes file "docker-compose/templates/web-deployment.yaml" created
INFO Kubernetes file "docker-compose/templates/***-default-networkpolicy.yaml" created
INFO chart created in "docker-compose/"

Actual Behavior

No resources generated with compose

kompose convert -f docker-compose.yaml -c -v
output

DEBU Checking validation of provider: kubernetes
DEBU Checking validation of controller:
DEBU Target Dir: docker-compose
INFO chart created in "docker-compose/"

Steps To Reproduce

  1. Create docker-compose.yaml with service and profile
  2. kompose convert -f docker-compose.yaml -c
  3. no templates created

Kompose Version

1.31.2 (a92241f79)
(not working 1.30.0 (9d8dcb518))
(works fine 1.29.0 (997957870))

Docker-Compose file

version: '3'
services:
  web:
    image: nginx
    profiles:
      - test
    ports:
      - 80:80

Anything else?

No response

Metadata

Metadata

Assignees

Labels

kind/bugCategorizes issue or PR as related to a bug.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions