Compare commits
3 commits
4ed2b7826a
...
948c9a5d8d
Author | SHA1 | Date | |
---|---|---|---|
|
948c9a5d8d | ||
|
182ece622e | ||
|
cfa432c4ce |
5 changed files with 11 additions and 10 deletions
|
@ -37,6 +37,7 @@ templates:
|
|||
- "/etc/sysctl.d/congestion.conf"
|
||||
- "/etc/sysctl.d/coredump.conf"
|
||||
- "/etc/docker/daemon.json"
|
||||
- "/etc/ntp.conf"
|
||||
services:
|
||||
- runlevel: "sysinit"
|
||||
service: "devfs"
|
||||
|
|
|
@ -1,4 +1,8 @@
|
|||
---
|
||||
- name: "Create directories."
|
||||
file:
|
||||
state: "directory"
|
||||
path: "/mnt/etc/docker"
|
||||
- name: "Install configuration files."
|
||||
template:
|
||||
src: "templates{{ item }}.j2"
|
||||
|
|
|
@ -5,14 +5,12 @@ iface lo inet loopback
|
|||
auto eth0
|
||||
|
||||
iface eth0 inet static
|
||||
address {{ hostvars[inventory_hostname].ansible_default_ipv4.address }}
|
||||
netmask {{ hostvars[inventory_hostname].ansible_default_ipv4.netmask }}
|
||||
gateway {{ hostvars[inventory_hostname].ansible_default_ipv4.gateway }}
|
||||
address {{ ansible_host }}/{{ netmask }}
|
||||
gateway {{ gateway }}
|
||||
|
||||
{% if ip6 is defined %}
|
||||
iface eth0 inet6 static
|
||||
address {{ ip6 }}
|
||||
netmask {{ netmask6 }}
|
||||
address {{ ip6 }}/{{ netmask6 }}
|
||||
gateway {{ gateway6 }}
|
||||
pre-up echo 0 > /proc/sys/net/ipv6/conf/eth0/accept_ra
|
||||
{% endif %}
|
||||
|
|
|
@ -1,5 +0,0 @@
|
|||
pool pool.ntp.org
|
||||
driftfile /var/lib/ntp/ntp.drift
|
||||
restrict default kod limited nomodify nopeer noquery
|
||||
restrict 127.0.0.1
|
||||
restrict ::1
|
3
templates/etc/ntp.conf.j2
Normal file
3
templates/etc/ntp.conf.j2
Normal file
|
@ -0,0 +1,3 @@
|
|||
# https://gist.github.com/jauderho/2ad0d441760fc5ed69d8d4e2d6b35f8d
|
||||
server time.cloudflare.com nts iburst
|
||||
driftfile /var/lib/ntp/ntp.drift
|
Loading…
Reference in a new issue