Crates.io | cargo-docker-build |
lib.rs | cargo-docker-build |
version | 0.1.2 |
source | src |
created_at | 2023-02-19 22:56:29.289552 |
updated_at | 2023-02-22 19:32:49.318114 |
description | Build Dockerfile and script from Cargo.toml for a Rust workspace project |
homepage | |
repository | https://github.com/ovidiu-ionescu/docker-build |
max_upload_size | |
id | 789363 |
size | 51,835 |
Helps building the executables in a Rust workspace and deploy them inside minikube
It generates two files:
When ran from the root of a workspace project, the program will read the Cargo.toml
files from every subproject and create a multi stage Dockerfile
, that can compile the
sources and produce the images.
The ones with the name starting with lib
will be ignored.
If the project is not a workspace, it will only generate for the current project.
The images will have labels with information extracted from Cargo.toml
A shell file build_docker.sh
will be generated.
When run, it will invoke the Dockerfile creation
and will tag the newly created images using the labels in the images.
The program will only do the file generation, it will not run anything so
you need to run the build_docker.sh
manually.
This program is meant to run as a Cargo subcommand. To install it from source, run:
git clone git@github.com:ovidiu-ionescu/docker-build.git
cd docker-build
cargo install --path .