Monthly Archives: March 2018

neverware cloudready chrome os chromium os

neverware cloudready chrome os chromium os

Oracle Unbreakable Enterprise Kernel Release 4

Oracle Unbreakable Enterprise Kernel Release 4 (kernel-uek-4.1.12-112.16.4.x) is now available for Oracle Linux 6 and Oracle Linux 7

docker stats and docker top

to use docker stats and docker top get container ids from docker container list or docker ps

$ docker ps

CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
375fd90c86a8 laradock_nginx "nginx" About an hour ago Up About an hour 0.0.0.0:80->80/tcp, 0.0.0.0:443->443/tcp laradock_nginx_1
8433057223b9 laradock_php-fpm "docker-php-entrypoi…" About an hour ago Up About an hour 9000/tcp laradock_php-fpm_1
1f708b403022 laradock_workspace "/sbin/my_init" About an hour ago Up About an hour 0.0.0.0:2222->22/tcp laradock_workspace_1

 

docker stats

$ docker stats 375fd90c86a8

 

docker top

$ docker top 375fd90c86a8

 

docker container removal

docker container removal

$ docker container list --all
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
7892a81691c6 docker/ucp "/bin/ucp-tool" 35 minutes ago Exited (0) 35 minutes ago cranky_shannon
ff848049bc55 redmine "/docker-entrypoint.…" About an hour ago Exited (0) About an hour ago inspiring_babbage
fe67ab61abda redmine "/docker-entrypoint.…" About an hour ago Exited (0) About an hour ago cocky_bartik
65a554844970 bitnami/redmine "/app-entrypoint.sh …" About an hour ago Exited (1) About an hour ago upbeat_pare

 

docker rm container

$ docker rm 4c5784e79dd9

docker image removal

docker image deletion and removal

get a list of images

$ docker images --all
REPOSITORY TAG IMAGE ID CREATED SIZE
laradock_nginx latest 687eb3dccec0 23 hours ago 24.4MB
laradock_php-fpm latest 9011ae1a47a5 23 hours ago 414MB
laradock_redis latest a085dd214956 24 hours ago 107MB
laradock_workspace latest 2ea822e3b905 24 hours ago 725MB
osde8info/get-started part-2 05bbc25a892f 27 hours ago 148MB
node alpine 785e257485e7 4 days ago 68.4MB
bitnami/redmine latest e547bec0c9bb 7 days ago 708MB
postgres alpine f4f4231d6f0b 10 days ago 39.5MB

delete a specific image

$ docker image rm f4f4231d6f0b

docker images are kept in /var/lib/docker

docker images are kept in /var/lib/docker

# du -s /var/lib/docker/*
20    /var/lib/docker/builder
220   /var/lib/docker/containerd
884   /var/lib/docker/containers
30028 /var/lib/docker/image
84    /var/lib/docker/network
5876620 /var/lib/docker/overlay2
20    /var/lib/docker/plugins
4     /var/lib/docker/runtimes
4     /var/lib/docker/swarm
4     /var/lib/docker/tmp
4     /var/lib/docker/trust
188   /var/lib/docker/volumes

you can save a lot of space by deleting any unused images and containers

# du -s /var/lib/docker/*
20	/var/lib/docker/builder
220	/var/lib/docker/containerd
4	/var/lib/docker/containers
2888	/var/lib/docker/image
84	/var/lib/docker/network
163380	/var/lib/docker/overlay2
20	/var/lib/docker/plugins
4	/var/lib/docker/runtimes
4	/var/lib/docker/swarm
4	/var/lib/docker/tmp
4	/var/lib/docker/trust
188	/var/lib/docker/volumes

docker compose docker-compose.yaml

docker compose runs all the containers (and dependancies) defined in your docker-compose.yaml file

for example

$ docker-compose up -d nginx

actually runs the nginx, phpfpm and wordspaces because the docker-compose.yaml contains depends on

### NGINX Server Container ##################################

nginx:
 build:
 context: ./nginx
 args:
 - PHP_UPSTREAM_CONTAINER=${NGINX_PHP_UPSTREAM_CONTAINER}
 - PHP_UPSTREAM_PORT=${NGINX_PHP_UPSTREAM_PORT}
 volumes_from:
 - applications
 volumes:
 - ${NGINX_HOST_LOG_PATH}:/var/log/nginx
 - ${NGINX_SITES_PATH}:/etc/nginx/sites-available
 ports:
 - "${NGINX_HOST_HTTP_PORT}:80"
 - "${NGINX_HOST_HTTPS_PORT}:443"
 depends_on:
 - php-fpm
 networks:
 - frontend
 - backend




### PHP-FPM Container #######################################

php-fpm:
 build:
 context: ./php-fpm
 args:
 - INSTALL_XDEBUG=${PHP_FPM_INSTALL_XDEBUG}

expose:
 - "9000"
 depends_on:
 - workspace
 extra_hosts:
 - "dockerhost:${DOCKER_HOST_IP}"
 environment:
 - PHP_IDE_CONFIG=${PHP_IDE_CONFIG}
 networks:
 - backend




### Workspace Utilities Container ###########################

workspace:
 build:
 context: ./workspace
 args:
 - INSTALL_XDEBUG=${WORKSPACE_INSTALL_XDEBUG}
 - INSTALL_BLACKFIRE=${INSTALL_BLACKFIRE}
 - INSTALL_SOAP=${WORKSPACE_INSTALL_SOAP}
 - INSTALL_LDAP=${WORKSPACE_INSTALL_LDAP}
 - INSTALL_IMAP=${WORKSPACE_INSTALL_IMAP}