From b0f05334cf000a93421a738f5516aeaf1dd15bfc Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Thu, 18 May 2017 00:54:17 -0500 Subject: [PATCH] Switch to Debian --- Makefile | 4 +- debian.yml | 230 ++++++++++++++++++++++++++++++++ general.yml | 92 +++++++++++++ notes.txt => gnome.sh | 0 setup.yml | 297 ------------------------------------------ 5 files changed, 324 insertions(+), 299 deletions(-) create mode 100644 debian.yml create mode 100644 general.yml rename notes.txt => gnome.sh (100%) delete mode 100644 setup.yml diff --git a/Makefile b/Makefile index 05c44b9..cd7312c 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ apply: - ansible-playbook setup.yml -u root -i "127.0.0.1," + ansible-playbook debian.yml -u root -i "127.0.0.1," init: - ansible-playbook setup.yml -u root -i "127.0.0.1," -k + ansible-playbook debian.yml -u root -i "127.0.0.1," -k diff --git a/debian.yml b/debian.yml new file mode 100644 index 0000000..a0286c7 --- /dev/null +++ b/debian.yml @@ -0,0 +1,230 @@ +- hosts: all + tasks: + - name: Install apt-transport-https + apt: + name: apt-transport-https + state: latest + + # setup repos + #- name: Dropbox Repository Key + # apt_key: + # keyserver: pgp.mit.edu + # id: 1C61A2656FB57B7E4DE0F4C1FC918B335044912E + #- name: Dropbox Repository + # apt_repository: + # repo: deb http://linux.dropbox.com/debian stretch main + # state: present + + - name: "Contrib, Non-free" + apt_repository: + repo: "deb http://ftp.us.debian.org/debian stretch contrib non-free" + state: present + + - name: Chrome Repository Key + apt_key: + url: https://dl-ssl.google.com/linux/linux_signing_key.pub + state: present + - name: Chrome Repository + apt_repository: + repo: "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" + filename: google-chrome + state: present + + - name: Docker Repository Key + apt_key: + url: https://download.docker.com/linux/debian/gpg + state: present + - name: Docker Repository + apt_repository: + repo: "deb [arch=amd64] https://download.docker.com/linux/debian stretch stable" + state: present + + # update system + - name: Update | Update System + apt: + upgrade: dist + update_cache: true + + # install packages + + - name: Install Ansible + apt: + name: ansible + state: latest + + - name: Install bzr + apt: + name: bzr + state: latest + + - name: Install clang + apt: + name: clang + state: latest + + - name: Install CTags + apt: + name: ctags + state: latest + + - name: Install Docker + apt: + name: docker-ce + state: latest + + - name: Install Docker Compose + apt: + name: docker-compose + state: latest + + # - name: Install Dropbox + # apt: + # name: dropbox + # state: latest + + - name: Install Git + apt: + name: git + state: latest + + - name: Install gnome-tweak-tool + apt: + name: gnome-tweak-tool + state: latest + + - name: Install Go + apt: + name: golang + state: latest + + - name: Install Google Chrome + apt: + name: google-chrome-stable + state: latest + + - name: Install jq + apt: + name: jq + state: latest + + - name: Install llvm + apt: + name: llvm + state: latest + + # - name: Install npm + # apt: + # name: npm + # state: latest + + - name: Install pandoc + apt: + name: pandoc + state: latest + + - name: Install polari + apt: + name: polari + state: latest + + - name: Install python-pip + apt: + name: python-pip + state: latest + + - name: Install python-netaddr + apt: + name: python-netaddr + state: latest + + - name: Install qtcreator + apt: + name: qtcreator + state: latest + + - name: Install redshift-gtk + apt: + name: redshift-gtk + state: latest + + - name: Install remmina + apt: + name: remmina + state: latest + + - name: Install rsync + apt: + name: rsync + state: latest + + - name: Install samba + apt: + name: samba + state: latest + + # - name: Install slack + # apt: + # name: slack + # state: latest + + # - name: Install steam + # apt: + # name: steam + # state: latest + + - name: Install sudo + apt: + name: sudo + state: latest + + - name: Install syncthing + apt: + name: syncthing + state: latest + + - name: Install tig + apt: + name: tig + state: latest + + # - name: Install tarsnap + # apt: + # name: tarsnap + # state: latest + + - name: Install tmux + apt: + name: tmux + state: latest + + - name: Install tree + apt: + name: tree + state: latest + + - name: Install vim-gtk3 + apt: + name: vim-gtk3 + state: latest + + - name: Install vlc + apt: + name: vlc + state: latest + + - name: Install ZSH + apt: + name: zsh + state: latest + + - name: Install ZFS + apt: + name: zfs-dkms + state: latest + + - name: Install ZFS Utils + apt: + name: zfsutils-linux + state: latest + + - include: 'general.yml' diff --git a/general.yml b/general.yml new file mode 100644 index 0000000..14a3459 --- /dev/null +++ b/general.yml @@ -0,0 +1,92 @@ +# setup config files + +- name: Clear /etc/vimrc + copy: + src: etc/vimrc + dest: /etc/vimrc + mode: 0644 + force: yes + +- name: Install /etc/sudoers + copy: + src: etc/sudoers + dest: /etc/sudoers + mode: 0644 + force: yes + +# pip packages + +- name: yq - YAML Query + pip: + name: yq + + +# services + +- name: Enable SSH Daemon + service: + name: sshd + enabled: yes + state: started + + +- name: Enable Docker Daemon + service: + name: docker + enabled: yes + state: started + + +# setup users and groups + +- name: wheel Group + group: + name: wheel + state: present +- name: Add gary to wheel + user: + name: gary + groups: wheel + append: true + +- name: Docker Group + group: + name: docker + state: present +- name: Add gary to docker + user: + name: gary + groups: docker + append: true + +- name: libvirt Group + group: + name: libvirt + state: present +- name: Add gary to libvirt + user: + name: gary + groups: libvirt + append: true + + +# services + +- name: Enable SSH Daemon + service: + name: sshd + enabled: yes + state: started + +- name: Enable Docker Daemon + service: + name: docker + enabled: yes + state: started + +- name: Enable Syncthing Daemon + service: + name: syncthing@gary + enabled: yes + state: started + diff --git a/notes.txt b/gnome.sh similarity index 100% rename from notes.txt rename to gnome.sh diff --git a/setup.yml b/setup.yml deleted file mode 100644 index 96c81fd..0000000 --- a/setup.yml +++ /dev/null @@ -1,297 +0,0 @@ -- hosts: all - tasks: - - - # setup config files - - - name: Clear /etc/vimrc - copy: - src: etc/vimrc - dest: /etc/vimrc - mode: 0644 - force: yes - - - name: Install /etc/sudoers - copy: - src: etc/sudoers - dest: /etc/sudoers - mode: 0644 - force: yes - - - name: Install /etc/yum.repos.d - copy: - src: etc/yum.repos.d/slack.repo - dest: /etc/yum.repos.d/slack.repo - mode: 0644 - force: yes - - - # setup yum repos - - - name: RPM Fusion - Free - dnf: - name: 'https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-25.noarch.rpm' - state: present - - - name: RPM Fusion - Non-free - dnf: - name: 'https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-25.noarch.rpm' - state: present - - - name: Google Chrome Repository - dnf: - name: 'https://dl.google.com/linux/direct/google-chrome-stable_current_x86_64.rpm' - state: present - - - name: ZFS - dnf: - name: 'http://download.zfsonlinux.org/fedora/zfs-release.fc25.noarch.rpm' - state: present - - - # install packages - - - name: Install Ansible - dnf: - name: ansible - state: latest - - - name: Install cargo - dnf: - name: cargo - state: latest - - - name: Install clang - dnf: - name: clang - state: latest - - - name: Install CTags - dnf: - name: ctags - state: latest - - - name: Install Docker - dnf: - name: docker - state: latest - - - name: Install Docker Compose - dnf: - name: docker-compose - state: latest - - - name: Install Dropbox - dnf: - name: nautilus-dropbox - state: latest - - - name: Install Git - dnf: - name: git - state: latest - - - name: Install gnome-tweak-tool - dnf: - name: gnome-tweak-tool - state: latest - - - name: Install Go - dnf: - name: golang - state: latest - - - name: Install Google Chrome - dnf: - name: google-chrome - state: latest - - - name: Install Java - dnf: - name: java-1.8.0-openjdk - state: latest - - - name: Install jq - dnf: - name: jq - state: latest - - - name: Install kernel-devel - dnf: - name: kernel-devel - state: latest - - - name: Install libselinux-python - dnf: - name: libselinux-python - state: latest - - - name: Install npm - dnf: - name: npm - state: latest - - - name: Install pandoc - dnf: - name: pandoc - state: latest - - - name: Install polari - dnf: - name: polari - state: latest - - - name: Install python-netaddr - dnf: - name: python-netaddr - state: latest - - - name: Install Qt 5 Devel - dnf: - name: qt5-devel - state: latest - - - name: Install redshift-gtk - dnf: - name: redshift-gtk - state: latest - - - name: Install qtcreator - dnf: - name: qtcreator - state: latest - - - name: Install rsync - dnf: - name: rsync - state: latest - - - name: Install samba - dnf: - name: samba - state: latest - - - name: Install slack - dnf: - name: slack - state: latest - - - name: Install steam - dnf: - name: steam - state: latest - - - name: Install sudo - dnf: - name: sudo - state: latest - - - name: Install tig - dnf: - name: tig - state: latest - - - name: Install tarsnap - dnf: - name: tarsnap - state: latest - - - name: Install tmux - dnf: - name: tmux - state: latest - - - name: Install vim-enhanced - dnf: - name: vim-enhanced - state: latest - - - name: Install vim-X11 - dnf: - name: vim-X11 - state: latest - - - name: Install vlc - dnf: - name: vlc - state: latest - - - name: Install ZFS - dnf: - name: zfs - state: latest - - - name: Install ZSH - dnf: - name: zsh - state: latest - - - # pip packages - - - name: yq - YAML Query - pip: - name: yq - - - # services - - - name: Enable SSH Daemon - service: - name: sshd - enabled: yes - state: started - - - - name: Enable Docker Daemon - service: - name: docker - enabled: yes - state: started - - - # setup users and groups - - - name: Docker Group - group: - name: docker - state: present - - name: Add gary to docker - user: - name: gary - groups: docker - append: true - - - - name: libvirt Group - group: - name: libvirt - state: present - - name: Add gary to libvirt - user: - name: gary - groups: libvirt - append: true - - - # services - - - name: Enable SSH Daemon - service: - name: sshd - enabled: yes - state: started - - - - name: Enable Docker Daemon - service: - name: docker - enabled: yes - state: started - - - # disable SELinux - - - name: Disable SELinux - selinux: - state: disabled