Custom Commands
For deploying your resources, you can add custom options to the final docker command, which is used to run your container.
Caution
Some of the docker native options are not supported, because it could break the Coolify's functionality. If you need any of the unsupported options, please contact us
Supported Options
--ip--ip6--shm-size--cap-add--cap-drop--security-opt--sysctl--device--ulimit--init--ulimit--privileged--gpus--entrypoint
Usage
You can simply add the options to the Custom Docker Options field on the General tab of your resource.
Example: --cap-add SYS_ADMIN --privileged
Custom Entrypoint
The --entrypoint option allows you to override the default entrypoint of a Docker image without building a custom image.
Syntax
Coolify supports three entrypoint syntax variations:
-
Simple entrypoint:
--entrypoint /bin/sh -
Quoted command with arguments:
--entrypoint "sh -c 'npm start'" -
Assignment syntax:
--entrypoint=/usr/local/bin/custom-script
Use Cases
Multiple Service Types from Single Image
Some Docker images, like ServerSideUp PHP, provide multiple entrypoints for different service types:
- Worker processes
- Queue schedulers
- Background jobs
- Web servers
Example for running a Laravel Horizon worker:
--entrypoint php --entrypoint artisan --entrypoint horizonCustom Initialization Scripts
Override the default entrypoint to run custom initialization:
--entrypoint "/app/custom-init.sh"Usage in Coolify
- Navigate to your resource's General tab
- Locate the Custom Docker Options field
- Add your entrypoint option along with any other custom options:
--entrypoint /bin/sh --cap-add SYS_ADMIN - Save and redeploy your application
Note
The entrypoint option is converted to Docker Compose format during deployment, supporting both Dockerfile and Docker Compose build packs.
Docker Compose
Deploy multi-container Docker Compose stacks in Coolify with magic environment variables, persistent storage, healthchecks, and predefined network connections.
Docker Registry
Push built Docker images to any registry with Coolify including custom tags, authentication setup, Swarm mode support, and self-hosted registry configuration.
