2020-12-20 18:23:06 +01:00
< p style = "text-align: center; margin-left: 1.6rem;" >
2021-04-27 17:44:49 +02:00
< img alt = "Logotype depicting a lighthouse" src = "./images/logo-450px.png" width = "450" / >
2020-12-20 18:23:06 +01:00
< / p >
2019-06-02 13:18:36 +02:00
< h1 align = "center" >
Watchtower
< / h1 >
< p align = "center" >
A container-based solution for automating Docker container base image updates.
< br / > < br / >
2024-07-09 09:22:02 +02:00
< a href = "https://codecov.io/gh/beatkind/watchtower" >
< img alt = "Codecov" src = "https://codecov.io/gh/beatkind/watchtower/branch/main/graph/badge.svg" >
2021-01-12 20:06:11 +01:00
< / a >
2024-07-08 15:18:32 +02:00
< a href = "https://godoc.org/github.com/beatkind/watchtower" >
< img alt = "GoDoc" src = "https://godoc.org/github.com/beatkind/watchtower?status.svg" / >
2019-06-02 13:18:36 +02:00
< / a >
2024-07-08 15:18:32 +02:00
< a href = "https://goreportcard.com/report/github.com/beatkind/watchtower" >
< img alt = "Go Report Card" src = "https://goreportcard.com/badge/github.com/beatkind/watchtower" / >
2019-06-02 13:18:36 +02:00
< / a >
2024-07-08 15:18:32 +02:00
< a href = "https://github.com/beatkind/watchtower/releases" >
2024-07-09 09:22:02 +02:00
< img alt = "latest version" src = "https://img.shields.io/github/tag/beatkind/watchtower.svg" / >
2019-06-02 13:18:36 +02:00
< / a >
< a href = "https://www.apache.org/licenses/LICENSE-2.0" >
2024-07-09 09:22:02 +02:00
< img alt = "Apache-2.0 License" src = "https://img.shields.io/github/license/beatkind/watchtower.svg" / >
2019-06-02 13:18:36 +02:00
< / a >
2024-07-09 09:22:02 +02:00
< a href = "https://hub.docker.com/r/beatkind/watchtower" >
< img alt = "Pulls from DockerHub" src = "https://img.shields.io/docker/pulls/beatkind/watchtower.svg" / >
2020-12-20 18:23:06 +01:00
< / a >
2019-06-02 13:18:36 +02:00
< / p >
2024-07-09 09:33:44 +02:00
# Overview
2024-07-09 09:40:32 +02:00
!!! note "Watchtower fork"
This is a fork of the really nice project from [containrrr ](https://github.com/containrrr ) called [watchtower ](https://github.com/containrrr/watchtower ).
I am not the original author of this project. I just forked it to make some changes to it and keep it up-to-date as properly as I can.
Contributions, tips and hints are welcome. Just open an issue or a pull request. Please be aware that I am by no means a professional developer. I am just a Platform Engineer.
2024-07-09 09:33:44 +02:00
2019-06-02 13:18:36 +02:00
## Quick Start
2021-04-27 11:34:24 +02:00
With watchtower you can update the running version of your containerized app simply by pushing a new image to the Docker
Hub or your own image registry. Watchtower will pull down your new image, gracefully shut down your existing container
and restart it with the same options that were used when it was deployed initially. Run the watchtower container with
the following command:
2019-06-02 13:18:36 +02:00
2021-04-27 11:34:24 +02:00
=== "docker run"
2021-12-27 12:21:41 +01:00
2021-04-27 17:44:49 +02:00
```bash
$ docker run -d \
--name watchtower \
-v /var/run/docker.sock:/var/run/docker.sock \
2024-07-09 09:22:02 +02:00
beatkind/watchtower
2021-04-27 17:44:49 +02:00
```
2021-12-27 12:21:41 +01:00
2021-04-27 11:34:24 +02:00
=== "docker-compose.yml"
2021-12-27 12:21:41 +01:00
2021-04-27 17:44:49 +02:00
```yaml
version: "3"
services:
2021-07-29 01:24:23 -07:00
watchtower:
2024-07-09 09:22:02 +02:00
image: beatkind/watchtower
2021-07-29 01:24:23 -07:00
volumes:
- /var/run/docker.sock:/var/run/docker.sock
2021-06-07 09:45:32 -04:00
```