A rocker wrapper for launching and attaching vscode to a rocker container
Project description
rockervsc
Continuous Integration Status
Intro
Rocker is an alternative to docker-compose that makes it easier to run containers with access to features of the local environment and add extra capabilities to existing docker images. I do most of my development in vscode with the devcontainers extension so this wrapper simplifies that workflow. Rather than calling rocker and then attaching vscode, this wrapper combines those actions into one command.
Installation
pip install rockervsc
Usage
To run rocker and automatically launch and attach a vscode instance, run this command:
rockervsc
You can pass all the normal rocker arguments to rockervsc and it will forward them to rocker, e.g.:
rockervsc --x11 --nvidia
by default rockervsc calls rockerc so instead of passing arguments explicitly you can have a rockerc.yaml file in your workspace
image: ubuntu:22.04
args:
- nvidia
- x11
- user
- git
and running:
rockervsc
will launch and attach vscode to the container with nvidia, x11, the current user id and git set up for you.
Caveats
I'm not sure this is the best way of implementing rockervsc like functionality. It might be better to implement it as a rocker extension, or in rocker itself. This was just the simplest way to get started. I may explore those other options in more detail in the future.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file rockervsc-0.3.0.tar.gz
.
File metadata
- Download URL: rockervsc-0.3.0.tar.gz
- Upload date:
- Size: 6.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ee6f798ba956e3171e86a401b003d8f646355319ecb05ef3ed3af6716379d0f3 |
|
MD5 | 875280071a8616b4c3c27c4fa34e17ca |
|
BLAKE2b-256 | d8133a978b476bfe2ce87128e142173dbe76b8993bfd87e514e0006659cfed95 |
File details
Details for the file rockervsc-0.3.0-py2.py3-none-any.whl
.
File metadata
- Download URL: rockervsc-0.3.0-py2.py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 63fed440956b1cdad4845934367513cc59bcbf0cdf46ba54f57678b253d39d23 |
|
MD5 | 61c8ebc70c43621d1491ff82493d29f6 |
|
BLAKE2b-256 | ea824a194c0478ac485c5720c64b0f202db3e8f6d107b022e62fa5077ca25e88 |