1Test 1-10 - Docker PS
2=======
3
4# Purpose:
5To verify that docker ps command is supported by VIC appliance
6
7# References:
8[1 - Docker Command Line Reference](https://docs.docker.com/engine/reference/commandline/ps/)
9
10# Environment:
11This test requires that a vSphere server is running and available
12
13# Test Steps:
141. Deploy VIC appliance to vSphere server
152. Issue docker ps
163. Issue docker create busybox /bin/top
174. Issue docker start <containerID>
185. Issue docker create busybox ls
196. Issue docker start <containerID>
207. Issue docker create busybox dmesg
218. Issue docker ps
229. Issue docker ps -a
2310. Issue docker create --name jojo busybox /bin/top
2411. PowerOn container jojo-* out of band via govc
2512. Issue docker ps -q
2613. Issue docker create --name koko busybox /bin/top
2714. Issue docker start koko
2815. Issue docker ps -q
2916. PowerOff container koko* out of band via govc
3017. Issue docker ps -q
3118. Issue docker create -p 8000:80 -p 8443:443 nginx
3219. Issue docker ps -a
3320. Issue docker run -d -p 6379 redis:alpine
3421. Issue docker ps
3522. Issue docker create --name lolo busybox /bin/top
3623. Issue docker start lolo
3724. Issue docker stop lolo
3825. Issue docker ps -aq
3926. Destroy container lolo* out of band via govc
4027. Issue docker ps -aq
4128. Issue docker ps -l
4229. Issue docker ps -n=2
4330. Issue docker ps -ls
4431. Issue docker ps -aq
4532. Create 3 containers
4633. Issue docker ps -aq
4734. Issue docker ps -f status=created
4835. Issue docker create --name abe --label prod busybox /bin/top
4936. Issue docker ps -a -f label=prod
5037. Issue docker ps -a -f name=abe
5138. Issue docker create -v foo:/dir --name fooContainer busybox
5239. Issue docker ps -a -f volume=foo
5340. Issue docker ps -a -f volume=foo -f volume=bar
5441. Issue docker ps -a -f volume=fo
5542. Issue docker network create fooNet
5643. Issue docker create --net=fooNet --name fooNetContainer busybox
5744. Issue docker ps -a -f network=fooNet
5845. Issue docker ps -a -f network=fooNet -f network=barNet
5946. Issue docker ps -a -f network=fo
6047. Issue docker ps -a -f volume=foo -f network=bar
6148. Issue docker ps -a -f network=bar -f volume=foo
6249. Issue docker ps -a -f volume=foo -f volume=buz -f network=bar
6350. Issue docker create -v buz:/dir --net=fooNet --name buzFooContainer busybox
6451. Issue docker ps -a -f volume=buz -f network=fooNet
65
66# Expected Outcome:
67* Steps 2-13 should all return without error
68* Step 2 should return with only the printed ps command header and no containers
69* Step 8 should return with only the information for the /bin/top container
70* Step 9 should return with the information for all 3 containers
71* Step 10-11 should return without error
72* Step 12 should include jojo-* containerVM
73* Steps 13-16 should return without error
74* Step 17 should not include koko and have one less container than in Step 15
75* Step 18 should return without error
76* Step 19 should include the port-mappings of Step 18's container
77* Step 20 should return without error
78* Step 21 should include the port-mappings of Step 20's container
79* Steps 22-25 should return without errors
80* Step 26 should succeed on ESXi and fail on vCenter with the error:
81```
82govc: ServerFaultCode: The method is disabled by 'VIC'
83```
84* Step 27 should include one less container than in Step 25
85* Step 28 should include only redis
86* Step 29 should include only redis and nginx
87* Step 30 should include only redis with SIZE present
88* Steps 31-32 should return with error
89* Step 33 should include 3 more containers than in Step 31
90* Step 34 should include 4 created containers
91* Step 35 should return without error
92* Step 36 should include only abe
93* Step 37 should include only abe
94* Step 38 should return without error
95* Step 39 should include only fooContainer
96* Step 40 should include only fooContainer
97* Step 41 should not include any containers
98* Steps 42-43 should return without error
99* Step 44 should include only fooNetContainer
100* Step 45 should include only fooNetContainer
101* Step 46 should not include any containers
102* Steps 47-49 should not include any containers
103* Step 50 should return without error
104* Step 51 should include only buzFooContainer
105
106# Possible Problems:
107None
108