-
Notifications
You must be signed in to change notification settings - Fork 792
[BUG] hostPort defined on container ports from "expose" #1691
Copy link
Copy link
Closed
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.
Description
Expected Behavior
The expose keyword's documentation is pretty clear: "Expose ports without publishing them to the host machine".
A port defined in expose should be declared as simple container port, a service should be created to allow access by others pods, but it should not be bound to the host.
Actual Behavior
The container port is created with "hostPort".
Steps To Reproduce
- create docker-compose with a service with
expose: - "8080" - use kompose convert
- check the deployment, it contains hostPort
Kompose Version
1.30.0 (9d8dcb518)
Docker-Compose file
version: '3'
services:
test:
image: test/test
expose:
- "8080"Anything else?
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.