Browse Source

Move tasks into new general role

master
Lukas Bestle 1 year ago
parent
commit
d677cefb63
Signed by: lukas GPG Key ID: 692037D104550FC9
  1. 0
      roles/general/files/authorized_keys
  2. 0
      roles/general/files/dotfiles/.composer/vendor/bin/.gitkeep
  3. 0
      roles/general/files/dotfiles/.config/fish/conf.d/pkgs.fish
  4. 0
      roles/general/files/dotfiles/.config/fish/config.fish
  5. 0
      roles/general/files/dotfiles/.config/fish/functions/fish_greeting.fish
  6. 0
      roles/general/files/dotfiles/.config/fish/functions/nsreverse.fish
  7. 0
      roles/general/files/dotfiles/.config/fish/functions/nsreverse6.fish
  8. 0
      roles/general/files/dotfiles/.config/fish/pkgs/.gitkeep
  9. 0
      roles/general/files/dotfiles/.config/git/.gitkeep
  10. 0
      roles/general/files/dotfiles/.config/welcome/colossal.flf
  11. 0
      roles/general/files/dotfiles/.config/welcome/summarizers/01-date.sh
  12. 0
      roles/general/files/dotfiles/.config/welcome/summarizers/02-uptime.sh
  13. 0
      roles/general/files/dotfiles/.config/welcome/summarizers/03-quota.sh
  14. 0
      roles/general/files/dotfiles/.config/welcome/summarizers/04-ram.sh
  15. 0
      roles/general/files/dotfiles/.config/welcome/warners/.gitkeep
  16. 0
      roles/general/files/dotfiles/.local/bin/.gitkeep
  17. 33
      roles/general/tasks/main.yml
  18. 0
      roles/general/templates/gitconfig.j2
  19. 0
      roles/general/templates/index.html.j2
  20. 11
      roles/host-site/tasks/main.yml
  21. 0
      roles/shell/handlers/main.yml
  22. 22
      roles/shell/tasks/main.yml
  23. 4
      site.yml

0
roles/terminal/files/authorized_keys → roles/general/files/authorized_keys

0
roles/terminal/files/dotfiles/.composer/vendor/bin/.gitkeep → roles/general/files/dotfiles/.composer/vendor/bin/.gitkeep

0
roles/terminal/files/dotfiles/.config/fish/conf.d/pkgs.fish → roles/general/files/dotfiles/.config/fish/conf.d/pkgs.fish

0
roles/terminal/files/dotfiles/.config/fish/config.fish → roles/general/files/dotfiles/.config/fish/config.fish

0
roles/terminal/files/dotfiles/.config/fish/functions/fish_greeting.fish → roles/general/files/dotfiles/.config/fish/functions/fish_greeting.fish

0
roles/terminal/files/dotfiles/.config/fish/functions/nsreverse.fish → roles/general/files/dotfiles/.config/fish/functions/nsreverse.fish

0
roles/terminal/files/dotfiles/.config/fish/functions/nsreverse6.fish → roles/general/files/dotfiles/.config/fish/functions/nsreverse6.fish

0
roles/terminal/files/dotfiles/.config/fish/pkgs/.gitkeep → roles/general/files/dotfiles/.config/fish/pkgs/.gitkeep

0
roles/terminal/files/dotfiles/.config/git/.gitkeep → roles/general/files/dotfiles/.config/git/.gitkeep

0
roles/terminal/files/dotfiles/.config/welcome/colossal.flf → roles/general/files/dotfiles/.config/welcome/colossal.flf

0
roles/terminal/files/dotfiles/.config/welcome/summarizers/01-date.sh → roles/general/files/dotfiles/.config/welcome/summarizers/01-date.sh

0
roles/terminal/files/dotfiles/.config/welcome/summarizers/02-uptime.sh → roles/general/files/dotfiles/.config/welcome/summarizers/02-uptime.sh

0
roles/terminal/files/dotfiles/.config/welcome/summarizers/03-quota.sh → roles/general/files/dotfiles/.config/welcome/summarizers/03-quota.sh

0
roles/terminal/files/dotfiles/.config/welcome/summarizers/04-ram.sh → roles/general/files/dotfiles/.config/welcome/summarizers/04-ram.sh

0
roles/terminal/files/dotfiles/.config/welcome/warners/.gitkeep → roles/general/files/dotfiles/.config/welcome/warners/.gitkeep

0
roles/terminal/files/dotfiles/.local/bin/.gitkeep → roles/general/files/dotfiles/.local/bin/.gitkeep

33
roles/terminal/tasks/main.yml → roles/general/tasks/main.yml

@ -6,15 +6,6 @@
key: "{{ item }}"
with_file: authorized_keys
- name: Get current shell
shell: "getent passwd {{ ansible_facts.user_id }} | cut -d: -f7"
register: current_shell
changed_when: no
- name: Change shell to fish
command: chsh --shell /usr/bin/fish
when: "current_shell.stdout != '/usr/bin/fish'"
- name: Copy dotfiles to home directory
copy:
src: dotfiles/
@ -34,19 +25,6 @@
- "{{ ansible_facts.env.HOME }}/.bash_history"
- "{{ ansible_facts.env.HOME }}/.zcompdump"
- name: Download and update iTerm2 shell integration
get_url:
url: https://iterm2.com/shell_integration/fish
dest: "{{ ansible_facts.env.HOME }}/.config/fish/conf.d/iterm2_integration.fish"
force: yes
- name: Download and update Oh My Fish! packages
git:
repo: "{{ item.value }}"
dest: "{{ ansible_facts.env.HOME }}/.config/fish/pkgs/{{ item.key }}"
loop: "{{ omf_pkgs | dict2items }}"
notify: Collect fish functions from packages
- name: Disable cron MAILTO
cronvar:
name: MAILTO
@ -55,3 +33,14 @@
- name: Set up host-specific cronjobs
cron: "{{ item }}"
loop: "{{ cronjobs.get(ansible_facts.user_id, []) }}"
- name: Add host domain to Uberspace config
import_role:
name: snapstromegon.uberspace_web_domain
vars:
domain: kodos-{{ ansible_facts.user_id }}.codesignd.net
- name: Set up host site
template:
src: index.html.j2
dest: /var/www/virtual/{{ ansible_facts.user_id }}/html/index.html

0
roles/terminal/templates/gitconfig.j2 → roles/general/templates/gitconfig.j2

0
roles/host-site/templates/index.html.j2 → roles/general/templates/index.html.j2

11
roles/host-site/tasks/main.yml

@ -1,11 +0,0 @@
---
- name: Add host domain to Uberspace config
import_role:
name: snapstromegon.uberspace_web_domain
vars:
domain: kodos-{{ ansible_facts.user_id }}.codesignd.net
- name: Set up host site
template:
src: index.html.j2
dest: /var/www/virtual/{{ ansible_facts.user_id }}/html/index.html

0
roles/terminal/handlers/main.yml → roles/shell/handlers/main.yml

22
roles/shell/tasks/main.yml

@ -0,0 +1,22 @@
---
- name: Get current shell
shell: "getent passwd {{ ansible_facts.user_id }} | cut -d: -f7"
register: current_shell
changed_when: no
- name: Change shell to fish
command: chsh --shell /usr/bin/fish
when: "current_shell.stdout != '/usr/bin/fish'"
- name: Download and update iTerm2 shell integration
get_url:
url: https://iterm2.com/shell_integration/fish
dest: "{{ ansible_facts.env.HOME }}/.config/fish/conf.d/iterm2_integration.fish"
force: yes
- name: Download and update Oh My Fish! packages
git:
repo: "{{ item.value }}"
dest: "{{ ansible_facts.env.HOME }}/.config/fish/pkgs/{{ item.key }}"
loop: "{{ omf_pkgs | dict2items }}"
notify: Collect fish functions from packages

4
site.yml

@ -5,9 +5,9 @@
- vars/config.yml
- vars/installs.yml
roles:
- general
- homebrew
- host-site
- terminal
- shell
- name: Redirect mail from non-mail Uberspaces
hosts: "!mail"

Loading…
Cancel
Save