ssssam commented on code in PR #1741: URL: https://github.com/apache/buildstream/pull/1741#discussion_r955108207
########## doc/source/main_install.rst: ########## @@ -285,13 +327,23 @@ A regular way to do this is to add the following line to the end of your ``~/.ba .. _install-container: - Buildstream Inside a Container ------------------------------- -If your system cannot provide the base requirements, it is possible to run -BuildStream within a container. This gives you an easy way to get started -using BuildStream on any Unix-like platform where containers are available, -including macOS. -For details, see the `Buildstream Docker documentation -<https://gitlab.com/BuildStream/buildstream-docker-images/-/blob/master/USING.md>`_ +It is possible to run BuildStream in an OCI container tool such as Docker. +This gives you an easy way to get started using BuildStream on any Unix-like +platform where containers are available, including macOS. + +Prebuilt images are available, see the documentation +`here <https://gitlab.com/BuildStream/buildstream-docker-images/-/blob/master/USING.md>`_ + +You can also produce your own container images, either by adapting the +`buildstream-docker-images project <https://gitlab.com/BuildStream/buildstream-docker-images/>`_, +or by following the full installation instructions above. + +Note that some special configuration is often needed to run BuildStream in a container: + + * User namespaces are used to isolate and control builds. This requires the + Docker ``--privileged`` mode. Review Comment: I didn't get as far as creating namespaces as it turns out `fusermount3` can't mount: ``` > podman run --device /dev/fuse -i -t --rm registry.gitlab.com/freedesktop-sdk/infrastructure/freedesktop-sdk-docker-images/bst2 [root@de014e636534 /]# bst --version 1.95.2.dev0 [root@de014e636534 /]# cd [root@de014e636534 ~]# git clone https://github.com/apache/buildstream [root@de014e636534 buildstream]# cd doc/examples/running-commands/ [root@de014e636534 running-commands]# bst build hello.bst ... Failure Summary hello.bst: [00:00:00][8cebf405][ build:hello.bst ] FAILURE buildbox-run failed with returncode 1 Printing the last 20 lines from log file: /root/.cache/buildstream/logs/running-commands/hello/8cebf405-build.110.log ====================================================================== LC_ALL: C HOME: /tmp TZ: UTC SOURCE_DATE_EPOCH: 1321009871 [--:--:--] START [8cebf405] hello.bst: Staging dependencies at: / [--:--:--] STATUS [b59f4520] base/alpine.bst: Staging base/alpine.bst/b59f4520 [--:--:--] STATUS [bb393e5a] base.bst: Staging base.bst/bb393e5a [00:00:00] SUCCESS [8cebf405] hello.bst: Staging dependencies at: / [--:--:--] START [8cebf405] hello.bst: Integrating sandbox [00:00:00] SUCCESS [8cebf405] hello.bst: Integrating sandbox [--:--:--] START [8cebf405] hello.bst: Staging sources [00:00:00] SUCCESS [8cebf405] hello.bst: Staging sources [--:--:--] START hello.bst: Running commands make PREFIX="/usr" make -j1 PREFIX="/usr" DESTDIR="/buildstream-install" install 2022-08-25T15:20:08.005+0000 [191:139995975073728] [buildboxcommon_casclient.cpp:95] [INFO] Setting d_maxBatchTotalSizeBytes = 4128768 bytes by default 2022-08-25T15:20:08.155+0000 [191:139995975073728] [buildboxcommon_runner.cpp:437] [ERROR] [actionDigest=ace830804d554a11f87ee8018bde83888d28775d4208e1798a010fdec4cd680f/178] Error executing command: std::runtime_error exception thrown at [buildboxcommon_casclient.cpp:900], errMsg = "Error staging "63db766975a429f55445f8e0a24f4107be339b311f002cb631841a71d91234ed/1438" into "": "std::runtime_error exception thrown at [buildboxcasd_fusestager.cpp:144], errMsg = "The FUSE stager child process unexpectedly died with exit code 1""" [00:00:00] FAILURE hello.bst: Running commands [00:00:00] FAILURE [8cebf405] hello.bst: buildbox-run failed with returncode 1 ====================================================================== Pipeline Summary Total: 3 Session: 3 Fetch Queue: processed 3, skipped 0, failed 0 Build Queue: processed 2, skipped 0, failed 1 [root@de014e636534 running-commands]# mkdir cas local [root@de014e636534 running-commands]# buildbox-fuse --local=cas local fusermount3: mount failed: Operation not permitted ``` So it seems I can't usefully build stuff if I don't supply `--privileged` to podman. Adding that to the commandline got me a successful build. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
