Self-hosting Diun the easy way

Self-hosting Diun the easy way

Yulei Chen - Content-Engineerin bei sliplane.ioYulei Chen
5 min

Keeping your Docker images up to date is one of the most important things you can do for security and stability. Diun (Docker Image Update Notifier) is an open-source tool that watches your Docker images and sends you notifications whenever a new version is available on the registry. No more manually checking Docker Hub for updates.

Sliplane makes it easy to deploy Diun as a background service alongside your other containers. With one-click deployment, you can have Diun running in minutes - monitoring your images and alerting you when updates drop.

Prerequisites

Before deploying, ensure you have a Sliplane account (free trial available).

Quick start

Sliplane provides one-click deployment with presets.

SliplaneDeploy Diun >
  1. Click the deploy button above
  2. Select a project
  3. Select a server (If you just signed up you get a 48-hour free trial server)
  4. Click Deploy!

About the preset

The one-click deploy above uses Sliplane's Diun preset. Here's what it includes:

  • Image: crazymax/diun:4.31.0
  • Persistent storage mounted to /data for the Diun database
  • Watch schedule set to every 6 hours by default via cron expression
  • Docker provider enabled by default via environment variables
  • Watch by default turned on, so all containers are checked when the Docker provider can connect

Diun is a background service with no web interface. You interact with it through environment variables and check its output via Sliplane's built-in log viewer.

Note: The Docker provider requires access to the Docker socket (/var/run/docker.sock), which is not mounted by default on Sliplane. Diun will still start and run without it, but it won't discover containers automatically. You can use Diun's file provider to specify which images to watch instead.

Next steps

After deploying, Diun starts running on your server. To get real value from it, you need two things: a list of images to watch and a notification provider to receive alerts.

Setting up notifications

Diun supports many notification providers. Add the relevant environment variables in your Sliplane service settings:

ProviderEnvironment VariableValue
SlackDIUN_NOTIF_SLACK_WEBHOOKURLYour Slack incoming webhook URL
DiscordDIUN_NOTIF_DISCORD_WEBHOOKURLYour Discord webhook URL
TelegramDIUN_NOTIF_TELEGRAM_TOKENYour bot token
DIUN_NOTIF_TELEGRAM_CHATIDSComma-separated chat IDs
WebhookDIUN_NOTIF_WEBHOOK_ENDPOINTYour webhook endpoint URL
DIUN_NOTIF_WEBHOOK_METHODGET or POST

For the full list of supported notification providers (including email, Gotify, Pushover, Matrix, Teams, and more), check the Diun notification docs.

Customizing the watch schedule

By default, Diun checks for image updates every 6 hours. You can change this by setting the DIUN_WATCH_SCHEDULE environment variable to a different cron expression:

ScheduleCron Expression
Every 6 hours0 */6 * * *
Every hour0 * * * *
Once a day at midnight0 0 * * *
Every 30 minutes*/30 * * * *

Checking logs

Since Diun has no web interface, the best way to verify it's running correctly is through Sliplane's log viewer. Navigate to your Diun service and click on "Logs". You should see messages like Diun starting up and reporting its watch schedule.

For more detailed output, set the LOG_LEVEL environment variable to debug. For general Docker logging tips, check out our post on how to use Docker logs.

Environment variables

Here are the key environment variables you can customize:

VariableDefaultDescription
TZEurope/BerlinTimezone for scheduling
LOG_LEVELinfoLog verbosity (debug, info, warn, error)
DIUN_WATCH_SCHEDULE0 */6 * * *Cron expression for check frequency
DIUN_WATCH_JITTER30sRandom delay added to each scheduled run
DIUN_PROVIDERS_DOCKERtrueEnable the Docker provider
DIUN_PROVIDERS_DOCKER_WATCHBYDEFAULTtrueWatch all containers automatically

Cost comparison

You can also self-host Diun with other cloud providers. Here is a pricing comparison for the most common ones:

ProvidervCPURAMDiskMonthly CostNote
Sliplane22 GB40 GB€9 (~$10.65)Flat rate, 1 TB bandwidth, SSL included
Fly.io22 GB40 GB~$18Disk and bandwidth billed separately
Render12 GB40 GB~$35100 GB bandwidth, Disk billed separately
Railway22 GB40 GB~$67 + $20 planPro plan floor, usage-based, bandwidth billed separately
Click here to see how these numbers were calculated.

(Assuming an always-on instance running 730 hrs/month)

  • Sliplane: flat €9/month for the Base server. Unlimited services on the same server, 1 TB egress and SSL included.
  • Fly.io: shared-cpu-2x 2 GB = $11.83/mo + 40 GB volume × $0.15/GB = $6 -> ~$17.83/mo. Egress billed separately ($0.02/GB in EU).
  • Render: closest match is Standard ($25, 1 vCPU / 2 GB) plus 40 GB disk × $0.25/GB = $10 -> ~$35/mo. Stepping up to Pro (2 vCPU / 4 GB) costs $85/mo + disk.
  • Railway (Pro plan): CPU 2 × $0.00000772/s × 2,628,000 s = $40.57; RAM 2 × $0.00000386/s × 2,628,000 s = $20.29; volume 40 × $0.00000006/s × 2,628,000 s = $6.31 -> ~$67/mo compute, plus the $20/mo Pro plan floor and $0.05/GB egress.

Bandwidth costs can add up fast on usage-based providers. Use our bandwidth cost comparison tool to see what your egress would cost on each platform.

FAQ

What does Diun actually do?

Diun monitors Docker images by periodically checking registries (like Docker Hub or GitHub Container Registry) for new versions. When it finds an update, it sends you a notification through your configured provider (Slack, Discord, email, webhook, etc.). It doesn't automatically update your images - it just lets you know that updates are available so you can decide when to upgrade.

Can I choose which containers to watch?

Yes. By default, the preset has DIUN_PROVIDERS_DOCKER_WATCHBYDEFAULT set to true, which means all containers on the server are monitored. If you only want to watch specific containers, set this to false and add the label diun.enable=true to the containers you want to track.

How do I update Diun?

Change the image tag in your Sliplane service settings and redeploy. Check Docker Hub for the latest stable version. Fittingly, Diun will notify you about its own updates too.

Are there alternatives to Diun?

Yes. Watchtower is a popular alternative that can both notify and automatically update containers. Ouroboros is another option, though it's no longer actively maintained. If you're specifically interested in keeping your self-hosted n8n instance up to date, we have a dedicated guide for that. For more Docker tooling, check out 5 awesome Docker tools to make your life easier.

Does Diun use a lot of resources?

No. Diun is very lightweight - it's written in Go and uses minimal CPU and memory. It only runs periodically (every 6 hours by default) and spends most of its time idle. You can easily run it alongside your other services on the same Sliplane server without any performance impact.

Self-host Diun now - It's easy!

Sliplane gives you all the tools you need to run Diun without server hassle.