{"id":7686309,"name":"dacbd/docker-artifacts","ecosystem":"actions","description":"A simple docker build sequence with help and robust defaults","homepage":null,"licenses":"mit","normalized_licenses":["MIT"],"repository_url":"https://github.com/dacbd/docker-artifacts","keywords_array":[],"namespace":"dacbd","versions_count":0,"first_release_published_at":null,"latest_release_published_at":"2026-03-10T19:04:26.895Z","latest_release_number":null,"last_synced_at":"2026-03-10T19:04:27.310Z","created_at":"2023-05-05T01:52:40.361Z","updated_at":"2026-03-10T19:04:27.311Z","registry_url":"https://github.com/dacbd/docker-artifacts","install_command":null,"documentation_url":null,"metadata":{"name":"docker-artifacts","description":"A simple docker build sequence with help and robust defaults","author":"Daniel Barnes","branding":{"icon":null,"color":null},"outputs":null,"inputs":{"tags":{"description":"Tags for the docker build, defaults to latest, always tags with commit hash that triggered the job","required":false,"default":"latest"},"container-name":{"description":"A custom name for the container image, implied from the git repo name if not present","required":false},"registry-prefix":{"description":"A registry prefix for container image naming ie (docker hub username) or (gcr.io/project_id) if you intend to push a docker login step should be done first","required":false},"docker-context":{"description":"Docker build context (likely/default git repo root ie: ./ )","required":false,"default":"./"},"docker-file":{"description":"Given the context, the Dockerfile to build","required":false,"default":"Dockerfile"},"docker-push":{"description":"Push to a docker registry (default false) determined via: \u003cregistry-prefix\u003e/\u003ccontainer-name\u003e:\u003ctags\u003e","required":false,"default":false},"docker-cache-from":{"description":"Override the default docker build cache (GitHub Actions cache)","required":false,"default":"type=gha"},"docker-cache-to":{"description":"Override the default docker build cache (GitHub Actions cache)","required":false,"default":"type=gha,mode=max"},"artifact-name":{"description":"The name for the uploaded docker artifact. If not provided the container-name is the implied value","required":false},"artifact-retention":{"description":"The number of days for Github to store the uploaded docker image","required":false,"default":1}},"runs":{"using":"composite","steps":[{"name":"Checkout repo","uses":"actions/checkout@v2","with":{"fetch-depth":0}},{"name":"Determine container name","id":"container-name","shell":"bash","run":"echo \"::set-output name=name::${{ inputs.container-name || '$(basename $(git rev-parse --show-toplevel))' }}\""},{"name":"Create full docker image name","id":"image-name","shell":"bash","run":"if [ -z \"${{ inputs.registry-prefix }}\" ]; then\n  echo \"::set-output name=name::${{ steps.container-name.outputs.name }}\"\nelse\n  echo \"::set-output name=name::${{ inputs.registry-prefix }}/${{ steps.container-name.outputs.name }}\"\nfi\n"},{"name":"Populate image ref","id":"image-commit-ref","shell":"bash","run":"echo \"::set-output name=name::${{ steps.image-name.outputs.name }}:${{ github.sha }}\""},{"name":"Build \u003cimage-name:tag\u003e csv","id":"tag-csv","uses":"actions/github-script@v5","env":{"IMAGE_URI":"${{ steps.image-name.outputs.name }}"},"with":{"result-encoding":"string","script":"var tags = function(str) {\n  const arr = str.split( ',' );\n  for (let i = 0; i \u003c arr.length; i++) {\n    arr[i] = arr[i].trim();\n  }\n  return arr;\n}( '${{ inputs.tags }}' )\ntags.push(context.sha)\ntags = tags.map((tag) =\u003e {\n  return process.env['IMAGE_URI'] + ':' + tag\n})\nvar tagsStr = tags.join(',')\nreturn tagsStr\n"}},{"name":"Setup docker buildx","uses":"docker/setup-buildx-action@v1"},{"name":"Docker build","uses":"docker/build-push-action@v2","with":{"context":"${{ inputs.docker-context }}","file":"${{ inputs.docker-file }}","push":"${{ inputs.docker-push }}","tags":"${{ steps.tag-csv.outputs.result }}","cache-from":"${{ inputs.docker-cache-from }}","cache-to":"${{ inputs.docker-cache-to }}","outputs":"type=docker,dest=/tmp/${{ steps.container-name.outputs.name }}.tar"}},{"name":"Upload docker Artifact","uses":"actions/upload-artifacts@v2","with":{"name":"${{ inputs.artifact-name || steps.container-name.outputs.name }}","path":"/tmp/${{ steps.container-name.outputs.name }}.tar","retention-days":"${{ inputs.artifact-retention }}"}}]},"default_branch":"main","path":null},"repo_metadata":{"uuid":"433991308","full_name":"dacbd/docker-artifacts","owner":"dacbd","description":null,"archived":false,"fork":false,"pushed_at":"2021-12-01T21:32:56.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2023-07-13T08:38:23.887Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dacbd.png","metadata":{},"created_at":"2021-12-01T21:30:19.000Z","updated_at":"2021-12-01T21:32:58.000Z","dependencies_parsed_at":"2023-05-02T08:30:26.867Z","dependency_job_id":null,"html_url":"https://github.com/dacbd/docker-artifacts","commit_stats":null,"previous_names":[],"tags_count":0,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dacbd%2Fdocker-artifacts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dacbd%2Fdocker-artifacts/tags","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dacbd%2Fdocker-artifacts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dacbd","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":145722141,"owners_count":6280668,"icon_url":"https://github.com/github.png","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"},"owner_record":{"login":"dacbd","name":"Daniel Barnes","uuid":"1105843","kind":"user","description":"","email":"","website":null,"location":"Seattle","twitter":null,"company":"@iterative ","icon_url":"https://avatars.githubusercontent.com/u/1105843?v=4","repositories_count":30,"last_synced_at":"2023-03-14T08:25:13.468Z","metadata":{"has_sponsors_listing":false},"html_url":"https://github.com/dacbd","created_at":"2022-11-03T06:01:50.114Z","updated_at":"2023-03-14T08:25:13.472Z","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dacbd","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dacbd/repositories"},"tags":[]},"repo_metadata_updated_at":"2023-07-14T10:05:59.577Z","dependent_packages_count":0,"downloads":null,"downloads_period":null,"dependent_repos_count":0,"rankings":{"downloads":null,"dependent_repos_count":40.47609473641883,"dependent_packages_count":0.0,"stargazers_count":48.06787566850296,"forks_count":36.23788652539306,"average":31.19546423257871},"purl":"pkg:githubactions/dacbd/docker-artifacts","advisories":[],"docker_usage_url":"https://docker.ecosyste.ms/usage/actions/dacbd/docker-artifacts","docker_dependents_count":null,"docker_downloads_count":null,"usage_url":"https://repos.ecosyste.ms/usage/actions/dacbd/docker-artifacts","dependent_repositories_url":"https://repos.ecosyste.ms/api/v1/usage/actions/dacbd/docker-artifacts/dependencies","status":null,"funding_links":[],"critical":null,"issue_metadata":{"last_synced_at":"2023-08-09T10:49:10.311Z","issues_count":0,"pull_requests_count":0,"avg_time_to_close_issue":null,"avg_time_to_close_pull_request":null,"issues_closed_count":0,"pull_requests_closed_count":0,"pull_request_authors_count":0,"issue_authors_count":0,"avg_comments_per_issue":null,"avg_comments_per_pull_request":null,"merged_pull_requests_count":0,"bot_issues_count":0,"bot_pull_requests_count":0,"past_year_issues_count":0,"past_year_pull_requests_count":0,"past_year_avg_time_to_close_issue":null,"past_year_avg_time_to_close_pull_request":null,"past_year_issues_closed_count":0,"past_year_pull_requests_closed_count":0,"past_year_pull_request_authors_count":0,"past_year_issue_authors_count":0,"past_year_avg_comments_per_issue":null,"past_year_avg_comments_per_pull_request":null,"past_year_bot_issues_count":0,"past_year_bot_pull_requests_count":0,"past_year_merged_pull_requests_count":0},"versions_url":"https://packages.ecosyste.ms/api/v1/registries/github%20actions/packages/dacbd%2Fdocker-artifacts/versions","version_numbers_url":"https://packages.ecosyste.ms/api/v1/registries/github%20actions/packages/dacbd%2Fdocker-artifacts/version_numbers","dependent_packages_url":"https://packages.ecosyste.ms/api/v1/registries/github%20actions/packages/dacbd%2Fdocker-artifacts/dependent_packages","related_packages_url":"https://packages.ecosyste.ms/api/v1/registries/github%20actions/packages/dacbd%2Fdocker-artifacts/related_packages","codemeta_url":"https://packages.ecosyste.ms/api/v1/registries/github%20actions/packages/dacbd%2Fdocker-artifacts/codemeta","maintainers":[]}