Skip to content

tmknom/dockerfiles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

599 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dockerfiles

A collection of Dockerfiles.

Description

This is a collection of dockerfiles that keep clean code.

Available dockerfiles are supported the following tools:

  • prettier: It's an opinionated code formatter, see the documents.
  • yamllint: It's a linter for YAML files, see the documents.
  • markdownlint: It's a style checker and lint tool for Markdown files, see the documents.

These are useful tools, but there is no official image. Therefore, this repository creates and distributes these lightweight images.

Usage

Pull

You can pull from Docker Hub or GitHub Packages, whichever you prefer. Using prettier as an example, pull as the following commands.

Docker Hub:

docker pull tmknom/prettier

GitHub Packages:

docker pull ghcr.io/tmknom/dockerfiles/prettier

The following shows how to use it when pulled from Docker Hub.

prettier

docker run --rm -v "$(pwd):/work" tmknom/prettier --check --parser=markdown README.md

For more information, see prettier/README.md.

yamllint

docker run --rm -v "$(pwd):/work" tmknom/yamllint -- .

For more information, see yamllint/README.md.

markdownlint

docker run --rm -v "$(pwd):/work" tmknom/markdownlint -- .

For more information, see markdownlint/README.md.

Supported platforms

  • linux/amd64
  • linux/arm64

Developer Guide

Click to see details

Requirements

Development

Creating a new Dockerfile

  1. Create <image_name>/ directory
  2. Define docker image: Dockerfile, entrypoint.sh, .dockerignore
  3. Manage package file: package.json or requirements.txt

Management for releasing and updating dependencies

  1. Create release action: .github/workflows/release-<image_name>.yml
  2. Configure version updates for dependencies: .github/dependabot.yml

Documentation for users

  1. Write details for the new docker image: <image_name>/README.md
  2. Update description and append usage: README.md

Release management

  1. Update Dockerfile or package management file
  2. Commit, push, and create a pull request
  3. After merged, run Workflows with release- prefix automatically at GitHub Actions

Then, publishes Docker images to Docker Hub and GitHub Packages. 🚀

Dependency management

Use Dependabot version updates. For more information, see dependabot.yml.

Secrets management

Stored following secrets in Repository Secrets.

  • DOCKERHUB_TOKEN: Personal access token used to log against Docker Hub.

About

A collection of Dockerfiles.

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors