crazy-max / diun

Receive notifications when an image is updated on a Docker registry
https://crazymax.dev/diun/
MIT License
3.08k stars 115 forks source link

Add command to check for updates #612

Open rafipiccolo opened 2 years ago

rafipiccolo commented 2 years ago

i found this command diun image list But it only shows the most recent image available.

i'd like to have a "one shot view" of all images with updates available to deploy updates manually.

Currently when i look at the logs i only see this line when there is a new image available.

INF New image found image=xxxxx
Wed, 11 May 2022 18:00:17 CEST INF Jobs completed added=1 failed=0 skipped=0 unchanged=61 updated=0

but it doesnt show all "unchanged" images. I have to scroll for that. sometimes i have to scroll very far because the image is not updated in weeks, and i have forgotten to update it so it never reappears.

is it possible ?

scadaguru commented 1 year ago

It will be really nice if it can provide the list on demand when I need all images needs update please! Thanks

crazy-max commented 1 year ago

diun image only interacts with diun database.

I think we could add a new command like diun check for that purpose. This command would list images available for the registered providers and check for updates without adding any records in database.

silversurfer98 commented 5 months ago

Hi, First of all thank you for your great work @crazy-max, I'm encountering a similar issue with Diun, it's not providing a list of which images need to be updated when I run the container for the second time. I require this information for logging purposes, as I'm in the process of developing a Python script which uses docker library to manage image updates using Watchtower. I have specific preferences on which images to update. The challenge lies in Diun not displaying the update list on subsequent runs. It would be a great help for any assistance on this matter. Thanks in advance

my docker-compose.yaml

version: "3.5"

services:
  diun:
    image: crazymax/diun:latest
    container_name: diun
    command: serve
    volumes:
      - "./data:/data"
      - "/var/run/docker.sock:/var/run/docker.sock"
    environment:
      - "TZ=Asia/Kolkata"
      - "LOG_LEVEL=info"
      - "DIUN_WATCH_WORKERS=20"
      - "DIUN_WATCH_SCHEDULE=0 */6 * * *"
      - "DIUN_WATCH_JITTER=30s"
      - "DIUN_WATCH_RUNONSTARTUP=true"
      - "DIUN_PROVIDERS_DOCKER=true"
      - "DIUN_PROVIDERS_DOCKER_WATCHBYDEFAULT=true"

    # labels:
    #   - "diun.enable=true"
    restart: always