Docker Hub Badges
GitLab Badges
MicroBadger
Tag | Badge |
---|---|
latest |
|
latest-slim |
The CI is scheduled to check every hour to check npm
for the latest version of markdownlint-cli
and check Docker Hub for the latest version of the node
docker image.
The schedule: https://gitlab.com/06kellyjac/docker_markdownlint-cli/pipeline_schedules
More information on the polling: https://gitlab.com/06kellyjac/docker_markdownlint-cli/blob/polling/README.md
There is also Clair security scanning performed on this container; click the badge above or click here to view the result.
Images are available on both Docker Hub and GitLab: https://gitlab.com/06kellyjac/docker_markdownlint-cli/container_registry
Docker Hub can easily take over 2 hours+ to queue, build, and push all the containers. GitLab takes around 2-6 minutes to build and push all the containers in parallel (although it can take longer to queue at "prime time"). Due to this, Images on GitLab will likely be more up-to-date by a substantial margin.
Personally I also experience faster image downloads from GitLab but your networking situation may differ.
There is a marginal difference in download speed but for using this image in your GitLab CI pipelines on gitlab.com it makes sense to use the image from GitLab's own registry.
Additionally please note Docker Hub only allows for 25 automated build tags.
So only the last 7 versions can remain automatically building (3 tags per version & latest). The tags should remain in Docker Hub but they won't be rebuilt with the latest patches. All tags will continue to build with the latest patches on GitLab and go in the registry there.
latest-alpine
,latest
: (alpine/latest/Dockerfile)latest-slim
: (slim/latest/Dockerfile)0.29.0-alpine
,0.29.0
: (alpine/0.29.0/Dockerfile)0.29.0-slim
: (slim/0.29.0/Dockerfile)0.28.1-alpine
,0.28.1
: (alpine/0.28.1/Dockerfile)0.28.1-slim
: (slim/0.28.1/Dockerfile)0.28.0-alpine
,0.28.0
: (alpine/0.28.0/Dockerfile)0.28.0-slim
: (slim/0.28.0/Dockerfile)0.27.1-alpine
,0.27.1
: (alpine/0.27.1/Dockerfile)0.27.1-slim
: (slim/0.27.1/Dockerfile)0.27.0-alpine
,0.27.0
: (alpine/0.27.0/Dockerfile)0.27.0-slim
: (slim/0.27.0/Dockerfile)0.26.0-alpine
,0.26.0
: (alpine/0.26.0/Dockerfile)0.26.0-slim
: (slim/0.26.0/Dockerfile)0.25.0-alpine
,0.25.0
: (alpine/0.25.0/Dockerfile)0.25.0-slim
: (slim/0.25.0/Dockerfile)0.24.0-alpine
,0.24.0
: (alpine/0.24.0/Dockerfile)0.24.0-slim
: (slim/0.24.0/Dockerfile)0.23.2-alpine
,0.23.2
: (alpine/0.23.2/Dockerfile)0.23.2-slim
: (slim/0.23.2/Dockerfile)0.23.1-alpine
,0.23.1
: (alpine/0.23.1/Dockerfile)0.23.1-slim
: (slim/0.23.1/Dockerfile)0.23.0-alpine
,0.23.0
: (alpine/0.23.0/Dockerfile)0.23.0-slim
: (slim/0.23.0/Dockerfile)0.22.0-alpine
,0.22.0
: (alpine/0.22.0/Dockerfile)0.22.0-slim
: (slim/0.22.0/Dockerfile)0.21.0-alpine
,0.21.0
: (alpine/0.21.0/Dockerfile)0.21.0-slim
: (slim/0.21.0/Dockerfile)0.20.0-alpine
,0.20.0
: (alpine/0.20.0/Dockerfile)0.20.0-slim
: (slim/0.20.0/Dockerfile)0.19.0-alpine
,0.19.0
: (alpine/0.19.0/Dockerfile)0.19.0-slim
: (slim/0.19.0/Dockerfile)0.18.0-alpine
,0.18.0
: (alpine/0.18.0/Dockerfile)0.18.0-slim
: (slim/0.18.0/Dockerfile)0.17.0-alpine
,0.17.0
: (alpine/0.17.0/Dockerfile)0.17.0-slim
: (slim/0.17.0/Dockerfile)0.16.0-alpine
,0.16.0
: (alpine/0.16.0/Dockerfile)0.16.0-slim
: (slim/0.16.0/Dockerfile)0.15.0-alpine
,0.15.0
: (alpine/0.15.0/Dockerfile)0.15.0-slim
: (slim/0.15.0/Dockerfile)0.14.1-alpine
,0.14.1
: (alpine/0.14.1/Dockerfile)0.14.1-slim
: (slim/0.14.1/Dockerfile)0.14.0-alpine
,0.14.0
: (alpine/0.14.0/Dockerfile)0.14.0-slim
: (slim/0.14.0/Dockerfile)0.13.0-alpine
,0.13.0
: (alpine/0.13.0/Dockerfile)0.13.0-slim
: (slim/0.13.0/Dockerfile)0.12.0-alpine
,0.12.0
: (alpine/0.12.0/Dockerfile)0.12.0-slim
: (slim/0.12.0/Dockerfile)0.11.0-alpine
,0.11.0
: (alpine/0.11.0/Dockerfile)0.11.0-slim
: (slim/0.11.0/Dockerfile)0.10.0-alpine
,0.10.0
: (alpine/0.10.0/Dockerfile)0.10.0-slim
: (slim/0.10.0/Dockerfile)
A Dockerfile
is also visible on the Docker Hub page: https://hub.docker.com/r/06kellyjac/markdownlint-cli/~/dockerfile/
If you're using the image from the GitLab registry replace all instances of 06kellyjac/markdownlint-cli
with registry.gitlab.com/06kellyjac/docker_markdownlint-cli
.
Linting one file with STDIN:
docker run -i 06kellyjac/markdownlint-cli -s < README.md
This is an easy way to lint one file.
Linting multiple files with STDIN:
cat README.md a.md b.md c.md other.md | docker run -i 06kellyjac/markdownlint-cli -s -
This is a quick and dirty way to lint multiple files. The downside is it's difficult to tell which file has linting issues.
Linting one file with STDIN and a custom markdownlint
config
docker run -i -v $PWD/.markdownlint.json:/markdown/.markdownlint.json 06kellyjac/markdownlint-cli -s < README.md
This takes the first example and also mounts your .markdownlint.json
config into the container. You may find the below example to be cleaner if all the files you want to lint are in your present working directory.
Linting files by mounting the whole present working directory into the container.
docker run -v $PWD:/markdown 06kellyjac/markdownlint-cli README.md a.md b.md c.md other_dir/other.md
or
docker run -v $PWD:/markdown 06kellyjac/markdownlint-cli .
This method is useful for linting files in the present working directory and also means you can mount your .markdownlint.json
config at the same time.
With a directory structure like so, where this_directory
is your present working directory:
this_directory
├── .markdownlint.json
├── README.md
├── a.md
├── b.md
├── c.md
└── other_dir
└── other.md
GitLab CI Example:
my_markdownlint_job:
image:
name: 06kellyjac/markdownlint-cli:0.29.0-alpine
# or to use the image from GitLab rather than Docker Hub
# replace it with the line below
# name: registry.gitlab.com/06kellyjac/docker_markdownlint-cli:0.29.0-alpine
entrypoint:
- "/usr/bin/env"
- "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
before_script:
- markdownlint --version
script:
- markdownlint .
-
Where to get help: I have contact details on my GitLab, the Docker Community Forums, the Docker Community Slack, or Stack Overflow
-
Where to file issues: https://gitlab.com/06kellyjac/docker_markdownlint-cli/issues
-
Maintained by: 06kellyjac on GitLab
-
Source of this description: The GitLab README.md (history)
markdownlint-cli
is a command-line interface for the markdownlint
library.
Thanks go to DavidAnson and contributors on GitHub for the markdownlint
library, and to igorshubovych and contributors on GitHub for markdownlint-cli
.
The source used in this image:
https://github.com/DavidAnson/markdownlint/
https://github.com/igorshubovych/markdownlint-cli/
View markdownlint licence information and markdownlint-cli licence information for the software contained in this image.
View licence information for the container set-up.