Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
0bdd8bc
gh-95023: added os.setns and os.unshare for namespaces switching on L…
noamcohen97 Jul 20, 2022
3685a27
remove gil release
noamcohen97 Jul 20, 2022
8f22740
better setns, unshare doc
noamcohen97 Jul 21, 2022
5115c8a
added example to setns
noamcohen97 Jul 21, 2022
8845a86
added note about fileno for setns
noamcohen97 Jul 21, 2022
d7bb582
added see also section for os.unshare
noamcohen97 Jul 21, 2022
987613a
Update configure.ac
noamcohen97 Jul 26, 2022
4c91413
Revert "remove gil release"
noamcohen97 Jul 26, 2022
7d23963
better docs
noamcohen97 Jul 26, 2022
b7abf20
assume Linux platform has a working readlink
noamcohen97 Jul 26, 2022
af74db5
change ifdefs
noamcohen97 Jul 26, 2022
5181126
added missing `CLONE_*` consts
noamcohen97 Jul 26, 2022
3a37ac2
run unshare in a different process
noamcohen97 Jul 26, 2022
1386833
reformat doc
noamcohen97 Jul 26, 2022
ae4b661
indent test code
noamcohen97 Jul 26, 2022
57b2c84
Apply suggestions from code review
noamcohen97 Jul 26, 2022
b2df7f7
better doc
noamcohen97 Jul 26, 2022
b4a68b6
Merge branch 'main' into namespaces
noamcohen97 Jul 26, 2022
dc51d01
remove whitespaces from doc
noamcohen97 Jul 26, 2022
5a3cff5
fix NEWS entry
noamcohen97 Jul 26, 2022
1d45196
move test code to another file
noamcohen97 Jul 26, 2022
84c4b8c
add glibc requirements to doc
noamcohen97 Jul 26, 2022
b9d3a34
Revert "move test code to another file"
noamcohen97 Jul 26, 2022
51c60d4
proofreaders review fixes
noamcohen97 Jul 26, 2022
225e06b
fix doc whitespaces
noamcohen97 Jul 26, 2022
fb64bb7
better documentation
noamcohen97 Jul 27, 2022
01d4af4
fix docs
noamcohen97 Jul 27, 2022
15e6d8b
remove bitwise or explanation
noamcohen97 Jul 27, 2022
375165b
Apply suggestions from code review
noamcohen97 Jul 28, 2022
7e2b44c
fix typo
noamcohen97 Jul 28, 2022
3ae952c
ref
noamcohen97 Jul 28, 2022
432d274
fix doc whitespace
noamcohen97 Jul 28, 2022
afa9a00
Merge remote-tracking branch 'upstream/main' into namespaces
noamcohen97 Jul 28, 2022
54c7bce
Merge remote-tracking branch 'upstream/main' into namespaces
noamcohen97 Jul 28, 2022
01713ec
regen posixmodule
noamcohen97 Jul 28, 2022
a6bb345
add name to `Misc/ACKS`
noamcohen97 Jul 28, 2022
1c0fb83
Merge remote-tracking branch 'upstream/main' into namespaces
noamcohen97 Aug 17, 2022
dac402a
fix doc availability
noamcohen97 Aug 17, 2022
ff7f961
regen global strings
noamcohen97 Aug 17, 2022
cc44f01
Merge remote-tracking branch 'upstream/main' into namespaces
noamcohen97 Oct 7, 2022
58bc8a6
Merge branch 'main' into namespaces
noamcohen97 Oct 7, 2022
b14396e
Merge remote-tracking branch 'upstream/main' into namespaces
noamcohen97 Oct 7, 2022
50c4809
Merge branch 'main' into namespaces
noamcohen97 Oct 14, 2022
de7dd3d
do not use stdout for test
noamcohen97 Oct 17, 2022
5c1bbdd
move all test login to subprocess
noamcohen97 Oct 19, 2022
29129d9
Update Lib/test/test_posix.py
noamcohen97 Oct 20, 2022
94883a4
add comments to tests
noamcohen97 Oct 20, 2022
3e365d2
bugfix in test while handling `ENOSPC`
noamcohen97 Oct 20, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
reformat doc
  • Loading branch information
noamcohen97 committed Jul 26, 2022
commit 138683342360830bd6b535caf2332d57fb2af204
7 changes: 4 additions & 3 deletions Doc/library/os.rst
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ process and user.
subject to any constraints imposed by the *nstype*, which is
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
a bit mask specified by combining one or more of the ``CLONE_NEW*`` constants
using ``|`` (bitwise or).
the caller's memberships in unspecified namespaces are left unchanged.
The callers memberships in unspecified namespaces are left unchanged.
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
*fd* can be any object with a :meth:`fileno` method, or a raw file descriptor.
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated

This example reassociates the thread with the ``init`` process' network namespace::
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
Expand Down Expand Up @@ -760,7 +760,8 @@ process and user.
.. function:: unshare(flags)

Disassociate parts of the process execution context.
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
The *flags* argument is a bit mask combining zero or more of the ``CLONE_*`` constants using ``|`` (bitwise or), that specifies which parts of the execution
The *flags* argument is a bit mask combining zero or more of the ``CLONE_*``
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
constants using ``|`` (bitwise or), that specifies which parts of the execution
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
context should be unshared.
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
If *flags* is specified as zero, no changes are made to the calling process'
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated
execution context.
Expand All @@ -777,6 +778,7 @@ Flags to the :func:`unshare` function, if the implementation supports them.
See the Linux manual for the exact effect and availability.
Comment thread
noamcohen97 marked this conversation as resolved.
Outdated

.. data:: CLONE_FILES
CLONE_FS
CLONE_NEWCGROUP
CLONE_NEWIPC
CLONE_NEWNET
Expand All @@ -789,7 +791,6 @@ See the Linux manual for the exact effect and availability.
CLONE_SYSVSEM
CLONE_THREAD
CLONE_VM
CLONE_FS

.. _os-newstreams:
Comment thread
noamcohen97 marked this conversation as resolved.

Expand Down