Git Product home page Git Product logo

pyrex's Introduction

Pyrex

Containerize your bitbake

Build Status Coverage Status

Requirements

Pyrex has the following system requirements:

  • docker or podman
  • python 3.6 or later

NOTE: Pyrex will not function properly if docker is installed as snap since it bind mounts files that the snap is not allowed to access. Please install a non-snap version of docker, e.g. apt install docker.io

Quickstart Guide (default layout)

Use this quickstart guide if your project uses the default (poky-style) layout where bitbake and layers are subdirectories of oe-core:

# Clone down Pyrex
git clone https://github.com/garmin/pyrex.git meta-pyrex

# Create the pyrex environment initialization script symbolic link
ln -s meta-pyrex/pyrex-init-build-env

# Create a default pyrex.ini config file
meta-pyrex/mkconfig > ./pyrex.ini

# Set PYREXCONFFILE to the location of the newly created config file
PYREXCONFFILE=./pyrex.ini

# Initialize the build environment
. pyrex-init-build-env

# Everything is setup. OpenEmbedded build commands (e.g. `bitbake`) will now
# run in Pyrex

Quickstart Guide (alternate layout)

Use this quickstart guide if your project uses a different layout where bitbake and oe-core are disjointed. In the example, it is assumed that oe-core and bitbake are both subdirectories of the current working directory, so you will need to change it to match your actual layout:

# Clone down Pyrex
git clone https://github.com/garmin/pyrex.git pyrex

# Create the pyrex environment initialization script symbolic link
ln -s pyrex/pyrex-init-build-env

# Create a default pyrex.ini config file
pyrex/mkconfig > ./pyrex.ini

# Set PYREXCONFFILE to the location of the newly created config file
PYREXCONFFILE=./pyrex.ini

# Tell Pyrex where bitbake and oe-core live
BITBAKEDIR=$(pwd)/bitbake
OEROOT=$(pwd)/oe-core

# Initialize the build environment
. pyrex-init-build-env

# Everything is setup. OpenEmbedded build commands (e.g. `bitbake`) will now
# run in Pyrex

What is Pyrex?

At its core, Pyrex is an attempt to provided a consistent environment in which developers can run Yocto and bitbake commands. Pyrex is targeted at development teams who want are doing interactive development with Yocto (although, Pyrex doesn't aim to be a full development environment, see below), and as such makes some different design decisions than other containerized solutions like CROPS.

Pyrex works by setting up a container image in which to run commands, then "trapping" the commands such that when the user executes the command in their shell, it is (hopefully) transparently executed inside the container instead.

What isn't Pyrex?

Pyrex isn't designed to be a complete Yocto IDE. The intention of Pyrex is not to run vim, emacs etc. and faithfully reproduce your development PC environment while also creating a reproducible build environment. Instead, Pyrex is designed to allow developers the freedom to use whatever tools and editors they want, run whatever distro they want, and configure their system how they want, but still run the actual Yocto build commands in a controlled environment.

Note that there are some provisions in the Pyrex image for running utilities tied into bitbake that can't easily be run any other way. For example, the commands bitbake -c devshell, bitbake -c devpyshell, and bitbake -c menuconfig (or any other commands that run in OE_TERMINAL) are all supported since there is no other way to easily run them outside the bitbake environment.

Note that because of this philosophy, it may not be possible to run some graphical tools such as hob when using Pyrex.

When should you use Pyrex?

There are a number of situations where Pyrex can be very useful:

  1. If you have multiple developers building on development machines with different setups (e.g. different distros). In these cases, Pyrex can help ensure that builds are consistent between different developers.
  2. You have to build multiple different versions of Yocto. Sadly, it isn't always possible to always use the latest and greatest version of Yocto, or even to use the same version of Yocto for all projects within a group. In these cases, Pyrex can be helpful because it will easily allow the different versions to use a container image that suits them without the developers having to think about it too much.

When should you not use Pyrex?

There are some situations where Pyrex may not always make sense:

  1. You aren't doing development. If all you need is a reproducible container to build Yocto in (for example, you just want to try out a build to see what Yocto is like), Pyrex is probably not for you. Pyrex has some amount of setup overhead and because of its focus doesn't isolate the container as much as some other solutions. In these cases CROPS is probably a better solution.
  2. You are a lone developer. Pyrex is primarily intended to ensure that a group of developers (e.g. a corporate or other group environment) working in Yocto will get consistent builds, regardless of their individual machine setups. This probably isn't much of a concern for a single individual.

Using Pyrex

Setup

Using vanilla Pyrex with a stock version of Yocto is pretty straight forward. First, add Pyrex to your project. There are many ways of doing this, but for this example, we will just clone it into a subdirectory of poky.

git clone https://github.com/garmin/pyrex.git meta-pyrex

NOTE: Cloning down Pyrex with the name meta-pyrex can be helpful if you want to put it as a subdirectory of poky, since poky's .gitignore will ignore all directories that start with 'meta-'

Next, you will need to create the environment setup script to initialize the Pyrex build environment. This script is equivalent to the oe-init-build-env script provided by poky and should be used by your developers in place of that script when they want to use Pyrex. There are a few ways to create this script, but all of them eventually must source the pyrex-init-build-env script. By default, this script assumes that you will create a symbolic link (named whatever you want) that lives alongside the oe-init-build-env script and points to pyrex-init-build-env. You can do this in our example like so:

ln -s meta-pyrex/pyrex-init-build-env

Alternatively, if you want your script to live somewhere else, or use a non-standard layout, you can write your own environment init script that tells pyrex-init-build-env where everything lives. A crude example script might look like:

# Paths that should be bound into the container. If unspecified, defaults to
# the parent directory of the sourced pyrex-init-build-env script, before
# it is resolved as a symbolic link. You may need to override the default if
# your bitbake directory, build directory, or any of your layer directories are
# not children of the default (and thus, wouldn't be bound into the container).
PYREX_CONFIG_BIND="$(pwd)"

# The path to the build init script. If unspecified, defaults to
# "$OEROOT/oe-init-build-env" or "$(pwd)/oe-init-build-env"
PYREX_OEINIT="$(pwd)/oe-init-build-env"

# The location of Pyrex itself. If not specified, pyrex-init-build-env will
# assume it is the directory where it is currently located (which is probably
# correct)
PYREX_ROOT="$(pwd)/meta-pyrex"

# Alternatively, if it is desired to always use a fixed config file that users
# can't change, set the following:
#PYREXCONFFILE="$(pwd)/pyrex.ini"

# Source the core pyrex environment script. Note that you must pass the
# arguments
. $(pwd)/meta-pyrex/pyrex-init-build-env "$@"

NOTE: While it might be tempting to combine all of these into a one-liner like PYREXCONFFILE="..." . $(pwd)/meta-pyrex/pyrex-init-build-env "$@", they must be specified on separate lines to remain compatible will all shells (i.e. bash in particular won't keep temporary variables specified in this way)

Configuration

Pyrex is configured using a ini-style configuration file. The location of this file is specified by the PYREXCONFFILE environment variable. This environment variable must be set before the environment is initialized.

If you do not yet have a config file, you can use the mkconfig command to use the default one and assign the PYREXCONFFILE variable in a single command like so:

$ export PYREXCONFFILE=`./meta-pyrex/mkconfig ./pyrex.ini`

The configuration file is the ini file format supported by Python's configparser class, with the following notes:

  1. The only allowed comment character is #
  2. The only allowed key assignment character is = (e.g. key : value is not supported)
  3. Extended interpolation is supported. Thus, you can reference other variables in the form ${section:key}
  4. All keys are case sensitive

For more information about specific configuration values, see the default pyrex.ini

Binding directories into the container

In order for bitbake running in the container to be able to build, it must have access to the data and config files from the host system. There are two variables that can be set to specify what is bound into the container, the PYREX_CONFIG_BIND environment variable and the run:bind option specified in the config file. Both variables are a whitespace separated list of host paths that should be bound into the container at the same path (e.g. /foo/bar in the host will be bound to /foo/bar in the container engine).

The PYREX_CONFIG_BIND environment variable is intended to specify the minimal set of bound directories required to initialize a default environment, and should only be set the by the environment initialization script, not by end users. The default value for this variable if unspecified is the parent of the sourced Pyrex initialization script. If the sourced script happens to be a symbolic link, the parent directory is determined before the symbolic link is resolved.

The run:bind config file option is intended to allow users to specify additional paths that they want to bind. For convenience, the default value of this variable allows users to specify binds in the PYREX_BIND environment variable if they wish.

Common reasons users might need to bind new paths include:

  • Alternate (out of tree) locations for sstate and download caches
  • Alternate (out of tree) build directories
  • Additional layers that are not under the default bind directories

When the container environment is setup some basic sanity checks will be performed to makes sure that important directories like the bitbake and build directories are bound into the container.

You should never map directories like /usr/bin, /etc/, / as these will probably just break the container. It is probably also unwise to map your entire home directory; although in some cases may be necessary to map $HOME/.ssh or other directories to access SSH keys and the like. For user convenience, the proxy user created in the container image by default has the same $HOME as the user who created the container, so these types of bind can be done by simply adding ${env:HOME}/.ssh to run:bind

Debugging the container

In the event that you need to get a shell into the container to run some commands, Pyrex creates a command called pyrex-shell. Executing this command in a Pyrex environment will run a shell in the container image, allowing interactive commands to be run. This can be very useful for debugging Pyrex containers.

You can also run arbitrary commands in the container with the pyrex-run command. Be aware that any changes made to the container are not persistent, and will be discarded when pyrex-run exits.

Running Pyrex

Once Pyrex is configured, using it is very straight forward. First, source the Pyrex environment setup you created. This will setup up the current shell to run the commands listed in ${config:command} inside of Pyrex. Once this is done, you can simply run those commands and they will be executed in Pyrex.

What doesn't work?

The following items are either known to not work, or haven't been fully tested:

  • Bitbake Server Since the container starts and stops each time a command is run, it is currently not possible to use the bitbake server that runs persistently in the background. I believe it might be possible to do this using persistent container images and docker exec, but it hasn't been thoroughly investigated.
  • devtool This may or may not work, and it might not take too much to get it working, but it hasn't been tested.
  • GUI terminals It is unlikely that you will be able to set OE_TERMINAL to use a GUI shell (e.g. rvxt) for use with devshell, pydevshell, menuconfig, etc. There currently isn't a mechanism for running GUI programs inside of the container and having them draw in the parent windowing system (although I suspect this isn't impossible). The only terminal for that is known to work inside the container screen. Thankfully, the default value for OE_TERMINAL of auto chooses this by default with the default Pyrex container image.
  • Shell job control Currently, using CTRL+Z to background the container doesn't work. It might be possible to get it to work one day, but until then the SIGTSTP signal is ignored by all child processes in Pyrex to prevent it from causing bad behaviors. It is still possible to pause the container using the docker pause command, but this doesn't integrate with the parent shells job control.
  • Rootless Docker This in untested, and probably doesn't work. It shouldn't be too hard since this should be very similar to how podman works. Currently however, it is assumed that if the container engine is docker it is running as root and if it is podman it is running rootless.

Developing on Pyrex

If you are doing development on Pyrex itself, please read the Developer Documentation

Using the latest image

While you can instruct Pyrex to pull the latest tag from dockerhub for a given image instead of a versioned release tag, this is highly discouraged, as it will most certainly cause problems. In these cases, you probably want to build the image locally instead. See the Developer Documentation.

FAQ

  • Why use a Ubuntu image as the default? The default container image that Pyrex creates is based on Ubuntu. Yes, it is known that there are other images out there that are lighter weight (e.g. Alpine Linux), but Ubuntu was chosen because it is one of the Sanity Tested Distros that Yocto supports. Pyrex aims to support a vanilla Yocto setup with minimal manual configuration.

  • What's with cleanup.py? When a container's main process exits, any remaining process appears to be sent a SIGKILL. This can cause a significant problem with many of the child processes that bitbake spawns, since unceremoniously killing them might result in lost data. The cleanup script is attached to a modified version of tini, and prevents tini from exiting until all child processes have exited (it sends them SIGTERM if they are being tardy). One of the particularly bad culprits is pseudo, which uses an in-memory sqlite database to record file permissions. This database is only written to disk periodically, meaning a significant amount of very important data can be lost if it is killed without being given the chance to cleanup. If you find yourself in the unfortunate circumstance of needing to debug the cleanup script, you can set the environment variable PYREX_CLEANUP_LOG_LEVEL to INFO or DEBUG for more logging.

  • Does the "py" in Pyrex refer to "Python"? No, it is incidental. The fact that the implementation currently uses Python is an implementation detail that users should not rely on (or be concerned with). Python was chosen because it is already a dependency for using bitbake, so it should already be present on a host machine.

  • Were you aware of Pyrex? Oops. Hopefully there isn't too much confusion; that Pyrex looks abandoned anyway

  • I can't access SSH or authenticated HTTP sources inside the container! This happens because the container doesn't bind in any of your personal authentication files (e.g. ~/.ssh/config) by default. If you need support for this, you can the lines shown below to the run:bind in pyrex.ini, which should cover most fetching cases:

    [run]
    bind =
        ${env:PYREX_BIND}
        ${env:HOME}/.ssh,readonly
        ${env:HOME}/.netrc,optional,readonly
        ${env:HOME}/.gitconfig,optional,readonly
        ${env:HOME}/.config/git,optional,readonly
    

pyrex's People

Contributors

jamesharris-garmin avatar joshuawatt avatar kergoth avatar kevinbreit-garmin avatar matthoosier-garmin avatar qschulz avatar rossstutterheim-garmin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pyrex's Issues

ulimit default too low

In the base containers, ulimit is set to 1024 (yes, I realize this is the docker default).

This is too low and caused (at least) ninja to fail to compile:

ERROR: Logfile of failure stored in: /srv/build/ttorling/poky-pyrex/build/tmp/work/x86_64-linux/ninja-native/1.10.0-r0/temp/log.do_compile.28230 Log data follows: | DEBUG: Executing shell function do_compile | [1/31] RE2C src/depfile_parser.cc | [2/31] INLINE build/browse_py.h | [3/31] RE2C src/lexer.cc | [4/31] CXX build/debug_flags.o | [5/31] CXX build/disk_interface.o | FAILED: build/disk_interface.o | g++ -MMD -MT build/disk_interface.o -MF build/disk_interface.o.d -g -Wall -Wextra -Wno-deprecated -Wno-missing-field-initializers -Wno-unused-parameter -fno-rtti -fno-exceptions -fvisibility=hidden -pipe '-DNINJA_PYTHON="python3"' -O2 -DNDEBUG -DUSE_PPOLL -DNINJA_HAVE_BROWSE -I. -isystem/srv/build/ttorling/poky-pyrex/build/tmp/work/x86_64-linux/ninja-native/1.10.0-r0/recipe-sysroot-native/usr/include -O2 -pipe -isystem/srv/build/ttorling/poky-pyrex/build/tmp/work/x86_64-linux/ninja-native/1.10.0-r0/recipe-sysroot-native/usr/include -O2 -pipe -c src/disk_interface.cc -o build/disk_interface.o | In file included from /usr/include/c++/7/cstdlib:75:0, | from /usr/include/c++/7/ext/string_conversions.h:41, | from /usr/include/c++/7/bits/basic_string.h:6361, | from /usr/include/c++/7/string:52, | from /usr/include/c++/7/stdexcept:39, | from /usr/include/c++/7/array:39, | from /usr/include/c++/7/tuple:39, | from /usr/include/c++/7/bits/stl_map.h:63, | from /usr/include/c++/7/map:61, | from src/disk_interface.h:18, | from src/disk_interface.cc:15: | /usr/include/stdlib.h:25:10: fatal error: /usr/include/x86_64-linux-gnu/bits/libc-header-start.h: Too many open files | #include <bits/libc-header-start.h> | ^~~~~~~~~~~~~~~~~~~~~~~~~~ | compilation terminated. | [6/31] CXX build/ninja.o | FAILED: build/ninja.o

This is on CentOS 8.1, latest master of poky, latest pyrex. Default in CentOS 8.1 is podman, so it is possible that is a factor, but I would be skeptical.

The build machine is a dual Xeon E5-26xx so multiple tasks are running at once. If I individually run '$ bitbake ninja-native', it builds fine. But then comes a box of dominoes (binutils-native, libpcre-native, perl-native, etc). Build target is core-image-full-cmdline.

If it is just a matter of a different configuration, it would handy to have that documented.

Fails temp directory creation

Following the README only leads to failing the creation of the randomly named /tmp subdirectory and stops there

Ubuntu 20.04, poky, warrior branch

Initial enviroment setup occurs in host

The initial sourcing of the OE init script (e.g. oe-init-build-env) still happens in the host environment. This allows pyrex to that environment variables in it's configuration (for example, this is why pyrex is able to place the pyrex.ini in the $BUILDDIR/conf directory. However, this does cause a few issues. Primarily, the init script does some environment sanity checking, which means the host has to be a valid environment in order to use pyrex, which is undesirable when trying to build older versions on newer hosts.

Pyrex should be reworked to source the initial environment script inside the container instead and capture the required variables. This does have one downside which is that the mechanism for populating pyrex.ini from templates will no longer work because the target build directory can't be known before launching the container (and it likely needs to be because it needs to know the users bind points). One possible solution is to require the user to specify the location of the pyrex.ini file via the PYREXTEMPLATECONF variable before initing the environment.

Provide docker images for arm64/v8

Hi,

I am working with pyrex for several months now. Would it be possible that you provide the images for arm64/v8 as well?
This would give me the possibility to build yocto on Apple Silicon inside a virtual machine.

Best Regards

How to properly use a custom image from another registry?

I can't seem to get the syntax right for this. I get the following output, when I run docker images

git.custom.com:1234/some-path/some-path/someimage   latest    2848f820ea3   3 months ago   631MB

I am trying to edit the pyrex.ini as follows

tag = some-path/some-path/someimage:latest

registry = git.custom.com

but I am getting the following output

docker: Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "/usr/libexec/pyrex/capture": stat /usr/libexec/pyrex/capture: no such file or directory: unknown.

I am assuming the whole url is not assembled correctly. Is there any way I can get Pyrex to provide verbose output to see what it actually tries to pull from?

EDIT: Okay, I just edited the pyrex.ini and printed the tag variable, which seems to be assembled correctly with the registry. No idea why it is failing. Could it be the port? The registry also requires a login. Does Pyrex support that?

Wrong builddir behavior

After working around #31:

$ pwd
/data/kergoth/mel/yocto-test/pyrex-test
$ PYREX_OEROOT=$PWD/oe-core PYREX_OEINIT=$PWD/oe-core/oe-init-build-env . ./pyrex/pyrex-init-build-env

### Shell environment set up for builds. ###

You can now run 'bitbake <target>'

Common targets are:
    core-image-minimal
    core-image-sato
    meta-toolchain
    meta-ide-support

You can also run generated qemu images with a command like 'runqemu qemux86'.

Other commonly useful commands are:
 - 'devtool' and 'recipetool' handle common recipe tasks
 - 'bitbake-layers' handles common layer tasks
 - 'oe-pkgdata-util' handles common target package tasks
$ pwd
/data/kergoth/mel/yocto-test/pyrex-test/build
$ which bitbake
bitbake is /data/kergoth/mel/yocto-test/pyrex-test/build/pyrex/bin/bitbake
$ bitbake -e | grep TOPDIR=
TOPDIR="/data/kergoth/mel/yocto-test/pyrex-test/oe-core/build"
$

Investigating further.

Custom registry and tagging images

Having a tag like

tag = my/great/image:pyrex-v2

and a registry like

registry = ghcr.io

When I build my image, the resulting docker image will be named/tagged as my/great/image:pyrex-v2, ie. without the registry information. AFAICT I then need to make sure that I or my users do not push it to docker.io by mistake, since that's the default registry.

When I let pyrex pull my image automatically (via whisk) the image will be named/tagged as ghcr.io/my/great/image:pyrex-v2.

Ideally I'd like my image to always contain the custom registry in its tag, even when built myself. But I don't see how I can do that without modifying pyrex's source. If I prepend the tag with my registry this will let me build a correctly-tagged image, but during fetching pyrex will prepend the registry yet again to the tag and try to fetch an image tagged ghcr.io/ghcr.io/my/greate/image....

Of course we can simply patch pyrex to always prepend the registry even when building locally and make sure to not append it if the user prepended it manually in pyrex.ini.

Do you have any thoughts about this? I'd like to minimize the risk of things being pushed to docker.io by mistake. Maybe a small thing, but 🤷

Bitbake 2.0 refuses to run in pyrex; inclusive language violations

When running any bitbake version >= 2.0 within a pyrex container, bitbake will throw a fatal error during recipe parsing and return code 1.

[0] usr0:build$ bitbake -e glibc
ERROR: Variable BB_ENV_EXTRAWHITE has been renamed to BB_ENV_PASSTHROUGH_ADDITIONS
ERROR: Variable BB_ENV_EXTRAWHITE from the shell environment has been renamed to BB_ENV_PASSTHROUGH_ADDITIONS
ERROR: Exiting to allow enviroment variables to be corrected

The error source is here, and it was added to enforce restrictions on insufficiently inclusive variables being defined in the environment. Bitbake will error whenever BB_ENV_EXTRAWHITE is defined in the execution environment, and it is unconditionally defined by pyrex.

pyrex/pyrex.py

Lines 554 to 557 in bebe3f9

# Pass along BB_ENV_EXTRAWHITE and anything it has whitelisted
if "BB_ENV_EXTRAWHITE" in os.environ:
engine_args.extend(["-e", "BB_ENV_EXTRAWHITE"])
container_envvars.extend(os.environ["BB_ENV_EXTRAWHITE"].split())

pyrex/image/capture.sh

Lines 100 to 103 in bebe3f9

"export": {
"BB_ENV_EXTRAWHITE": "$BB_ENV_EXTRAWHITE",
"BUILDDIR": "$BUILDDIR"
}

Bitbake 2.0 support is needed for pyrex users to build the OE kirkstone release and beyond.

Feature request: add nerdctl support

See nerdctl. It behaves much like Podman and docker, and integrates well with lima on the Mac. More viable open options are good given the flak docker is taking over licensing just now (personally I think it's a reasonable move on their part, but.. :)

ubuntu 22.04

What are the plans to add support for ubuntu 22.04 container?

uidmap has negative number when UID is very large

I'm using pyrex to as part of the process for building the NI Linux RT image used by nilrt. I followed the instructions in the ni/nilrt README.md up to the step where you source ni-oe-init-build-env. That file runs pyrex capture which in turn attempts to run podman run with a malformed --uidmap. The error message is as follows:

Error: error initializing ID mappings: UID setting is malformed expected ["uint32:uint32:uint32"]: ["0:1:1900000000" "1900000000:0:1" "1900000001:1900000001:-1899934464"]

I'm using Ubuntu 20.01 and Python 3.9.12. nilrt pulls in a submodule of pyrex at 8262423. The ni org has their own fork of pyrex but it's unmodified from this repo.

My UID is 1900000000. (Truthfully, my actual UID is not that round but this is close enough.) I didn't choose the UID, it was assigned by the team that configured the machine at my workplace. I've never used a machine where my UID was more than four or five digits but apparently UIDs can use a full uint32. I am not sure what motivated the selection of such a large UID. 🤷

Here's my /etc/subuid; foo is another user (and group) while me is my username and group.

foo:100000:65536
me:165536:65536

And my /etc/subgid:

foo:100000:65536
me:165536:65536

Fails with zsh

When attempting to source pyrex-init-build-env from zsh:

Traceback (most recent call last):
  File ".../pyrex/pyrex.py", line 610, in <module>
    main()
  File ".../pyrex/pyrex.py", line 606, in main
    sys.exit(args.func(args))
  File ".../pyrex/pyrex.py", line 231, in capture
    os.write(args.fd, build_conffile.encode('utf-8'))
OSError: [Errno 9] Bad file descriptor

It seems that use of file descriptors greater than 10 without using the {varname} syntax is not particularly portable among shells. See also https://unix.stackexchange.com/a/227100. Use of 0-9 seems to be more portable.

groupadd fails if the group already exists

If the build user's group isn't a unique one, but is one that already exists in the docker image's groups file, the groupadd will fail, making pyrex fail. Likely either we should ignore the failure, or check if we need to add it first.

docker fails if SSH_AUTH_SOCK is a symbolic link

pyrex doesn't work under Visual Studio Code using the Remote - SSH extension at the moment, as docker errors out trying to mount the SSH_AUTH_SOCK.

Ex.

$ echo $SSH_AUTH_SOCK
/tmp/vscode-ssh-auth-sock-800238678
$ ls -l $SSH_AUTH_SOCK
lrwxrwxrwx 1 kergoth kergoth 30 Oct 31 04:14 /tmp/vscode-ssh-auth-sock-800238678 -> /tmp/ssh-3BXtESk4jp/agent.2656
$ ls -l $(readlink -f $SSH_AUTH_SOCK)
srwxrwxr-x 1 kergoth kergoth 0 Oct 31 04:14 /tmp/ssh-3BXtESk4jp/agent.2656
$ bitbake -p
docker: Error response from daemon: invalid mount config for type "bind": stat /tmp/vscode-ssh-auth-sock-800238678: permission denied.
See 'docker run --help'.

Can't start pyrex in LXC container

Hi,

I'm trying to get pyrex going as a GitHub action runner on a cloud box I run. This cloud box runs proxmox and I have a number of LXC containers running on it.

I've installed docker to be able to run inside the LXC container and this works for me e.g. docker run hello-world works.

I followed the instructions for running pyrex and I get this error. I wonder if this is because I have had to change the way docker runs within the LXC container to use aufs

image

All thoughts appreciated as I've love to be able to use this for builds!

Add PYREX_USER to Docker Group if it exists.

In some images based on pyrex we will want to add our PYREX_USER to the docker group if that group is already created. This will allow us to access the docker daemon without the need to use sudo locally.

devtool edit-recipe doesn't work

devtool edit-recipe doesn't find vi. Quentin already found the root of the cause. The EDITOR env variable needs to be passed to Pyrex and all common editors should be installed in the container.

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.