This document outlines the conversion of an application defined in a Compose file to ACI objects. At a high-level, each Compose deployment is mapped to a single ACI container group. Each service is mapped to a container in the container group. The Docker ACI integration provides does not allow scaling of services.
The table below lists supported Compose file fields and their ACI counterparts.
Legend:
| Keys | Map | Notes |
|---|---|---|
| Service | ✓ | |
| service.service.build | x | Ignored. No image build support on ACI. |
| service.cap_add, cap_drop | x | |
| service.command | ✓ | Override container Command. On ACI, specifying command will override the image command and entrypoint, if the image has an command or entrypoint defined |
| service.configs | x | |
| service.cgroup_parent | x | |
| service.container_name | x | Service name is used as container name on ACI. |
| service.credential_spec | x | |
| service.deploy | ✓ | |
| service.deploy.endpoint_mode | x | |
| service.deploy.mode | x | |
| service.deploy.replicas | x | Only one replica is started for each service. |
| service.deploy.placement | x | |
| service.deploy.update_config | x | |
| service.deploy.resources | ✓ | Restriction: ACI resource limits cannot be greater than the sum of resource reservations for all containers in the container group. Using container limits that are greater than container reservations will cause containers in the same container group to compete with resources. |
| service.deploy.restart_policy | ✓ | One of: any, none, on-failure. Restriction: All services must have the same restart policy. The entire ACI container group will be restarted if needed. |
| service.deploy.labels | x | ACI does not have container-level labels. |
| service.devices | x | |
| service.depends_on | x | |
| service.dns | x | |
| service.dns_search | x | |
| service.domainname | ✓ | Mapped to ACI DNSLabelName. Restriction: all services must specify the same domainname, if specified. domainname must be unique globally in .azurecontainer.io
|
| service.tmpfs | x | |
| service.entrypoint | x | ACI only supports overriding the container command. |
| service.env_file | ✓ | |
| service.environment | ✓ | |
| service.expose | x | |
| service.extends | x | |
| service.external_links | x | |
| service.extra_hosts | x | |
| service.group_add | x | |
| service.healthcheck | n | |
| service.hostname | x | |
| service.image | ✓ | Private images will be accessible if the user is logged into the corresponding registry at deploy time. Users will be automatically logged in to Azure Container Registry using their Azure login if possible. |
| service.isolation | x | |
| service.labels | x | ACI does not have container-level labels. |
| service.links | x | |
| service.logging | x | |
| service.network_mode | x | |
| service.networks | x | Communication between services is implemented by defining mapping for each service in the shared /etc/hosts file of the container group. Each service can resolve names for other services and the resulting network calls will be redirected to localhost. |
| service.pid | x | |
| service.ports | ✓ | Only symetrical por mapping is supported in ACI. See #exposing-ports. |
| service.secrets | ✓ | |
| service.security_opt | x | |
| service.stop_grace_period | x | |
| service.stop_signal | x | |
| service.sysctls | x | |
| service.ulimits | x | |
| service.userns_mode | x | |
| service.volumes | ✓ | Mapped to AZure File Shares. See #persistent-volumes. |
| service.restart | x | Replaced by service.deployment.restart_policy |
| Volume | x | |
| driver | ✓ | See #persistent-volumes. |
| driver_opts | ✓ | |
| external | x | |
| labels | x | |
| Secret | x | |
| TBD | x | |
| Config | x | |
| TBD | x | |