Sign inSign up

uavcan/toxic

By uavcan

•Updated over 5 years ago

Ubuntu 18.04 (bionic) environment for python testing using tox.

Image
0

1.1K

uavcan/toxic repository overview

⁠Toxic Docker

Builds and pushes a docker environment for use with tox testing. This environment contains a series of python versions allowing multi-version tox testing locally and in CI services.

The "sq" suffix indicates that the "sonarqube"⁠ scanner has been included in the image. This scanner allows tox builds to upload coverage and other reports to a sonarqube instance.

⁠Build and Push

These instructions are for maintainers with permissions to push to the "uavcan" organization on Docker Hub.

docker build .
docker images

REPOSITORY      TAG            IMAGE ID
toxic           latest         d7ab132649d6
# We use the range of python environments supported as the version tag.
docker tag d7ab132649d6 uavcan/toxic:py35-py38-sq
docker login --username=yourhubusername
docker push uavcan/toxic:py35-py38-sq

⁠Testing out the container

Start an interactive session:

docker run --rm -it -v ${PWD}:/repo uavcan/toxic:py35-py38-sq

On macintosh you'll probably want to optimize osxfs with something like cached or delegated:

docker run --rm -it -v ${PWD}:/repo:delegated uavcan/toxic:py35-py38-sq

See "Performance tuning for volume mounts"⁠ for details.

⁠Travis CI

You can use this in your .travis.yml like this:

services:
  - docker

before_install:
- docker pull uavcan/toxic:py35-py38-sq

script:
- docker run --rm -v $TRAVIS_BUILD_DIR:/repo uavcan/uavcan/toxic:py35-py38-sq /bin/sh -c tox

⁠BuildKite

Example pipeline.yml:

- label: ":github: my containerized build"
    command: "tox"
    plugins:
      - docker#v3.5.0:
          workdir: /repo
          image: "uavcan/toxic:py35-py38-sq"
          propagate-environment: true
          mount-ssh-agent: true

Tag summary

Content type

Image

Digest

Size

291.7 MB

Last updated

over 5 years ago

docker pull uavcan/toxic:py35-py39-sq