Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding support for Podman #344

Merged
merged 5 commits into from
Nov 15, 2019
Merged

Adding support for Podman #344

merged 5 commits into from
Nov 15, 2019

Conversation

ostrosco
Copy link
Contributor

@ostrosco ostrosco commented Nov 9, 2019

  • Via the new container_engine parameter in Cross.toml, the user can now
    specify whether they want to use Podman or Docker.
  • Several changes to src/docker.rs to pass in different options based on whether
    docker or podman is being used. This also mandates the use of --userns host
    which does require bumping the minimum Docker version.
  • Updates to the code base based on rustfmt and clippy recommendations.

@ostrosco ostrosco requested review from Dylan-DPC-zz and a team as code owners November 9, 2019 03:43
@reitermarkus
Copy link
Member

Please move the style changes to a separate PR. It's really hard to review the actual changes with them mixed in.

- Via the new container_engine parameter in Cross.toml, the user can now
  specify whether they want to use Podman or Docker.
- Several changes to src/docker.rs to pass in different options based on whether
  docker or podman is being used. This also mandates the use of `--userns host`
  which does require bumping the minimum Docker version.
@ostrosco ostrosco changed the title Adding support for Podman and rustfmt/clippy fixes Adding support for Podman Nov 9, 2019
@ostrosco
Copy link
Contributor Author

ostrosco commented Nov 9, 2019

Sorry about that. I've reverted everything back save for the changes to add podman support.

src/docker.rs Outdated Show resolved Hide resolved
- In version 1.6.3 of Podman, support for anonymous volues was added
  which allows for Docker and Podman to both add /cargo/bin for MacOS
  compatibility. The Docker command was reverted to its original version
  and the minimum version of Podman is now set to 1.6.3.
- Minor updates to the README to indicate that Docker and Podman are both
  supported and one of the must be installed.
src/docker.rs Show resolved Hide resolved
src/docker.rs Outdated Show resolved Hide resolved
src/main.rs Outdated Show resolved Hide resolved
src/main.rs Outdated Show resolved Hide resolved
src/docker.rs Outdated Show resolved Hide resolved
- Instead of requiring the user to specify which container engine they
  would prefer via the container_engine option, cross will now check to see
  which one is installed and use it. Defaults to docker if both are installed.
src/docker.rs Outdated Show resolved Hide resolved
- Changing the get_container_engine() call to use Result<> instead
  of Option<> and using combinators rather than ifs.
- Added which::Error to the list of errors in the error_chain. This
  also required disabling the default features of which which uses
  failure by default rather than std::error::Error.
@reitermarkus
Copy link
Member

bors r+

bors bot added a commit that referenced this pull request Nov 15, 2019
344: Adding support for Podman r=reitermarkus a=ostrosco

- Via the new container_engine parameter in Cross.toml, the user can now
  specify whether they want to use Podman or Docker.
- Several changes to src/docker.rs to pass in different options based on whether
  docker or podman is being used. This also mandates the use of `--userns host`
  which does require bumping the minimum Docker version.
- Updates to the code base based on rustfmt and clippy recommendations.

Co-authored-by: ostrosco <[email protected]>
@bors
Copy link
Contributor

bors bot commented Nov 15, 2019

Build succeeded

  • rust-embedded.cross

@bors bors bot merged commit 243e21a into cross-rs:master Nov 15, 2019
@reitermarkus
Copy link
Member

Thanks, @ostrosco, great work!

@ostrosco
Copy link
Contributor Author

Thanks and you're welcome!

@ostrosco ostrosco deleted the feature/podman branch November 15, 2019 15:02
@Alexhuszagh Alexhuszagh added enhancement A-container-engine Area: container engines A-podman Area: podman container engine labels Nov 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-container-engine Area: container engines A-podman Area: podman container engine enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants