Configure hostnames
oh boy here we go
This commit is contained in:
parent
8ea69fd3b4
commit
3d91b4d752
@ -21,6 +21,16 @@
|
||||
- openssh-server
|
||||
- python3-apt
|
||||
- vim
|
||||
- name: Copy system configs
|
||||
template:
|
||||
src: "{{ item.src }}"
|
||||
dest: "{{ item.dest }}"
|
||||
mode: "{{ item.mode }}"
|
||||
loop:
|
||||
- { src: "hosts", dest: "/etc/hosts", mode: "0644" }
|
||||
- name: Set hostname
|
||||
hostname:
|
||||
name: "{{ inventory_hostname }}"
|
||||
- name: Set timezone
|
||||
timezone:
|
||||
name: "America/Chicago"
|
||||
@ -49,4 +59,6 @@
|
||||
- "97-overlayroot"
|
||||
- name: Configure Ansible user
|
||||
include_tasks: ansibleuser.yml
|
||||
- name: Configure hostname
|
||||
include_tasks: hostname.yml
|
||||
become: yes
|
||||
|
10
roles/common/templates/hosts
Normal file
10
roles/common/templates/hosts
Normal file
@ -0,0 +1,10 @@
|
||||
127.0.0.1 localhost
|
||||
127.0.0.1 {{ ansible_facts['nodename'] }}
|
||||
|
||||
# The following lines are desirable for IPv6 capable hosts
|
||||
::1 localhost ip6-localhost ip6-loopback
|
||||
fe00::0 ip6-localnet
|
||||
ff00::0 ip6-mcastprefix
|
||||
ff02::1 ip6-allnodes
|
||||
ff02::2 ip6-allrouters
|
||||
ff02::3 ip6-allhosts
|
@ -23,7 +23,6 @@
|
||||
dest: "{{ item.dest }}"
|
||||
mode: "{{ item.mode }}"
|
||||
loop:
|
||||
- { src: "hosts", dest: "/etc/hosts", mode: "0644" }
|
||||
- { src: "sshd_config", dest: "/etc/ssh/sshd_config", mode: "0644" }
|
||||
- { src: "nomouseaccel.conf", dest: "/etc/X11/xorg.conf.d/90-mouse-acceleration.conf", mode: "0644" }
|
||||
- { src: "i3.desktop", dest: "/usr/share/xsessions/i3-custom.desktop", mode: "0644" }
|
||||
|
@ -1,48 +0,0 @@
|
||||
127.0.0.1 localhost
|
||||
127.0.0.1 {{ ansible_facts['nodename'] }}
|
||||
|
||||
# Fuck off, Spotify
|
||||
#0.0.0.0 adclick.g.doublecklick.net
|
||||
#0.0.0.0 adeventtracker.spotify.com
|
||||
#0.0.0.0 ads-fa.spotify.com
|
||||
#0.0.0.0 analytics.spotify.com
|
||||
#0.0.0.0 audio2.spotify.com
|
||||
#0.0.0.0 b.scorecardresearch.com
|
||||
#0.0.0.0 bounceexchange.com
|
||||
#0.0.0.0 bs.serving-sys.com
|
||||
#0.0.0.0 content.bitsontherun.com
|
||||
#0.0.0.0 core.insightexpressai.com
|
||||
#0.0.0.0 crashdump.spotify.com
|
||||
#0.0.0.0 d2gi7ultltnc2u.cloudfront.net
|
||||
#0.0.0.0 d3rt1990lpmkn.cloudfront.net
|
||||
#0.0.0.0 desktop.spotify.com
|
||||
#0.0.0.0 doubleclick.net
|
||||
#0.0.0.0 ds.serving-sys.com
|
||||
#0.0.0.0 googleadservices.com
|
||||
#0.0.0.0 googleads.g.doubleclick.net
|
||||
#0.0.0.0 gtssl2-ocsp.geotrust.com
|
||||
#0.0.0.0 js.moatads.com
|
||||
#0.0.0.0 log.spotify.com
|
||||
#0.0.0.0 media-match.com
|
||||
#0.0.0.0 omaze.com
|
||||
#0.0.0.0 open.spotify.com
|
||||
#0.0.0.0 pagead46.l.doubleclick.net
|
||||
#0.0.0.0 pagead2.googlesyndication.com
|
||||
#0.0.0.0 partner.googleadservices.com
|
||||
#0.0.0.0 pubads.g.doubleclick.net
|
||||
#0.0.0.0 redirector.gvt1.com
|
||||
#0.0.0.0 s0.2mdn.net
|
||||
#0.0.0.0 securepubads.g.doubleclick.net
|
||||
#0.0.0.0 spclient.wg.spotify.com
|
||||
#0.0.0.0 tpc.googlesyndication.com
|
||||
#0.0.0.0 v.jwpcdn.com
|
||||
#0.0.0.0 video-ad-stats.googlesyndication.com
|
||||
#0.0.0.0 weblb-wg.gslb.spotify.com
|
||||
#0.0.0.0 www.googleadservices.com
|
||||
#0.0.0.0 www.googletagservices.com
|
||||
#0.0.0.0 www.omaze.com
|
||||
|
||||
# The following lines are desirable for IPv6 capable hosts
|
||||
::1 localhost ip6-localhost ip6-loopback
|
||||
ff02::1 ip6-allnodes
|
||||
ff02::2 ip6-allrouters
|
Loading…
Reference in New Issue
Block a user