-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
39c5e98
commit 7f38c20
Showing
2 changed files
with
33 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,42 @@ | ||
# Docker | ||
# Running Cupdate in Docker | ||
|
||
Cupdate is made to run in Docker by mounting the Docker socket. Cupdate will | ||
poll the socket for changes, reacting on changes made to containers. | ||
|
||
To get started, run the following command to run Cupdate and expose its UI and | ||
API on port 8080. | ||
|
||
```shell | ||
docker run --detach --volume /var/run/docker.sock:/var/run/docker.sock ghcr.io/alexgustafsson/cupdate:latest | ||
docker run --interactive --tty --rm \ | ||
--volume "/var/run/docker.sock:/var/run/docker.sock:ro" \ | ||
--mount type=tmpfs,destination=/tmp \ | ||
--env CUPDATE_DOCKER_HOST=unix:///var/run/docker.sock \ | ||
--publish 8080:8080 \ | ||
ghcr.io/alexgustafsson/cupdate | ||
``` | ||
|
||
See also the Docker compose example in [compose.yaml](compose.yaml). | ||
To more easily configure Cupdate to your liking and persisting the configuration | ||
it is recommended to use Docker Compose. To run Cupdate with Docker Compose, run | ||
the following command. | ||
|
||
```shell | ||
docker compose up -f ./compose.yaml | ||
docker compose -f ./docs/docker/compose.yaml up | ||
``` | ||
|
||
The Compose file is configured using best practices, but can be adapted to suite | ||
your needs. | ||
|
||
## Config | ||
|
||
For Docker, Cupdate requires the Docker host to be specified. For now, Cupdate | ||
only supports using the Docker socket immediately. It should be configured using | ||
the `CUPDATE_DOCKER_HOST` environment variable, setting it to | ||
`unix:///var/run/docker.sock`, for example. | ||
When running Cupdate using Docker, the Docker host needs to be specified. For | ||
now, Cupdate only supports using the Docker socket immediately. Its path should | ||
be configured using the `CUPDATE_DOCKER_HOST` environment variable, setting it | ||
to `unix:///var/run/docker.sock`, for example. | ||
|
||
By default, only running containers are used by Cupdate. To use all containers, | ||
set `CUPDATE_DOCKER_INCLUDE_ALL_CONTAINERS` to `true`. | ||
By default, only running containers are processed by Cupdate. To process all | ||
containers, running or not, set `CUPDATE_DOCKER_INCLUDE_ALL_CONTAINERS` to | ||
`true`. | ||
|
||
See also [config.md](../config.md). | ||
Whilst the commands above are enough to get you started with Cupdate, you might | ||
want to change some configuration to better suite your needs. Please see the | ||
additional documentation in [../config.md](../config.md). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters