Skip to content
Snippets Groups Projects
Commit 4fc2cc6c authored by hofmann's avatar hofmann :speech_balloon:
Browse files

add journald logging

parent 5c603319
Branches
Tags
Loading
......@@ -2,7 +2,7 @@
- name: Uninstall old docker version
ansible.builtin.apt:
name: ['docker', 'docker-engine', 'docker.io', 'containered', 'runc']
state: absent
state: absent
- name: Set up the repository for Docker
ansible.builtin.apt:
......@@ -22,7 +22,7 @@
url: 'https://download.docker.com/linux/debian/gpg'
keyring: '/usr/share/keyrings/docker-archive-keyring.gpg'
- name: set up the stable Docker repository
- name: Set up the stable Docker repository
ansible.builtin.apt_repository:
repo: 'deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian {{ ansible_lsb.codename }} stable'
......@@ -30,3 +30,10 @@
ansible.builtin.apt:
name: ['docker-ce', 'docker-ce-cli', 'containerd.io', 'docker-compose']
state: present
- name: Configure docker logging
ansible.builtin.template:
src: "daemon.json"
dest: "/etc/docker/daemon.json"
mode: "0644"
notify: restart docker
{
"log-driver": "journald"
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment