Giter VIP home page Giter VIP logo

rust-vmm-container's Introduction

rust-vmm-container

rustvmm/dev is a container with all dependencies used for running rust-vmm integration tests.

The container is available on Docker Hub and has support for x86_64 and aarch64 platforms.

docker pull rustvmm/dev:v3

For the latest available tag, please check the rustvmm/dev builds available on Docker Hub.

Depending on which platform you're running the command from, docker will pull either rustvmm/dev:v3_aarch64 or rustvmm/dev:v3_x86_64.

For now rust is installed only for the root user.

Using the Container

The container is currently used for running the integration tests for the kvm-ioctls crate.

Example of running cargo build on the kvm-ioctls crate:

> git clone [email protected]:rust-vmm/kvm-ioctls.git
> cd kvm-ioctls/
> docker run --volume $(pwd):/kvm-ioctls \
         rustvmm/dev:v3 \
         /bin/bash -c "cd /kvm-ioctls && cargo build --release"
 Downloading crates ...
  Downloaded libc v0.2.48
  Downloaded kvm-bindings v0.1.1
   Compiling libc v0.2.48
   Compiling kvm-bindings v0.1.1
   Compiling kvm-ioctls v0.0.1 (/kvm-ioctls)
    Finished release [optimized] target(s) in 5.63s

Available Tools

The container currently has the Rust toolchain version 1.35.0 and Python3.6.

Python packages:

Cargo plugins:

Rust targets on x86_64:

  • x86_64-unknown-linux-gnu
  • x86_64-unknown-linux-musl

Rust targets on aarch64:

  • aarch64-unknown-linux-gnu
  • aarch64-unknown-linux-musl

Publishing a New Version

On an aarch64 platform:

> cd rust-vmm-dev-container
> # Build a container image for aarch64
> docker build -t rustvmm/dev:aarch64 -f Dockerfile .
> docker images
REPOSITORY             TAG                 IMAGE ID            CREATED             SIZE
rustvmm/dev            aarch64             f3fd02dfb213        21 hours ago        1.13GB
ubuntu                 18.04               0926e73e5245        3 weeks ago         80.4MB
>
> docker tag f3fd02dfb213 rustvmm/dev:v4_aarch64
> docker push rustvmm/dev:v4_aarch64

You will need to redo all steps on a x86_64 platform so the containers are kept in sync (same package versions on both x86_64 and aarch64).

> docker build -t rustvmm/dev:v4_x86_64 -f Dockerfile .
> docker tag XXXXXXXX rustvmm/dev:v4_x86_64
> docker push rustvmm/dev:v4_x86_64

Now that the tags v4_x86_64 and v4_aarch64 are pushed to Docker Hub, we can go ahead and also create a new version tag that points to these two builds using docker manifest.

docker manifest create \
        rustvmm/dev:v4 \
        rustvmm/dev:v4_x86_64 \
        rustvmm/dev:v4_aarch64
docker manifest push rustvmm/dev:v4

If it is the first time you are creating a docker manifest, most likely it will fail with: docker manifest is only supported when experimental cli features are enabled. Checkout this article to understand why and how to fix it.

rust-vmm-container's People

Contributors

andreeaflorescu avatar gliptak avatar jiangliu avatar mrxinwang avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.