OpenShift CI/CD Concepts TODEPLETE: Difference between revisions
Jump to navigation
Jump to search
Line 3: | Line 3: | ||
=Container= | =Container= | ||
* [[#Privileged_Container|Privileged container]]. | * [[#Privileged_Container|Privileged container]]. | ||
* Any output directed to stdout in a running container is captured in a log file that can be viewed with [[docker logs]] command. | * Any output directed to stdout in a running container is captured in a log file that can be viewed with [[docker logs]] command. |
Revision as of 06:01, 5 December 2017
tmp
Container
- Privileged container.
- Any output directed to stdout in a running container is captured in a log file that can be viewed with docker logs command.
- Containers are ephemeral. Any in-memory state is lost when the container stops. When a container is deleted, any data written to the container’s file system is deleted as well.
Restart Policy
The container's restart policy specifies how container are restarted when the docker server is restarted. It is maintained in /var/lib/docker/containers/<container-id>/hostconfig.json as:
{ ... "RestartPolicy":{"Name":"no","MaximumRetryCount":0}, ... }
Note that the json file must not be edited directly. If the restart policy has to be changed, that must be done with docker update.
The policy for a specific container can be retrieved with docker inspect.
Also see
.dockerignore
Contains files and directories that won't be uploaded to the docker host when the image is built.