openembedded-core.lists.openembedded.org archive mirror
 help / color / mirror / Atom feed
* looking for a recipe for LXD container to do OE/YP builds
@ 2022-08-11  7:29 Robert P. J. Day
  0 siblings, 0 replies; only message in thread
From: Robert P. J. Day @ 2022-08-11  7:29 UTC (permalink / raw)
  To: OE Core mailing list


  (not so much an OE question as a build question related to the
proper design of LXD container for doing OE builds.)

  colleague asked me how to best create an LXD container based on a
specific release (ubuntu 18.04); specifically, how to use idmapped
mounts to correctly map a directory into the container so that UIDs
don't step on each other, so here's the scenario.

  * (google repo-based) YP checkout that will, in the end, apparently
generate 120BG(!!!) of output.

  * must be ubuntu 18.04 container based on versions of OE/YP layers
being checked out

the need to do this mapping is that, by default, when you shell into
the LXD container, you're running as root, which of course will not
work for running bitbake. and the tricky(?) part is that:

  1) on my ubuntu 22.04 host, my account is rpjday/1000.
  2) the non-root account created in the container is ubuntu/1000

so we already have a bit of conflict in matching UIDs attached to
different usernames.

  i'm just trying to determine the preferred way to set up /etc/subuid
and /etc/subgid and an LXC device so that i can map the entire build
directory into the container, shell into the container, do the build
there and have all the output go into the mapped directory so that it
(obviously) ends up on my host and not in the container (where there
is nowhere near 120G of space, and i don't want to resize the
container to that extent).

  thoughts? i'm about to try a few combinations and might stumble
across something that works, but if anyone else has gone through this
and has a recipe, that would be just ducky.

rday

p.s. my first guess is that it might not be an issue that there are
two different accounts with UID 1000, since ubuntu in the container
will map nicely to my own account on the host. but we'll see shortly.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-08-11  7:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-11  7:29 looking for a recipe for LXD container to do OE/YP builds Robert P. J. Day

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).