<feed xmlns='http://www.w3.org/2005/Atom'>
<title>guix.git/tests/guix-environment-container.sh, branch master</title>
<subtitle>Personal branch of https://git.savannah.gnu.org/cgit/guix.git/ for implementing 'guix deploy'.
</subtitle>
<id>https://www.git.jakob.space/guix.git/atom?h=master</id>
<link rel='self' href='https://www.git.jakob.space/guix.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/'/>
<updated>2019-04-02T16:15:37Z</updated>
<entry>
<title>environment: '-C' creates namespaces where the user is not root.</title>
<updated>2019-04-02T16:15:37Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2019-04-02T08:57:24Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=1ccc0f807d3f22fa9ade1c607c112e04df833a72'/>
<id>urn:sha1:1ccc0f807d3f22fa9ade1c607c112e04df833a72</id>
<content type='text'>
* guix/scripts/environment.scm (launch-environment/container): Add UID
and GID.  Use them in PASSWD and GROUPS.  Pass them as #:guest-uid and
 #:guest-gid to 'call-with-container'.
* tests/guix-environment-container.sh: Test the inner UID.
In '--user' test, replace hard-coded 0 with 1000.
* doc/guix.texi (Invoking guix environment): Adjust accordingly.
</content>
</entry>
<entry>
<title>environment: Create /etc/group in containers.</title>
<updated>2019-03-26T17:11:52Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2019-03-26T17:07:58Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=952afb6f8c209692e52f9561965ee39e143e1d88'/>
<id>urn:sha1:952afb6f8c209692e52f9561965ee39e143e1d88</id>
<content type='text'>
Reported by Pierre Neidhardt &lt;mail@ambrevar.xyz&gt;.

* guix/scripts/environment.scm (launch-environment/container): Create
GROUPS and call 'write-group'.
* tests/guix-environment-container.sh: Test it.
</content>
</entry>
<entry>
<title>environment: Use (gnu build accounts) for /etc/passwd handling.</title>
<updated>2019-03-26T17:11:52Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2019-03-26T11:12:41Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=8a9922bdee875b3b5e1d928fc8e2121ffa99663a'/>
<id>urn:sha1:8a9922bdee875b3b5e1d928fc8e2121ffa99663a</id>
<content type='text'>
* guix/scripts/environment.scm (launch-environment/container): Remove
call to 'mock-passwd'; instantiate a &lt;password-entry&gt; instead.  Call
'write-passwd' to write the pasword database instead of using custom
code.
(mock-passwd): Remove.
* tests/guix-environment-container.sh: Test 'getpwuid'.
</content>
</entry>
<entry>
<title>environment: Add --user.</title>
<updated>2018-03-02T10:55:43Z</updated>
<author>
<name>Mike Gerwitz</name>
<email>mtg@gnu.org</email>
</author>
<published>2018-01-26T03:29:32Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=e37944d8270cdca5729e3583136c4fe9d487779c'/>
<id>urn:sha1:e37944d8270cdca5729e3583136c4fe9d487779c</id>
<content type='text'>
This change allows overriding the home directory of all filesystem mappings to
help hide the identity of the calling user in a container.

* doc/guix.texi (Invoking guix environment)[--container]: Mention --user.
[--user]: Add item.
* guix/scripts/environment.scm (show-help): Add --user.
(%options): Add --user.
(launch-environment/container) Add 'user' parameter.  Update doc.  Override
'user-mappings' using 'override-user-mappings'.  Consider override for chdir.
(mock-passwd, user-override-home, overrid-euser-dir): New procedures.
(guix-environment): Disallow --user without --container.  Provide user to
'launch-environment/container'.
* tests/guix-environment.sh: Add user test.

Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
</entry>
<entry>
<title>environment: Add --link-profile.</title>
<updated>2018-03-02T10:55:42Z</updated>
<author>
<name>Mike Gerwitz</name>
<email>mtg@gnu.org</email>
</author>
<published>2018-01-26T03:29:15Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=07ec349229eeae9f733fe92a300c7cfa4cf8e321'/>
<id>urn:sha1:07ec349229eeae9f733fe92a300c7cfa4cf8e321</id>
<content type='text'>
This change is motivated by attempts to run programs (like GNU IceCat) within
containers.  The 'fontconfig' program, for example, is configured explicitly
to check ~/.guix-profile for additional fonts.

There were no existing container tests in 'tests/guix-environment.sh', but I
added one anyway for this change.

* doc/guix.texi (Invoking guix environment): Add '--link-profile'.
* guix/scripts/environment.scm (show-help): Add '--link-profile'.
(%options): Add 'link-profile' as '#\P', assigned to 'link-profile?'.
(link-environment): New procedure.
(launch-environment/container): Use it when 'link-profile?'.
[link-profile?]: New parameter.
(guix-environment): Leave when '--link-prof' but not '--container'.  Add
'#:link-profile?' argument to 'launch-environment/container' application.
* tests/guix-environment-container.sh: New '--link-profile' test.

Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
</entry>
<entry>
<title>tests: Fix 'guix environment --container' test in the presence of tmpfs.</title>
<updated>2016-08-28T22:09:44Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2016-08-28T14:02:41Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=7cdec6a90ab6342b1ff7b4a3e9b7ec82e9c8b914'/>
<id>urn:sha1:7cdec6a90ab6342b1ff7b4a3e9b7ec82e9c8b914</id>
<content type='text'>
Reported by Ting-Wei Lan &lt;lantw44@gmail.com&gt;.
This is a followup to 1250034d5aff14fe236aad9900233a2b6f8563bb.

* tests/guix-environment-container.sh (mount_test_code): Reverse order
of 'string-prefix?' arguments.
</content>
</entry>
<entry>
<title>tests: 'guix-environment-container.sh' works when run from a tmpfs.</title>
<updated>2016-07-31T16:51:38Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2016-07-31T16:51:38Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=1250034d5aff14fe236aad9900233a2b6f8563bb'/>
<id>urn:sha1:1250034d5aff14fe236aad9900233a2b6f8563bb</id>
<content type='text'>
Fixes &lt;http://bugs.gnu.org/22004&gt;.
Reported by Ting-Wei Lan &lt;lantw44@gmail.com&gt;.

* tests/guix-environment-container.sh (mount_test_code): Add 'match'
clause to ignore "/"; augment clause that ignores specific file system
types such that it does not ignore parent mount points.
</content>
</entry>
<entry>
<title>container: Gracefully report mount errors in the child process.</title>
<updated>2016-05-30T22:11:04Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2016-05-30T20:44:58Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=c06f6db7a424fd47e3cd2625dbfda2367316f3bd'/>
<id>urn:sha1:c06f6db7a424fd47e3cd2625dbfda2367316f3bd</id>
<content type='text'>
Fixes &lt;http://bugs.gnu.org/23306&gt;.

* gnu/build/linux-container.scm (run-container): Use 'socketpair'
instead of 'pipe'.  Rename 'in' to 'child' and 'out' to 'parent'.  Send
a 'ready message or an exception argument list from the child to the
parent; adjust the parent accordingly.
* tests/containers.scm ("call-with-container, mnt namespace, wrong bind
mount"): New test.
* tests/guix-environment-container.sh: Add test with
--expose=/does-not-exist.
</content>
</entry>
<entry>
<title>environment: Properly handle SIGINT.</title>
<updated>2016-03-27T19:09:21Z</updated>
<author>
<name>David Thompson</name>
<email>dthompson2@worcester.edu</email>
</author>
<published>2016-03-26T12:45:08Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=13bc8d5e4f842fe595306c22c99a5868d8016318'/>
<id>urn:sha1:13bc8d5e4f842fe595306c22c99a5868d8016318</id>
<content type='text'>
Switching to execlp means that the process spawned in a container is PID
1, which obsoleted one of the 'guix environment --container' tests
because the init process can't be killed in the usual manner.

* guix/scripts/environment.scm (launch-environment/fork): New procedure.
(launch-environment): Switch from system* to execlp.  Add handler for
SIGINT.
(guix-environment): Use launch-environment/fork.
* tests/guix-environment-container.sh: Replace abnormal exit test with
one that works now that the spawned process is PID 1.
</content>
</entry>
<entry>
<title>scripts: environment: Build environments as profiles.</title>
<updated>2016-02-12T21:02:06Z</updated>
<author>
<name>David Thompson</name>
<email>davet@gnu.org</email>
</author>
<published>2016-02-12T20:39:26Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=779aa003fbacbbcb6973f289b607d1d285009cec'/>
<id>urn:sha1:779aa003fbacbbcb6973f289b607d1d285009cec</id>
<content type='text'>
Fixes &lt;http://bugs.gnu.org/19816&gt;.

* guix/scripts/environment.scm (evaluate-input-search-paths)
(build-inputs): Delete.
(evaluate-profile-search-paths, strip-input-name)
(package-or-package+output?, package-environment-inputs)
(build-environment, inputs-&gt;profile-derivations): New procedures.
(create-environment, show-search-paths, launch-environment)
(launch-environment/container): Replace 'inputs' argument
with 'profile' argument.
(package+propagated-inputs): Strip off names off of input tuples.
(options/resolve-packages): Handle input tuples that specify an output
in expressions.
(guix-environment): Convert inputs into a profile to use in the
environment.  Remove non-package inputs such as origins from
environment inputs.
* doc/guix.texi ("invoking guix environment"): Document package+output
tuples for --expression option.
* tests/guix-environment.sh: Update tests.
* tests/guix-environment-container.sh: Likewise.

Co-authored-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
</entry>
</feed>
