OneBusAway / onebusaway-gtfs-modules

A Java-based library for reading, writing, and transforming public transit data in the GTFS format, including database support.
Other
129 stars 105 forks source link

Build container images via jib-maven-plugin #301

Closed hbruch closed 1 week ago

hbruch commented 1 week ago

Summary:

This PR adds jib-maven-plugin as build dependency which allows to build and publish onebusaway gtfs tools as docker images.

Note: currently, image names are build using their maven artifactId as repository names. To build and publish them, an env variable CONTAINER_REGISTRY_NAMESPACE needs to be defined.

To build use e.g. CONTAINER_REGISTRY_NAMESPACE=mfdz mvn jib:dockerBuild, or, to build and publish to the registry CONTAINER_REGISTRY_NAMESPACE=mfdz mvn jib:build

It will build the following images (assuming current version is 4.0.1-SNAPSHOT):

mfdz/onebusaway-gtfs-merge-cli:4.0.1-SNAPSHOT mfdz/onebusaway-gtfs-hibernate-cli:4.0.1-SNAPSHOT mfdz/onebusaway-gtfs-transformer-cli:4.0.1-SNAPSHOT

According to jib-maven-plugin multi-module example, module-dependencies are built as reproducible builds.

leonardehrenfried commented 1 week ago

Thanks for this PR. I will merge this and tweak the settings a bit myself.

leonardehrenfried commented 1 week ago

Sorry, I don't have the permissions to publish to Github Container Registry or Dockerhub. I will have to ask so it will take a little longer.

leonardehrenfried commented 1 week ago

https://hub.docker.com/r/opentransitsoftwarefoundation/onebusaway-gtfs-merge-cli/tags

Can you try if the images work?