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 🙏

© 2026 – Pkg Stats / Ryan Hefner

simple-container-monitor

v1.0.4

Published

Docker container monitoring with Notion page integration

Downloads

30

Readme

Docker Container Monitor with Notion Integration

An easily-inspectable TypeScript file without dependencies that you run as a Docker container to show CPU and memory usage stats for all containers in the free Notion mobile app or on the web.

Create a free Notion account with a page and an integration and pass in the information to this monitor and it will update the container stats on the page every minute.

No need to open ports and configure web routes or sign up for expensive monitoring services to get basic container stats in your mobile phone.

Setup

  1. Create a Notion integration:
  • Go to https://www.notion.so/my-integrations
  • Click "New integration" and create an internal integration
  • Name your integration (e.g., "Container Monitor")
  • Select the workspace where you want to use the integration
  • Set the capabilities needed (Read content, Update content, Insert content)
  • Click "Submit" to create the integration
  • Copy the "Internal Integration Token" - this is your NOTION_TOKEN
  1. Create a Notion page for the stats and associate it with your integration:
  • Click "..." in the top right of the page
  • Go to the Connections submenu and select your integration
  • Copy the page ID from the URL (the part after the workspace name and before the question mark) Example: https://www.notion.so/workspace/83c75a51b3b8476b97c0a5141f72b9e9 The ID is: 83c75a51b3b8476b97c0a5141f72b9e9
  1. Deploy the monitor in a container
  • From NPM
    docker run -d --name container-monitor \
    -v /var/run/docker.sock:/var/run/docker.sock \
    -e NOTION_TOKEN=secret_abcdefghijklmnopqrstuvwxyz1234567890 \
    -e NOTION_PAGE_ID=page_id \
    node:18-alpine \
    npx simple-container-monitor
  • With Docker Compose, add the following service definition to your docker-compose.yml file:
    services:
      container-monitor:
        image: node:18-alpine
        container_name: container-monitor
        volumes:
          - /var/run/docker.sock:/var/run/docker.sock
        environment:
          NOTION_TOKEN: secret_abcdefghijklmnopqrstuvwxyz1234567890
          NOTION_PAGE_ID: page_id
        command: npx simple-container-monitor
        restart: unless-stopped
  • Or if you want to run the code directly from this repo to inspect the file before running
    Clone this repo or download the SimpleContainerMonitor.ts file, then run the following Docker command.
    docker run -d --name container-monitor \
    -v /var/run/docker.sock:/var/run/docker.sock \
    -v /absolute_path/to/SimpleContainerMonitor.ts:/app/SimpleContainerMonitor.ts \
    -e NOTION_TOKEN=secret_abcdefghijklmnopqrstuvwxyz1234567890 \
    -e NOTION_PAGE_ID=page_id \
    -w /app \
    node:18-alpine \
    npx tsx SimpleContainerMonitor.ts

Also runnable as a service outside Docker if Node 18+ is installed by setting the NOTION_TOKEN and NOTION_PAGE_ID environment variables end exectuing npx simple-container-monitor

Environment Variables

  • NOTION_TOKEN (required): The integration token from step 1
  • NOTION_PAGE_ID (required): ID of an existing page to update

Prerequisites

  • Node.js 18 or higher
  • Notion account

License

This project is licensed under the MIT License.