npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

dc-outdated

v1.1.0

Published

Command line utiliy for checking outdated docker-compose images.

Downloads

16

Readme

dc-outdated

Command line utiliy for checking outdated docker-compose images.

dc-outdated (docker-compose-outdated) is a command line utiltiy that allows to easily check for outdated docker images in your docker-compose.yml file (just like outdated command in npm or yarn). Therefore it iterates over each image definition in your docker-compose.yml file, and fetches the latest available tag-name form the appropriate docker registry (according to the semver versioning schema). Tags that do not match the semver versioning schema will be ignored.

Prerequisites

If you are using images from a private registry it is neccessary to login to that registry (docker login command) before executing this application. This is required, since dc-outdated reads login-credentials from the user's docker config file by default. By default, this application searches for a docker-compose.yml file in the current working directory (same behavior as docker-compose utility). Hence, the directory in which the application is executed, must contain a valid docker-compose.yml file. In order to make this tool work correctly it is neccessary that all images in the docker-compose.yml file are specified with a semver compliant tag. Otherwise execution will fail.

Usage

You can use this utilty by installing it globally and executing it in your project's root directory:

npm i -g  dc-outdated
cd /path/to/your/project
dc-outdated

If the compose file contains outdated docker images, the programm will list the outdated image names. Besides the image name, the application will also output the current image version (as specified in the docker-compose.yml file), the next wanted version (max possible version according to the image's current version caret range) and the latest version of the image.

Image                 Current    Wanted[^]    Latest
--------------------  ---------  -----------  ------------
library/rabbitmq      3.6.16     3.7.11       3.8.0-beta.2
library/mongo         3.4.16     3.7.9        4.1.7
library/influxdb      0.13.0     1.7.3        1.7.3

For advanced usage, command line flags can be used to change the default behavoir of the application:

| Flag | Description | | --------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- | | --compose-file | Path to the docker-compose file. Defaults to ./docker-compose.yml | | --docker-config | Path to the docker config file, from which authentication details taken. Defaults to ~/.docker/config.json | | --filter | Filter string to optionally filter the list of checked-images. If specified, only images-names that contain the given search string will be checked | | -x | When scanning the docker-compose.yml file, exclude all images from the offical docker registry, as well as images that do not have a semver compliant tag |

However, for a fully detailed description of all flags that can be used, see the application's usage information (dc-outdated --help).

TODOs

  • For now only docker compose files of version 2.x were tested. For the future docker-compose version 3 should be supported too
  • At this moment checking for outdated images against the official docker registry is not fully working. Hence, only images from a self-hosted docker registry (v2) can be checked reliable. This will be changed in the future so that all kind of docker registries are supported. For now you will have to login to registry-1.docker.io in order to verfy images from offical docker registry.