782 Commits

Author SHA1 Message Date
Jenkins
937d6df5df Merge "Implement kuryr integration" 2017-04-24 07:08:48 +00:00
Jenkins
fc57735213 Merge "Remove unused CONF" 2017-04-24 05:40:24 +00:00
Feng Shengqin
9fc95d00fb Remove unused CONF
Change-Id: Icf8e6c6db7b5d570bb454e0a7ee2bfa81b57b037
2017-04-21 15:10:06 +08:00
Feng Shengqin
577c4f6636 Combine tty and stdin_open in server
Change-Id: I7d4f85d714e744709687e402f585696e6f79aa62
Closes-Bug: #1683951
2017-04-21 12:30:36 +08:00
Jenkins
80323e1ca6 Merge "Remove unused LOG" 2017-04-20 19:03:31 +00:00
Jenkins
ace9840ee1 Merge "Avoid running multiple etcd process" 2017-04-20 11:38:44 +00:00
Feng Shengqin
bc6224b7d6 Remove unused LOG
Removing unused LOG to keep code clean.

Change-Id: I87dd983882dcaff577c7a762d492e1b7baddfd79
2017-04-20 14:51:33 +08:00
Jenkins
5fb47583a0 Merge "Add container number info to compute node." 2017-04-20 03:31:57 +00:00
Jenkins
5efbc0d35a Merge "Drop duplicated exception handle code from docker driver" 2017-04-20 03:31:52 +00:00
Hongbin Lu
fc6ac8d177 Avoid running multiple etcd process
If both Zun and Kuryr-libnetwork are enabled in devstack, the script
might fail since etcd will be installed and started twice. This commit
fixed it.

Change-Id: Ieffbb7a86e99a3e9a03cbfcadb2daf92d8f62cfb
2017-04-19 23:47:43 +00:00
Hongbin Lu
c5a979864e Implement kuryr integration
After this patch, all containers created by native docker driver
will connect to neutron. Right now, users don't have a choice of
networks the container will be created from (which is a future
work). Instead, Zun will select a neutron network for each
container by looking up all the networks under user's tenant.

This is the first step for enabling Kuryr integration. The following
work needs to be done later:
* Expose network feature via REST API. Allow users to create, inspect,
  delete container network, and connect/disconnect container from/to
  a network.
* Add support for associate/dissociate floating IPs to containers.
* Add support for tuning security groups of the containers.

Implements: blueprint kuryr-integration
Change-Id: I2701eb9a82a74aedf00c1a2af29850d4bd0e8f7a
2017-04-19 22:10:09 +00:00
Madhuri Kumari
f7875709e1 Update the create and start with run command in doc
Change-Id: I9bf292c9f7d44bed1721dee95e761be47a876c36
2017-04-19 11:10:33 +00:00
Feng Shengqin
7695b17754 Drop duplicated exception handle code from docker driver
Due to docker.errors.APIError is wrapped at DockerHTTPClient,
duplicated exception handle code from docker driver can be removed.

Change-Id: I3accc317cc8a79741934098d853e7749a0f59844
2017-04-19 17:19:30 +08:00
ShunliZhou
7cffe6db39 Add container number info to compute node.
Add total, running, paused, stopped container numbers to compute
node.

Change-Id: I8f40fac022814dc6f44901699295faac080d4825
Partially-Implements: blueprint expose-host-capabilities
2017-04-19 16:25:07 +08:00
Jenkins
cf11246e01 Merge "Make ETCD's port configurable in devstack" 2017-04-19 05:52:20 +00:00
Hongbin Lu
b4fc4e3ea1 Make ETCD's port configurable in devstack
Change-Id: I1e75f6e942cf6bd95b0604fc5944c40514d9052d
2017-04-18 18:18:17 -04:00
Feng Shengqin
4e56268ccb Remove pause and unpause in utils.py
Change-Id: Ia893b71336fea077e06c5bf24d058a7daddcf802
2017-04-18 17:36:27 +08:00
Jenkins
fe2492e67a Merge "IntegrityError: (1048, u"Column 'mem_total' cannot be null")" 2017-04-18 07:47:12 +00:00
Feng Shengqin
4e5e5e90b0 IntegrityError: (1048, u"Column 'mem_total' cannot be null")
Change-Id: I19f36c240f1456d5fab31167d5acfb3d38c3dfa3
Closes-Bug: #1683282
2017-04-18 09:02:56 +08:00
Jenkins
8c36b723ba Merge "Add unit test for meminfo for docker driver" 2017-04-17 23:44:47 +00:00
Jenkins
aebef93ef9 Merge "Allow host of docker daemon to be configurable" 2017-04-17 06:21:49 +00:00
Jenkins
ada3a228f6 Merge "Fixing for consistent code" 2017-04-17 06:21:43 +00:00
Jenkins
9b3e841ac2 Merge "Sync container's host in periodic task" 2017-04-17 06:11:57 +00:00
ShunliZhou
4556bb3946 Add unit test for meminfo for docker driver
Add meminfo patch changed docker_driver.get_available_resources,
but forget to add ut for get_available_resources. Add test case
in this patch.

Change-Id: Ia5f3af75f82026e5f959863f33d4654f5cb5ba32
2017-04-17 13:31:03 +08:00
Jenkins
df6960bd36 Merge "Add memory info to compute node." 2017-04-15 09:10:37 +00:00
ShunliZhou
459ee5f4e8 Add memory info to compute node.
Add memory total, memory free, memory available to compute node.

Change-Id: I0cadc8acfb618e74ac4f0c2a49b7ed153c9b3af9
Partially-Implements: blueprint expose-host-capabilities
2017-04-15 09:24:10 +08:00
Hongbin Lu
dd5e21858d Sync container's host in periodic task
The container's host needs to be synced periodically because the
value of the host is mutable (in config file). If the value of
a host is changed but it is not synced to containers, the rpc
request will send to the old host which will fail.

In order to squeeze the logic of syncing host, the existing
periodic task was re-written because the original task was mainly
designed to sync a single container state (i.e. status). This
commit re-wrote the implementation make it generic and can be
leveraged to sync various container states (i.e. host, status).

In addition, this commit moved the implementation to container
driver since syncing container states seems to be driver-specific.

Change-Id: I998af06989363b5329ae1f853dd01388ddaeb1cc
2017-04-14 21:23:56 -04:00
Jenkins
ffbad00b50 Merge "The status_reason always exists" 2017-04-14 16:32:52 +00:00
Jenkins
184d70a1c5 Merge "Return docker url as well on interactive mode" 2017-04-14 15:17:38 +00:00
Jenkins
481029d180 Merge "Allow start/restart container in Error state" 2017-04-14 10:09:45 +00:00
Jenkins
a60bbf13c5 Merge "Fix the logic to set container state to Error" 2017-04-14 10:06:18 +00:00
Feng Shengqin
296f98c545 The status_reason always exists
The error info is deleted when the container start or reboot,
but status_reason always exists after the container runs well.

Change-Id: I9772aea1e7a4772d0b1b20a0caf8381b25296443
Closes-Bug: #1682032
2017-04-14 11:14:46 +08:00
Jenkins
0e6257ed9e Merge "Developer Quick-Start - Need modification" 2017-04-14 03:09:08 +00:00
Hongbin Lu
19a0879868 Allow start/restart container in Error state
This allows the container to be recovered by a restart

Change-Id: I29ead99abe9cf05573f1142715cd7c36e7ca4f86
2017-04-13 21:14:39 -04:00
Hongbin Lu
a35a93d814 Fix the logic to set container state to Error
According to https://docs.docker.com/engine/api/v1.23/ , the 'Error'
field returned by 'inspect' is a string, but we treated it as
boolean in before. As a result, the state was incorrect.

Change-Id: If85605ed4931c0c021090cf752f80b5200f08f33
2017-04-13 21:09:50 -04:00
Feng Shengqin
f687b6ebac Developer Quick-Start - Need modification
Change-Id: I51e47fe6e0a91a856498d64e80bb09f668fd36b4
Closes-Bug: #1682025
2017-04-13 05:23:43 +00:00
Hongbin Lu
a083494b6e Allow host of docker daemon to be configurable
An immediate use case is to enable attaching to containers that
are behind the proxy. In this case, the ip address of docker
daemon won't be reachable from outside thus attaching is
impossible. With this config, cloud admins can set a reachable
ip address for external access of docker daemon.

Change-Id: If4981154139c98ad4a8373744d29938214991ca6
2017-04-13 00:01:14 +00:00
OpenStack Proposal Bot
54e74a61c8 Updated from global requirements
Change-Id: I6edbb8192996287163e79ead4d5673b6cec3ac01
2017-04-12 13:43:46 +00:00
Jenkins
00353178cc Merge "Miss 'next' field at list response" 2017-04-12 13:41:43 +00:00
Jenkins
1be726d633 Merge "Replace string with constants" 2017-04-12 13:34:50 +00:00
Jenkins
55f02836c3 Merge "Remove unused compare_version" 2017-04-12 01:58:56 +00:00
Feng Shengqin
b47890589e Miss 'next' field at list response
Change-Id: Id8510fa66e2407404e82cac73fa9843ba067eee5
Closes-Bug: #1681537
2017-04-12 08:40:12 +08:00
Feng Shengqin
b9bd0ea5b1 Fixing for consistent code
Change-Id: I49992260e89df2f12b5028172ab82e95cc8d7886
2017-04-10 16:36:29 +08:00
miaohb
5e5fe1b0d6 Replace string with constants
This patch adds a new file to define constants, and replaces the
string variables with constants.

Change-Id: Ice4aa493c4713264d43a70c3fde2776a01584228
Implements: blueprint replace-string-with-const
2017-04-10 16:11:25 +08:00
himani
2d98b4640f Added 'image_id' field in _basic_keys in images_view.py
Bug introduced in https://review.openstack.org/#/c/420503/
This patch fixes it.

Change-Id: Idf89888f8a33a91badf386cb27afb8ed88d75cd6
Closes-bug: #1679104
2017-04-08 20:10:17 +05:30
Feng Shengqin
87675787f5 Remove unused compare_version
docker.version()['ApiVersion'] in the function
gets error in docker 1.10.6

>>> import docker
>>> docker.version
'1.10.6'
>>>
>>> docker.version()['ApiVersion']
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: 'str' object is not callable

The patch removes compare_version due to
the two functions are unused.

Change-Id: If867394725eca7ee2dd7ed46c21ba4468d756f4a
2017-04-08 14:07:23 +08:00
Jenkins
93c9b81566 Merge "Optimize the link address" 2017-04-08 01:50:17 +00:00
Jenkins
257890f3bc Merge "Get logs of creating container should return 409" 2017-04-08 01:50:11 +00:00
Jenkins
f7ccf369d0 Merge "Remove the redundant context definition" 2017-04-08 01:50:06 +00:00
Jenkins
eb878635ee Merge "Change Cluster to Container in object.rst" 2017-04-08 01:17:41 +00:00