use ansible-aur module for AUR packages

This commit is contained in:
Pig Monkey 2015-12-12 13:12:19 -08:00
parent 908e78cd26
commit 2d0c544683
31 changed files with 74 additions and 509 deletions

View file

@ -57,19 +57,15 @@ role.
All tasks involving the [AUR][6] are tagged `aur`. To provision an AUR-free
system, pass this tag to ansible's `--skip-tag`.
AUR packages will be downloaded via [cower][7] and installed with [makepkg][8].
It is assumed that the user will want to use an [AUR helper][9] after the
system has been provisioned, so whatever package is defined in `aur.helper`
will be installed. This helper will *not* be used during any of the
provisioning.
AUR packages are installed via the [ansible-aur][7] module. Note that while
[aura][8], an [AUR helper][9], is installed by default, it will *not* be used
during any of the provisioning.
## Known Issues
* [tpfanco][10], normally installed as part of the `thinkpad` role is currently
[unavailable in the AUR][11]. No ThinkPad fan control software is currently
installed.
* [gpxpy][12], normally installed as part of the `mapping` role is currently
[unavailable in the AUR][13].
[1]: http://www.ansible.com
@ -78,10 +74,8 @@ provisioning.
[4]: https://wiki.archlinux.org/index.php/Secure_Shell#Managing_the_sshd_daemon
[5]: https://thoughtbot.github.io/rcm/
[6]: https://aur.archlinux.org
[7]: https://github.com/falconindy/cower
[8]: https://wiki.archlinux.org/index.php/Makepkg
[7]: https://github.com/pigmonkey/ansible-aur
[8]: https://github.com/aurapm/aura
[9]: https://wiki.archlinux.org/index.php/AUR_helpers
[10]: https://code.google.com/p/tpfanco/
[11]: https://aur.archlinux.org/packages/?O=0&K=tpfanco
[12]: https://github.com/tkrajina/gpxpy
[13]: https://aur.archlinux.org/packages/?O=0&K=gpxpy

View file

@ -11,8 +11,11 @@ hostname: nous
aur:
dir: aur
helper: aura-bin
makepkg: makepkg -csri --noconfirm --needed --noprogressbar
packages:
- aura-bin
- pmount
- orpie
- firejail
ssh:
port: 22

@ -1 +1 @@
Subproject commit f59e1df56feb201ccb79acce995ff5349acef76c
Subproject commit cdff10ae118718c58afbb13ddf67247c5cca4bda

View file

@ -15,7 +15,6 @@
- { role: laptop, tags: ['laptop'] }
- { role: thinkpad, tags: ['thinkpad'] }
- { role: screensaver, tags: ['screensaver'] }
- { role: firejail, tags: ['firejail'] }
- { role: chat, tags: ['chat'] }
- { role: git-annex, tags: ['git-annex'] }
- { role: ledger, tags: ['ledger'] }

View file

@ -1,18 +1,6 @@
---
- name: Download hashdeep
command: cower -dq hashdeep
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/hashdeep
- name: Install hashdeep
aur: name=hashdeep user={{ user.name }}
tags:
- aur
- hashdeep
become: yes
become_user: "{{ user.name }}"
- name: Build and install hashdeep
command: "{{ aur.makepkg }} --skippgpcheck chdir=/home/{{ user.name }}/{{ aur.dir }}/hashdeep"
tags:
- aur
- hashdeep
become: yes
become_user: "{{ user.name }}"

View file

@ -1,23 +1,10 @@
---
- name: Download rcm
command: cower -dq rcm
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/rcm
- name: Install rcm
aur: name=rcm user={{ user.name }}
when: dotfiles is defined
tags:
- aur
- dotfiles
become: yes
become_user: "{{ user.name }}"
- name: Build and install rcm
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/rcm"
when: dotfiles is defined
tags:
- aur
- dotfiles
become: yes
become_user: "{{ user.name }}"
- name: Clone user dotfiles
git: repo={{ dotfiles.url }} dest=/home/{{ user.name }}/.dotfiles accept_hostkey=yes update=no

View file

@ -15,4 +15,3 @@
- include: cron.yml
- include: ssh.yml
- include: dotfiles.yml
- include: orpie.yml

View file

@ -1,19 +0,0 @@
---
- name: Download orpie
command: cower -dq orpie
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/orpie
tags:
- aur
- orpie
become: yes
become_user: "{{ user.name }}"
- name: Build and install orpie
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/orpie"
tags:
- aur
- orpie
become: yes
become_user: "{{ user.name }}"

View file

@ -14,66 +14,15 @@
- aur
- packages
- name: Download cower
get_url: url=https://aur.archlinux.org/cgit/aur.git/snapshot/cower.tar.gz
dest=/home/{{ user.name }}/{{ aur.dir }}
owner={{ user.name }}
group={{ user.group }}
- name: Install cower
aur: name=cower user={{ user.name }} skip_pgp=yes
tags:
- aur
- packages
- name: Extract cower
unarchive: src=/home/{{ user.name }}/{{ aur.dir }}/cower.tar.gz
dest=/home/{{ user.name }}/{{ aur.dir }}
copy=no
owner={{ user.name }}
group={{ user.group }}
creates=/home/{{ user.name }}/{{ aur.dir }}/cower
- name: Install AUR base packages
aur: name={{ item }} user={{ user.name }}
with_items: "{{ aur.packages }}"
tags:
- aur
- packages
- name: Build and install cower
command: "{{ aur.makepkg }} --skippgpcheck chdir=/home/{{ user.name }}/{{ aur.dir }}/cower"
tags:
- aur
- packages
become: yes
become_user: "{{ user.name }}"
- name: Download AUR helper
command: cower -dq {{ aur.helper }}
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/{{ aur.helper }}
tags:
- aur
- packages
become: yes
become_user: "{{ user.name }}"
- name: Build and install AUR helper
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/{{ aur.helper }}"
tags:
- aur
- packages
become: yes
become_user: "{{ user.name }}"
- name: Download pmount
command: cower -dq pmount
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/pmount
tags:
- aur
- packages
become: yes
become_user: "{{ user.name }}"
- name: Build and install pmount
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/pmount"
tags:
- aur
- packages
become: yes
become_user: "{{ user.name }}"

View file

@ -10,20 +10,8 @@
- chromium
- firejail
- name: Download Chromium Pepper Flash
command: cower -dq chromium-pepper-flash
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/chromium-pepper-flash
- name: Install Chromium Pepper Flash
aur: name=chromium-pepper-flash user={{ user.name }}
tags:
- aur
- chromium
become: yes
become_user: "{{ user.name }}"
- name: Build and install Chromium Pepper Flash
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/chromium-pepper-flash"
tags:
- aur
- chromium
become: yes
become_user: "{{ user.name }}"

View file

@ -17,38 +17,11 @@
tags:
- ruby-dev
- name: Download Ruby bundler
command: cower -dq ruby-bundler
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/ruby-bundler
- name: Install Compass and dependencies
aur: name={{ item }} user={{ user.name }}
with_items:
- ruby-bundler
- ruby-compass
tags:
- aur
- ruby-dev
become: yes
become_user: "{{ user.name }}"
- name: Build and install Ruby bundler
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/ruby-bundler"
tags:
- aur
- ruby-dev
become: yes
become_user: "{{ user.name }}"
- name: Download Compass
command: cower -dq ruby-compass
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/ruby-compass
tags:
- aur
- ruby-dev
become: yes
become_user: "{{ user.name }}"
- name: Build and install Compass
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/ruby-compass"
tags:
- aur
- ruby-dev
become: yes
become_user: "{{ user.name }}"

View file

@ -1,3 +0,0 @@
---
dependencies:
- { role: base }

View file

@ -1,16 +0,0 @@
---
- name: Download Firejail
command: cower -dq firejail
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/firejail
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Build and install Firejail
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/firejail"
tags:
- aur
become: yes
become_user: "{{ user.name }}"

View file

@ -1,16 +1,5 @@
---
- name: Download git-annex
command: cower -dq git-annex-bin
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/git-annex-bin
- name: Install git-annex
aur: name=git-annex-bin user={{ user.name }} skip_pgp=yes
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Build and install git-annex
command: "{{ aur.makepkg }} --skippgpcheck chdir=/home/{{ user.name }}/{{ aur.dir }}/git-annex-bin"
tags:
- aur
become: yes
become_user: "{{ user.name }}"

View file

@ -1,39 +1,15 @@
---
- name: Download rofi
command: cower -dq rofi-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/rofi-git
- name: Install rofi
aur: name=rofi-git user={{ user.name }}
tags:
- aur
- rofi
become: yes
become_user: "{{ user.name }}"
- name: Build and install rofi
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/rofi-git"
- name: Install rofi-pass
aur: name=rofi-pass-git user={{ user.name }}
tags:
- aur
- rofi
become: yes
become_user: "{{ user.name }}"
- name: Download rofi-pass
command: cower -dq rofi-pass-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/rofi-pass-git
tags:
- aur
- rofi
become: yes
become_user: "{{ user.name }}"
- name: Build and install rofi-pass
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/rofi-pass-git"
tags:
- aur
- rofi
become: yes
become_user: "{{ user.name }}"
- name: Install i3-wm for rofi window switching
pacman: name=i3-wm state=present

View file

@ -1,19 +1,6 @@
---
- name: Download light-git
command: cower -dq light-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/light-git
- name: Install light-git
aur: name=light-git user={{ user.name }}
tags:
- aur
- light-git
become: yes
become_user: "{{ user.name }}"
- name: Build and install light-git
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/light-git"
tags:
- aur
- light-git
become: yes
become_user: "{{ user.name }}"

View file

@ -1,25 +1,5 @@
---
- name: Install ledger dependencies
pacman: name={{ item }} state=present
with_items:
- boost
- cmake
- texlive-plainextra
- name: Install ledger
aur: name=ledger user={{ user.name }}
tags:
- aur
- name: Download ledger
command: cower -dq ledger
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/ledger
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Build and install ledger
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/ledger"
tags:
- aur
become: yes
become_user: "{{ user.name }}"

View file

@ -4,21 +4,8 @@
tags:
- mtrack-git
- name: Download xf86-input-mtrack-git
command: cower -dq xf86-input-mtrack-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/xf86-input-mtrack-git
- name: Install xf86-input-mtrack-git
aur: name=xf86-input-mtrack-git user={{ user.name }}
tags:
- aur
- mtrack-git
become: yes
become_user: "{{ user.name }}"
- name: Build and install mtrack-git
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/xf86-input-mtrack-git"
tags:
- aur
- mtrack-git
become: yes
become_user: "{{ user.name }}"

View file

@ -1,18 +1,6 @@
---
- name: Download goobook-git
command: cower -dq goobook-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/goobook-git
- name: Install goobook-git
aur: name=goobook-git user={{ user.name }}
tags:
- aur
- contacts
become: yes
become_user: "{{ user.name }}"
- name: Build and install goobook-git
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/goobook-git"
tags:
- aur
- contacts
become: yes
become_user: "{{ user.name }}"

View file

@ -1,35 +1,13 @@
---
- name: Download Mutt
command: cower -dq mutt-sidebar
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/mutt-sidebar
- name: Install mutt
aur: name=mutt-sidebar user={{ user.name }}
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Build and install Mutt
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/mutt-sidebar"
- name: Install urlview
aur: name=urlview user={{ user.name }}
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Download urlview
command: cower -dq urlview
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/urlview
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Build and install urlview
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/urlview"
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Install OfflineIMAP
pacman: name=offlineimap state=present

View file

@ -2,18 +2,7 @@
- name: Install Viking
pacman: name=viking state=present
#- name: Download gpxpy
# command: cower -dq python-gpxpy
# chdir=/home/{{ user.name }}/{{ aur.dir }}
# creates=/home/{{ user.name }}/{{ aur.dir }}/python-gpxpy
# tags:
# - aur
# become: yes
# become_user: "{{ user.name }}"
#- name: Build and install gpxpy
# command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/python-gpxpy"
# tags:
# - aur
# become: yes
# become_user: "{{ user.name }}"
- name: Install gpxpy
aur: name=python-gpxpy user={{ user.name }}
tags:
- aur

View file

@ -1,54 +1,11 @@
---
- name: Download xininfo
command: cower -dq xininfo-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/xininfo-git
- name: Install teiler and dependencies
aur: name=ledger user={{ user.name }}
aur: name={{ item }} user={{ user.name }}
with_items:
- xininfo-git
- copyq-git
- teiler-git
tags:
- aur
- teiler
become: yes
become_user: "{{ user.name }}"
- name: Build and install xininfo
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/xininfo-git"
tags:
- aur
- teiler
become: yes
become_user: "{{ user.name }}"
- name: Download teiler (rofi screenshot app)
command: cower -dq teiler-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/teiler-git
tags:
- aur
- teiler
become: yes
become_user: "{{ user.name }}"
- name: Build and install teiler
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/teiler-git"
tags:
- aur
- teiler
become: yes
become_user: "{{ user.name }}"
- name: Download copyq (clipboard mgr)
command: cower -dq copyq-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/copyq-git
tags:
- aur
- teiler
become: yes
become_user: "{{ user.name }}"
- name: Build and install copyq
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/copyq-git"
tags:
- aur
- teiler
become: yes
become_user: "{{ user.name }}"

View file

@ -1,19 +1,5 @@
---
- name: Download pdsh
command: cower -dq pdsh
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/pdsh
- name: Install pdsh
aur: name=pdsh user={{ user.name }}
tags:
- aur
- pdsh
become: yes
become_user: "{{ user.name }}"
- name: Build and install pdsh
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/pdsh"
tags:
- aur
- pdsh
become: yes
become_user: "{{ user.name }}"

View file

@ -2,21 +2,10 @@
- name: Install xautolock
pacman: name=xautolock state=present
- name: Download physlock
command: cower -dq physlock
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/physlock
- name: Install physlock
aur: name=physlock user={{ user.name }}
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Build and install physlock
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/physlock"
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Push sleep lock script
template: src=lock.sh.j2 dest=/usr/lib/systemd/system-sleep/lock.sh mode=755

View file

@ -4,20 +4,8 @@
tags:
- battery
- name: Download tpacpi-bat
command: cower -dq tpacpi-bat
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/tpacpi-bat
- name: Install tpacpi-bat
aur: name=tpacpi-bat user={{ user.name }}
tags:
- aur
- battery
become: yes
become_user: "{{ user.name }}"
- name: Build and install tpacpi-bat
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/tpacpi-bat"
tags:
- aur
- battery
become: yes
become_user: "{{ user.name }}"

View file

@ -1,21 +1,9 @@
---
- name: Download tpfanco
command: cower -dq tpfanco-svn
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/tpfanco-svn
- name: Install tpfanco
aur: name=tpfanco-svn user={{ user.name }}
tags:
- aur
- fan
become: yes
become_user: "{{ user.name }}"
- name: Build and install tpfanco
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/tpfanco-svn"
tags:
- aur
- fan
become: yes
become_user: "{{ user.name }}"
- name: Copy tpfanco configuration file
copy: src=thinkfan.conf dest=/etc/thinkfan.conf

View file

@ -9,23 +9,11 @@
tags:
- virtualbox
- name: Download VirtualBox extensions
command: cower -dq virtualbox-ext-oracle
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/virtualbox-ext-oracle
- name: Install VirtualBox extensions
aur: name=virtualbox-ext-oracle user={{ user.name }}
tags:
- aur
- virtualbox
become: yes
become_user: "{{ user.name }}"
- name: Build and install VirtualBox extensions
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/virtualbox-ext-oracle"
tags:
- aur
- virtualbox
become: yes
become_user: "{{ user.name }}"
- name: Copy kernel modules to load
copy: src=modules.conf dest=/etc/modules-load.d/virtualbox.conf

View file

@ -1,18 +1,6 @@
---
- name: Download autorandr
command: cower -dq autorandr-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/autorandr-git
- name: Install autorandr
aur: name=autorandr-git user={{ user.name }}
tags:
- aur
- autorandr
become: yes
become_user: "{{ user.name }}"
- name: Build and install autorandr
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/autorandr-git"
tags:
- aur
- autorandr
become: yes
become_user: "{{ user.name }}"

View file

@ -1,18 +1,6 @@
---
- name: Download srandrd
command: cower -dq srandrd
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/srandrd
- name: Install srandrd
aur: name=srandrd user={{ user.name }}
tags:
- aur
- srandrd
become: yes
become_user: "{{ user.name }}"
- name: Build and install srandrd
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/srandrd"
tags:
- aur
- srandrd
become: yes
become_user: "{{ user.name }}"

View file

@ -4,20 +4,8 @@
tags:
- termite
- name: Download termite
command: cower -dq termite-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/termite-git
- name: Install termite
aur: name=termite-git user={{ user.name }}
tags:
- aur
- termite
become: yes
become_user: "{{ user.name }}"
- name: Build and install termite
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/termite-git"
tags:
- aur
- termite
become: yes
become_user: "{{ user.name }}"

View file

@ -1,19 +1,8 @@
---
- name: Download YubiKey Personalizaiton GUI
command: cower -dq yubikey-personalization-gui-git
chdir=/home/{{ user.name }}/{{ aur.dir }}
creates=/home/{{ user.name }}/{{ aur.dir }}/yubikey-personalization-gui-git
- name: Install YubiKey Personalization GUI
aur: name=yubikey-personalization-gui-git user={{ user.name }}
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Build and install YubiKey Personalization GUI
command: "{{ aur.makepkg }} chdir=/home/{{ user.name }}/{{ aur.dir }}/yubikey-personalization-gui-git"
tags:
- aur
become: yes
become_user: "{{ user.name }}"
- name: Install smartcard libs/tools
pacman: name={{ item }} state=present