{"id":37135476,"url":"https://github.com/sbt-jib/sbt-jib","last_synced_at":"2026-01-14T15:47:53.930Z","repository":{"id":37852081,"uuid":"136899889","full_name":"sbt-jib/sbt-jib","owner":"sbt-jib","description":"sbt version of sbt jib: https://github.com/GoogleContainerTools/jib","archived":false,"fork":false,"pushed_at":"2025-08-07T14:02:37.000Z","size":193,"stargazers_count":153,"open_issues_count":10,"forks_count":29,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-10-10T22:07:14.129Z","etag":null,"topics":["docker","docker-builder","jib","sbt","scala"],"latest_commit_sha":null,"homepage":null,"language":"Scala","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sbt-jib.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2018-06-11T08:54:20.000Z","updated_at":"2025-09-09T08:41:10.000Z","dependencies_parsed_at":"2024-05-21T01:28:17.711Z","dependency_job_id":"26287a10-d9da-4b21-aa33-f2aa0aa4abbd","html_url":"https://github.com/sbt-jib/sbt-jib","commit_stats":null,"previous_names":["schmitch/sbt-jib"],"tags_count":46,"template":false,"template_full_name":null,"purl":"pkg:github/sbt-jib/sbt-jib","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbt-jib%2Fsbt-jib","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbt-jib%2Fsbt-jib/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbt-jib%2Fsbt-jib/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbt-jib%2Fsbt-jib/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sbt-jib","download_url":"https://codeload.github.com/sbt-jib/sbt-jib/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbt-jib%2Fsbt-jib/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28424902,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T15:24:48.085Z","status":"ssl_error","status_checked_at":"2026-01-14T15:23:41.940Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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","docker-builder","jib","sbt","scala"],"created_at":"2026-01-14T15:47:53.182Z","updated_at":"2026-01-14T15:47:53.915Z","avatar_url":"https://github.com/sbt-jib.png","language":"Scala","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sbt-jib\n\nThis project tries to make a sbt plugin for the awesome [jib](https://github.com/GoogleContainerTools/jib) project from google.\n\n\n## Usage\n\nAdd the following lines in `project/plugins.sbt`:\n\n```scala\naddSbtPlugin(\"de.gccc.sbt\" % \"sbt-jib\" % \"\u003csbt-jib-version\u003e\")\nlibraryDependencies += \"com.google.cloud.tools\" % \"jib-core\" % \"\u003cjib-core-version\u003e\"\n```\n\nYou can find the latest `jib-core` version [in their release list](https://github.com/GoogleContainerTools/jib/releases).\n\n| `sbt-jib` | `jib-core` |\n| :---: | :---: |\n| ![sbt-jib badge](https://maven-badges.herokuapp.com/maven-central/de.gccc.sbt/sbt-jib/badge.svg) | ![jib-core badge](https://maven-badges.herokuapp.com/maven-central/com.google.cloud.tools/jib-core/badge.svg) |\n\n\n## settings\n    \n| name                               | type                 | description                                                                                                                                    |\n|------------------------------------|----------------------|------------------------------------------------------------------------------------------------------------------------------------------------|\n| **jibTarget**                      | Option[File]         | jib work directory                                                                                                                             |\n| **jibBaseImage**                   | String               | jib base image                                                                                                                                 |\n| **jibBaseImageCredentialHelper**   | Option[String]]      | jib base image credential helper cli name (e.g. ecr-login)                                                                                     |\n| **jibJvmFlags**                    | List[String]]        | jib default jvm flags                                                                                                                          |\n| **jibArgs**                        | List[String]]        | jib default args                                                                                                                               |\n| **jibEntrypoint**                  | Option[List[String]] | jib entrypoint                                                                                                                                 |\n| **jibImageFormat**                 | JibImageFormat       | jib default image format                                                                                                                       |\n| **jibTargetImageCredentialHelper** | Option[String]       | jib target image credential helper cli name                                                                                                    |\n| **jibRegistry**                    | String               | jib target image registry (defaults to docker hub)                                                                                             |\n| **jibOrganization**                | String               | jib docker organization (defaults to organization)                                                                                             |\n| **jibName**                        | String               | jib image name (defaults to project name)                                                                                                      |\n| **jibVersion**                     | String               | jib version (defaults to version)                                                                                                              |\n| **jibEnvironment**                 | Map[String, String]  | jib docker env variables                                                                                                                       |\n| **jibPlatforms**                   | Set[Platform]        | jib platforms                                                                                                                                  |\n| **jibLabels**                      | Map[String, String]  | jib docker labels                                                                                                                              |\n| **jibTcpPorts**                    | List[Int]            | jib docker exposed tcp ports                                                                                                                   |\n| **jibUdpPorts**                    | List[Int]            | jib docker exposed udp ports                                                                                                                   |\n| **jibTags**                        | List[String]         | jib image tags (in addition to jibVersion)                                                                                                     |\n| **jibUser**                        | Option[String]       | jib user and group to run the container as                                                                                                     |\n| **jibMappings**                    | Seq[(File, String)]  | jib additional resource mappings, \u003cbr\u003eformatted as \\\u003csource file resource\\\u003e -\u003e \\\u003cfull path on container\\\u003e                                      |\n| **jibExtraMappings**               | Seq[(File, String)]  | jib extra file mappings / i.e. java agents \u003cbr\u003e(see above for formatting)                                                                      |\n| **jibJavaAddToClasspath**          | List[File]           | Adds other files to the class path when using jibJava*. Serves as replacement for `jibMappings` and `jibExtraMappings` which don't work there. |\n| **jibUseCurrentTimestamp**         | Boolean              | jib use current timestamp for image creation time. Default to Epoch                                                                            |\n| **jibCustomRepositoryPath**        | Option[String]       | jib custom repository path freeform path structure. \u003cbr\u003eThe default repo structure is organization/name                                        |\n\n## commands\n\n| name               | description |\n| ---                | --- |\n| **jibDockerBuild**     | jib build docker image |\n| **jibImageBuild**      | jib build image (does not need docker) |\n| **jibTarImageBuild**   | jib build tar image |\n| **jibJavaDockerBuild**   | jib build docker image, uses JavaContainerBuilder from jib-core |\n| **jibJavaImageBuild**    | jib build image (does not need docker), uses JavaContainerBuilder from jib-core |\n| **jibJavaTarImageBuild** | jib build tar image, uses JavaContainerBuilder from jib-core |\n\n## credentials\n\nThere are a couple of ways to supply credentials to the image pull and push operations done by jib. The following sources are tested in order:\n\n1. Environment variables: `JIB_BASE_IMAGE_USERNAME` + `JIB_BASE_IMAGE_PASSWORD` for pulling the base image, `JIB_TARGET_IMAGE_USERNAME` + `JIB_TARGET_IMAGE_PASSWORD` for pushing the target image\n2. SBT credentials: The plugin looks for a `credentials` entry that matches the host of the image registry\n3. The `$HOME/.docker/config.json` for credentials and credential helpers\n4. A set of [well known credential helpers](https://github.com/GoogleContainerTools/jib/blob/v0.18.0-core/jib-core/src/main/java/com/google/cloud/tools/jib/frontend/CredentialRetrieverFactory.java#L69)\n5. The credential helpers supplied by `jibBaseImageCredentialHelper` or `jibTargetImageCredentialHelper`\n\n## snippets and examples\n\n### injecting java agents\n\nThis snippet shows how to inject a Java Agent (Kanela) into a container via jibExtraMappings.\n\nbuild.sbt\n```scala\n//...project stuff...\njavaAgents += \"io.kamon\" % \"kanela-agent\" % \"1.0.5\" % \"dist;runtime;compile\"\n//...project stuff...\njibBaseImage := \"openjdk:11-jre\"\njibName := \"my-service\"\njibRegistry := \"some-ecr-repository\"\njibUseCurrentTimestamp := true\njibCustomRepositoryPath := Some(jibName.value)\njibJvmFlags := List(\"-javaagent:/root/lib/kanela-agent.jar\")\njibExtraMappings := {\n    //javaAgents, Modules and ResolvedAgent come from the sbt-javaagent plugin\n    val resolved = javaAgents.value.map { agent =\u003e\n        update.value.matching(Modules.exactFilter(agent.module)).headOption map {\n            jar =\u003e ResolvedAgent(agent, jar)\n        }\n    }\n    for {\n        resolvedAgent \u003c- resolved.flatten\n    } yield {\n        resolvedAgent.artifact -\u003e s\"/root/lib/${resolvedAgent.agent.name}.jar\"\n    }\n}\njibTargetImageCredentialHelper := Some(\"ecr-login\") \njibBaseImageCredentialHelper := Some(\"ecr-login\")\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsbt-jib%2Fsbt-jib","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsbt-jib%2Fsbt-jib","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsbt-jib%2Fsbt-jib/lists"}