Crates.io | cargo-docker |
lib.rs | cargo-docker |
version | 0.2.0 |
source | src |
created_at | 2016-09-30 16:27:29.266722 |
updated_at | 2017-04-25 18:12:23.32012 |
description | A cargo subcommand to build binary with other OS. |
homepage | |
repository | https://github.com/DenisKolodin/cargo-docker |
max_upload_size | |
id | 6664 |
size | 3,200 |
A cargo subcommand to build Rust code inside docker and get the result back.
It's useful to build binary with other environment. As example, you can build binary for CentOS
inside Ubuntu
.
To use cargo-docker
you should type the following:
$ cargo docker --image=rustup/debian:jessie --output=jessie-target
This command uses docker without sudo and you have to get rights to use docker.
Add docker
group:
$ sudo groupadd docker
$ sudo service docker restart
Not necessary if you have installed new version of docker.
Add yourself to docker
group:
$ sudo gpasswd -a ${USER} docker
Login again to update user flags.