Skip to content

Commit 759f120

Browse files
committed
docs, net, service-objects: Add a section for Service lifecycle
In v1.9 `virtctl expose` adds a `ownerReference` to the Service object and binds it to the VM/VMI object. Allowing proper cleanup of Services and avoiding orphan services. Signed-off-by: Edward Haas <edwardh@redhat.com>
1 parent e4a968e commit 759f120

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

docs/network/service_objects.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,3 +178,15 @@ Use `vinagre` client to connect your VirtualMachineInstance by using the
178178
public IP and port.
179179

180180
Note that here the external port here (31829) was dynamically allocated.
181+
182+
## Service lifecycle
183+
184+
Service objects may be created explicitly by an user or implicitly
185+
through the `virtctl expose` command.
186+
187+
While creating the service explicitly, it is up to the user to explicitly
188+
cleanup the service.
189+
From v1.9 the implicit service creation through `virtctl expose` adds an
190+
`ownerRefernce` to the service object, binding the service to the VM/VMI.
191+
As a result, the service will be collected by the garbage-collector once
192+
the referenced object (e.g. VMI) is deleted.

0 commit comments

Comments
 (0)