{"id":19368461,"url":"https://github.com/anchore/test-images","last_synced_at":"2026-07-09T08:30:21.229Z","repository":{"id":39602248,"uuid":"300731537","full_name":"anchore/test-images","owner":"anchore","description":"Container automation for testing and validation","archived":false,"fork":false,"pushed_at":"2024-09-19T15:11:45.000Z","size":6645,"stargazers_count":3,"open_issues_count":1,"forks_count":2,"subscribers_count":16,"default_branch":"main","last_synced_at":"2025-01-06T22:35:31.000Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Dockerfile","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/anchore.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"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}},"created_at":"2020-10-02T20:41:45.000Z","updated_at":"2024-10-03T05:15:03.000Z","dependencies_parsed_at":"2024-04-17T09:30:39.175Z","dependency_job_id":"60afe9ab-1b03-4aa6-8849-92a1d3eac310","html_url":"https://github.com/anchore/test-images","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anchore%2Ftest-images","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anchore%2Ftest-images/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anchore%2Ftest-images/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anchore%2Ftest-images/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/anchore","download_url":"https://codeload.github.com/anchore/test-images/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240491823,"owners_count":19809977,"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":[],"created_at":"2024-11-10T08:06:29.550Z","updated_at":"2026-07-09T08:30:21.183Z","avatar_url":"https://github.com/anchore.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# test-images\nThis repository holds files like `Dockerfile` with some automation to build container images used for testing.\n\n\n## Development\n\nIf you need to create a new container for testing, create a new directory with a Dockerfile and symlink the `ContainerMakefile` into it. In this example\nwe create a `new` directory which will hold the contents for a new container image:\n\n```text\n$ mkdir containers/new\n$ cd containers/new\n$ ln -s ../../ContainerMakefile Makefile\n```\n\nAfter creating the new directory and symlinking the `ContainerMakefile` the automation will be able to make it part of its workflow to make it available on `anchore/test_images`.\n\nNext, add a `Dockerfile` and make sure it passes the `build` and `lint` targets:\n\n```\n$ make lint\nLinting container image anchore/test_image:new\ndocker run --rm -i hadolint/hadolint \u003c Dockerfile\n/dev/stdin:1 DL3006 Always tag the version of an image explicitly\nmake: *** [lint] Error 1\n```\n\nSince the tagging is done by the automation, add the following line at the top of the container:\n\n```\n# hadolint ignore=DL3006\n```\n\nThat should allow the linting to pass. Create a pull request, which will also build and lint the container as part of the verification process.\n\nAfter your container merges to the `main` branch, it will be pushed to `anchore/test_images`. Following the example in this section, it will tag it with the name\nof the directory, which in this case is `new`. The end result will create the following container: `anchore/test_images:new`.\n\n\n### Optional setups when building\nThere are some situations where the default `ContainerMakefile` is insufficient to create an image along with `Dockerfile`. This is the case of the Java image, where\nthere is a need to run some ephemeral containers to create a java artifact. In such cases, there is support for a `setup.sh` script that needs to be defined in the target. If\nthis file exists, the `Makefile` will execute it as part of the `build` target. \n\nNote: make sure the file is executable\n\n\n## make targets\nA couple of other `make` commands are available for the symlinked `Makefile`, they are documented as part of the `make help` output.\n\n* `make build`: builds the current container locally, tags it with the current directory name\n* `make clean`: Removes the container image associated with the directory. If the directory name is `new`, then it will try to remove `anchore/test_images:new`\n* `make lint`: Runs the `hadolint/hadolint` container passing the contents of the `Dockerfile` to stdin, this step is run as a verification when a PR is opened\n\nIn addition to defined targets, the `Makefile` supports dynamic targets by looking into the `containers/` directory. Every sub-directory in that path becomes an available target to build it locally. For example, `containers/py38` is exposed and available with the following command:\n\n```\n$ make py38\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanchore%2Ftest-images","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fanchore%2Ftest-images","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanchore%2Ftest-images/lists"}