03bd7f728ed8605210c93fec739c612972484e8c |
|
05-Jan-2017 |
Po-Hsu Lin <po-hsu.lin@canonical.com> |
python3-lxc: fix api_test.py on s390x
The api_test.py script uses Trusty release by default, which does not
have s390x image. Switch to Xenial to solve this.
Signed-off-by: Po-Hsu Lin <po-hsu.lin@canonical.com> |
51ee3c5891d7e95247adb6b605a2e3ab591dc449 |
|
26-Oct-2016 |
Evgeni Golov <evgeni@debian.org> |
mark the python examples as having utf-8 encoding
this allows running them also under Python2, which otherwise
would choke on Stéphane's name and error out with
SyntaxError: Non-ASCII character '\xc3' in file …
Signed-off-by: Evgeni Golov <evgeni@debian.org> |
e2f91e3434ddf2d4cb85d2385057a492eb462166 |
|
10-Nov-2015 |
Fox Wilson <2016fwilson@babbage.csl.tjhsst.edu> |
Use /usr/bin/env python3 instead of /usr/bin/python3 project-wide
This fixes invocations of certain commands when python3 is installed in
a nonstandard path (/usr/local/bin, for example).
Signed-off-by: Fox Wilson <2016fwilson@tjhsst.edu> |
4e31246a25d29db0c554ae2f6b34fc19b8fcdefd |
|
09-Jun-2014 |
Stéphane Graber <stgraber@ubuntu.com> |
python3: Fix crashes in snapshot()
This makes sure all PyObject structs are always initialized to NULL,
this will fix issues such as (issue #239).
Also add a snapshot/list/restore testcase to the python3 api test code.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
0b648faeca47475682679caa750c224e6a5d7cff |
|
07-May-2014 |
Dwight Engen <dwight.engen@oracle.com> |
python3: remove assert since hwaddr isn't set by the download template
Signed-off-by: Dwight Engen <dwight.engen@oracle.com>
Acked-by: Stéphane Graber <stgraber@ubuntu.com> |
cd063f4524ce16ad3de1820780f1b5763de43f5d |
|
13-Feb-2014 |
Stéphane Graber <stgraber@ubuntu.com> |
python3: Update apitest
This update will make it work unprivileged as well as testing a few of
the new functions.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
c756a6e91b6d6da2ff8a21b5a4ece26b05b99283 |
|
13-Feb-2014 |
Stéphane Graber <stgraber@ubuntu.com> |
python3: Drop API warning and fix pep8/pyflakes3
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
0464b881e68ef5f50bd7bb9633b70e2e89be039b |
|
31-Jan-2014 |
Stéphane Graber <stgraber@ubuntu.com> |
shutdown: Rework API and lxc-stop
With this change, shutdown() will no longer call stop() after the
timeout, instead it'll just return false and it's up to the caller to
then call stop() if appropriate.
This also updates the bindings, tests and other scripts.
lxc-stop is then updated to do proper option checking and use shutdown,
stop or reboot as appropriate.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
e6c6d62287d4259cff223313eef3b7c5b03e2a1b |
|
24-Jan-2014 |
Stéphane Graber <stgraber@ubuntu.com> |
tests: Fix python3 API test
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com> |
2edd7a881d7d6b94c13d18c28ce6a6a15966ed31 |
|
03-Dec-2013 |
Stéphane Graber <stgraber@ubuntu.com> |
python3: Fix PEP8 and avoid crash when listing
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com> |
f10e04e36170dbd0faae3a667d53f0af1ef6a13a |
|
16-Oct-2013 |
Stéphane Graber <stgraber@ubuntu.com> |
Make 'make dist' match git content
This fixes a few obvious issues when comparing the make dist output with
the git tree.
- Make all templates non-executable in git
- Remove unused files:
- src/lxc/list.c (empty, only includes the list.h header)
- src/lxc/lxc-destroy.in (replace by lxc_destroy.c)
- Add missing files to dist tarball:
- src/python-lxc/examples/pyconsole.py
- src/python-lxc/examples/pyconsole-vte.py
- Mark all the python API tests executable
- Mark lxc-test-ubuntu executable
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com> |
799f29ab699f08e67231b012f20a25e23a6c391d |
|
18-Sep-2013 |
S.Çağlar Onur < <caglar@10ur.org> |
Add get_interfaces to the API
get_ips accepts an interface name as a parameter but there was no
way to get the interfaces names from the container. This patch
introduces a new get_interfaces call to the API so that users
can obtain the name of the interfaces.
Support for python bindings also introduced as a part of this version.
Signed-off-by: S.Çağlar Onur <caglar@10ur.org>
Acked-by: Stéphane Graber <stgraber@ubuntu.com> |
250b1eec71b074acdff1c5f6b5a1f0d7d2c20b77 |
|
03-Sep-2013 |
Stéphane Graber <stgraber@ubuntu.com> |
licensing: Add missing headers and FSF address
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com> |
ca9548ad02238600899a1f86ded308279964e018 |
|
03-Sep-2013 |
Stéphane Graber <stgraber@ubuntu.com> |
python: Fix api_test to use the new attach() API
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
9c83a661397456e1455d739bcadfa38f05ce2fe6 |
|
21-May-2013 |
Stéphane Graber <stgraber@ubuntu.com> |
lxcapi: Add new get_ips() call
This adds a new get_ips call which takes a family (inet, inet6 or NULL),
a network interface (or NULL for all) and a scope (0 for global) and returns
a char** of all the IPs in the container.
This also adds a matching python3 binding (function result is a tuple) and
deprecates the previous pure-python get_ips() implementation.
WARNING: The python get_ips() call is quite different from the previous
implementation. The timeout argument has been removed, the family names are
slightly different (inet/inet6 vs ipv4/ipv6) and an extra scope parameter
has been added.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
1cb4260d10df377deb64f4d2a5fc188890b01e66 |
|
01-Mar-2013 |
Stéphane Graber <stgraber@ubuntu.com> |
python api_test: Drop use of @LXCPATH@
The python api test script was using @LXCPATH@ for one of its checks.
Now that the lxcpath is exposed by the lxc python module directly, this
can be dropped and api_test.py can now become a simple python file without
needing pre-processing by autoconf.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
bde1853954e7e0a33fec872391c757933c063ae9 |
|
26-Nov-2012 |
Stéphane Graber <stgraber@ubuntu.com> |
python: PEP8 compatibility
The new version of the pep8 command is detecting more indentation
mistakes than it used to, this fixes them.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com> |
5a339bbb87e06cb4687056e07985eeb6bafef002 |
|
12-Nov-2012 |
Stéphane Graber <stgraber@ubuntu.com> |
api_test.py: Remove workarounds for API bugs
The script used to contain a workaround for back when create()
wouldn't properly flush the config and reload it.
As these issues have now been fixed, these workarounds can be removed.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com> |
e0de36d791e82d9916cad4ac41562077cf9789c3 |
|
12-Nov-2012 |
Stéphane Graber <stgraber@ubuntu.com> |
Add better example/test of the python3-lxc API
Replaced python-lxc/test.py by a new api_test.py script that
uses all the available function of the API to run a batch of
basic tests.
This example is useful both as a test of the API and as a guide on
how to use the python API to manage containers.
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com> |