Containers on demand
A method includes receiving, from a client device, a request to initiate an action on a target system. The method further includes determining, in view of a container registry, that the action is permissive. The method further includes receiving an authorized container corresponding to the action. The method further includes performing, by a processing device, the action in view of the container.
1. A method, comprising:
determining that a triggering event has occurred within a target system, wherein the triggering event is associated with a first action performed on the target system;
determining a second action associated with the first action, wherein the first action indicates a demand for the second action;
generating, by a system external to the target system, a request to a container registry for a container comprising a service to perform the second action;
determining, in view of the container registry, that the second action is authorized on the target system;
receiving, at the target system, an authorized container corresponding to the second action, wherein the authorized container is selected from a plurality of containers in view of the second action to be performed on the target system and a functionality provided by a service of the authorized container;
running the authorized container on the target system; and
performing, by a processing device, the second action on the target system in view of the functionality provided by the service of the authorized container running on the target system.
2. The method of claim 1 , further comprising sending a request for the authorized container to the container registry.
3. The method of claim 1 , wherein determining that the action is authorized comprises determining that the action is allowed on the target system at a time of the request.
4. The method of claim 1 , wherein the target system is running a minimized image incapable of performing the action without modification.
5. The method of claim 1 , wherein performing the action in view of the container comprises:
establishing a connection from the authorized container to the client device;
executing the action;
removing the connection; and
discarding the authorized container.
6. The method of claim 1 , wherein the action corresponds to at least one of:
logging into the target system using a secure shell (SSH) protocol; or
collecting a metric of the target system using a port control protocol (PCP).
7. The method of claim 1 , wherein the action corresponds to at least one of:
viewing a configuration of the target system; or
troubleshooting the target system.
8. A system, comprising:
a memory to store a container registry; and
a processing device operatively coupled to the memory, the processing device to:
determine that a triggering event has occurred within a target system, wherein the triggering event is associated with a first action performed on the target system;
determine a second action associated with the first action, wherein the first action indicates a demand for the second action;
generate, by a system external to the target system, a request to a container registry for a container comprising a service to perform the second action;
determine, in view of the container registry, that the second action is authorized on the target system;
receive, at the target system, an authorized container corresponding to the second action, wherein the authorized container is selected from a plurality of containers in view of the second action to be performed on the target system and a functionality provided by a service of the authorized container;
run the authorized container on the target system; and
perform the second action on the target system in view of the functionality provided by the service of the authorized container running on the target system.
9. The system of claim 8 , the processing device further to send a request for the authorized container to the container registry, in response to the determining.
10. The system of claim 8 , wherein to determine that the action is authorized the processing device further to determine that the action is allowed on the target system at a time of the request.
11. The system of claim 8 , wherein the target system is running a minimized image incapable of performing the action without modification.
12. The system of claim 8 , wherein to perform the action in view of the container the processing device further to:
establish a connection from the authorized container to the client device;
execute the action;
remove the connection; and
discard the authorized container.
13. The system of claim 8 , wherein the action corresponds to at least one of:
logging into the target system using a secure shell (SSH) protocol; or
collecting a metric of the target system using a port control protocol (PCP).
14. The system of claim 8 , wherein the action corresponds to at least one of:
viewing a configuration of the target system; or
troubleshooting the target system.
15. A non-transitory computer-readable storage medium including instructions that, when executed by a processing device, cause the processing device to
determine that a triggering event has occurred within a target system, wherein the triggering event is associated with a first action performed on the target system;
determine a second action associated with the first action, wherein the first action indicates a demand for the second action;
generate, by a system external to the target system, a request to a container registry for a container comprising a service to perform the second action;
determine, in view of the container registry, that the second action is authorized on the target system;
receive, at the target system, an authorized container corresponding to the second action, wherein the authorized container is selected from a plurality of containers in view of the second action to be performed on the target system and a functionality provided by a service of the authorized container;
run the authorized container on the target system; and
perform, by the processing device, the second action on the target system in view of the functionality provided by the service of the authorized container running on the target system.
16. The non-transitory computer-readable storage medium of claim 15 , the processing device further to send a request for the authorized container to the container registry.
17. The non-transitory computer-readable storage medium of claim 15 , wherein to determine that the action is authorized the processing device further to determine that the action is allowed on the target system at a time of the request.
18. The non-transitory computer-readable storage medium of claim 15 , wherein the target system is running a minimized image incapable of performing the action without modification.
19. The non-transitory computer-readable storage medium of claim 15 , wherein to perform the action in view of the container the processing device further to:
establish a connection from the authorized container to the client device;
execute the action;
remove the connection; and
discard the authorized container.
20. The non-transitory computer-readable storage medium of claim 15 , wherein the action corresponds to at least one of:
logging into the target system using a secure shell (SSH) protocol;
collecting a metric of the target system using a port control protocol (PCP);
viewing a configuration of the target system; or
troubleshooting the target system.