{"id":18310900,"url":"https://github.com/jimschubert/docked","last_synced_at":"2026-02-13T04:22:30.937Z","repository":{"id":57627717,"uuid":"378480980","full_name":"jimschubert/docked","owner":"jimschubert","description":"A Dockerfile linting tool","archived":false,"fork":false,"pushed_at":"2024-03-21T22:12:14.000Z","size":1134,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-21T08:35:00.539Z","etag":null,"topics":["docker","go","golang","linter","linting"],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/jimschubert/docked","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jimschubert.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"jimschubert","patreon":"jimschubert"}},"created_at":"2021-06-19T18:35:10.000Z","updated_at":"2023-10-14T21:03:21.000Z","dependencies_parsed_at":"2024-06-20T01:46:27.827Z","dependency_job_id":"c61ebce9-d268-4f73-b7f3-efe82fc32057","html_url":"https://github.com/jimschubert/docked","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":"jimschubert/go-cli-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jimschubert%2Fdocked","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jimschubert%2Fdocked/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jimschubert%2Fdocked/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jimschubert%2Fdocked/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jimschubert","download_url":"https://codeload.github.com/jimschubert/docked/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247383885,"owners_count":20930365,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","go","golang","linter","linting"],"created_at":"2024-11-05T16:15:49.079Z","updated_at":"2026-02-13T04:22:30.851Z","avatar_url":"https://github.com/jimschubert.png","language":"Go","funding_links":["https://github.com/sponsors/jimschubert","https://patreon.com/jimschubert"],"categories":[],"sub_categories":[],"readme":"# docked\n\nA Dockerfile linting tool which aims to pull many best practices and recommendations from multiple sources:\n\n* OWASP\n* Docker Official Documentation\n* Community recommendations\n* Package manager bug trackers\n\nCheck out the currently supported [rules](./RULES.md).\n\n[![Apache 2.0 License](https://img.shields.io/badge/License-Apache%202.0-blue)](./LICENSE)\n![Go Version](https://img.shields.io/github/go-mod/go-version/jimschubert/docked)\n[![Go Build](https://github.com/jimschubert/docked/actions/workflows/build.yml/badge.svg)](https://github.com/jimschubert/docked/actions/workflows/build.yml)\n![Docker Image Size (latest semver)](https://img.shields.io/docker/image-size/jimschubert/docked?color=orange\u0026label=Docker%20Image%20Size)\n[![Go Report Card](https://goreportcard.com/badge/github.com/jimschubert/docked)](https://goreportcard.com/report/github.com/jimschubert/docked)\n\u003c!-- [![codecov](https://codecov.io/gh/jimschubert/docked/branch/master/graph/badge.svg)](https://codecov.io/gh/jimschubert/docked) --\u003e \n\n## tldr;\n\n```\ndocked analyze ./Dockerfile\n```\n\nSuccessful Outputs:\n![](./.github/screens/output.png)\n\nFailure Outputs:\n![](./.github/screens/output-failures.png)\n\nAnd, it's customizable. You can ignore, re-prioritize, or add custom rules via regex. There's also JSON and [HTML](https://htmlpreview.github.io/?https://raw.githubusercontent.com/jimschubert/docked/master/.github/examples/html/index.html) outputs.\n\n## Install\n\n### Binaries\n\nLatest binary releases are available via [GitHub Releases](https://github.com/jimschubert/docked/releases).\n\n### Homebrew\n\n```\nbrew install jimschubert/tap/docked\n```\n\n### Docker\n\n```\ndocker pull jimschubert/docked:latest\n```\n\nWhen running the docker image, be sure to mount and reference the sources appropriately. For example:\n\n### Completions\n\nAfter you've installed the binary either manually or via Homebrew, consider enabling completions for your shell. \n\nFor instructions, view help for your target shell.\n\n#### zsh\n\n```\ndocked completion zsh --help\n```\n\n#### bash\n\n```\ndocked completion bash --help\n```\n\n#### fish\n\n```\ndocked completion fish --help\n```\n\n#### powershell\n\n```\ndocked completion powershell --help\n```\n\n## Usage\n\n```shell\n$ docked analyze --help\n\nAnalyze a Dockerfile for issues\nIf not provided, FILE defaults to ./Dockerfile\n\nUsage:\n  docked analyze [FILE] [flags]\n\nFlags:\n  -h, --help                   help for analyze\n  -i, --ignore strings         The lint ids to ignore\n  -k, --no-buildkit-warnings   Whether to suppress Docker parser warnings\n      --regex-engine string    The regex engine to use (regexp, regexp2) (default \"regexp2\")\n      --report-type string     The type of reporting output (text, json, html) (default \"text\")\n\nGlobal Flags:\n      --config string   config file (default is $HOME/.docked.yaml)\n      --viper           use Viper for configuration (default true)\n```\n\nThings to consider:\n\n* Buildkit warnings should be disabled when piping output (for example when using `--report-type json`), but this is _not forced_\n* The `regexp2` engine is default because it supports full regular expression syntax. Compare differences in [regexp2's README](https://github.com/dlclark/regexp2#compare-regexp-and-regexp2). Note that `regexp2` patterns are not run in compatibility mode in docked, although that might change later.\n* `viper` configuration is work-in-progress. Feel free to contribute.\n\n## Configuration\n\nThe optional configuration file follows this example syntax:\n\n```\nignore:\n  - D7:tagged-latest\nrule_overrides:\n  'D5:secret-aws-access-key': low\ncustom_rules:\n  - name: custom-name\n    summary: Your custom summary\n    details: Your additional rule details\n    pattern: '.' # some regex pattern\n    priority: critical\n    command: add\n```\n\n## Build\n\nBuild a local distribution for evaluation using goreleaser (easiest).\n\n```bash\ngoreleaser release --skip-publish --snapshot --rm-dist\n```\n\nThis will create an executable application for your os/architecture under `dist`:\n\n```\ndist\n├── docked_darwin_amd64\n│   └── docked\n├── docked_linux_386\n│   └── docked\n├── docked_linux_amd64\n│   └── docked\n├── docked_linux_arm64\n│   └── docked\n├── docked_linux_arm_6\n│   └── docked\n└── docked_windows_amd64\n    └── docked.exe\n```\n\nBuild and execute locally using go:\n\n* Get dependencies\n\n```shell\ngo get -d ./...\n```\n\n* Build\n\n```shell\ngo build -o docked ./cmd/docked/\n```\n\n* Run\n\n```shell\n./docked --help\n```\n\n## License\n\nThis project is [licensed](./LICENSE) under Apache 2.0.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjimschubert%2Fdocked","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjimschubert%2Fdocked","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjimschubert%2Fdocked/lists"}