aboutsummaryrefslogtreecommitdiffstats
path: root/roles/workstation/tasks/main.yml
diff options
context:
space:
mode:
authorbinary <me@rgoncalves.se>2021-02-27 10:30:33 +0100
committerbinary <me@rgoncalves.se>2021-02-27 10:30:33 +0100
commit5acdc00aaf6c65c1353cc02a59f33e0d6ba9a281 (patch)
tree8bb7737b3efd6055dbf098105858c43c7453fbd6 /roles/workstation/tasks/main.yml
parentd776d9820aeeb2fb84a4a47ce5eacf3a40823591 (diff)
downloadinfrastructure-5acdc00aaf6c65c1353cc02a59f33e0d6ba9a281.tar.gz
Break workstation role in sub-roles
Diffstat (limited to 'roles/workstation/tasks/main.yml')
-rw-r--r--roles/workstation/tasks/main.yml48
1 files changed, 0 insertions, 48 deletions
diff --git a/roles/workstation/tasks/main.yml b/roles/workstation/tasks/main.yml
deleted file mode 100644
index 6b8d28f..0000000
--- a/roles/workstation/tasks/main.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-
-# workstation ~~ roles/workstation/tasks/main.yml
-# init workstation
-
----
-
-- name: retrieve BECOME method
- stat: path=/usr/bin/doas
- register: ws_become
-
-- name: retrieve original user
- shell: logname
- register: ws_user
-
-- name: retrieve host facts
- set_fact:
- ansible_become_method: "{{ 'doas' if ws_become.stat.exists else 'sudo' }}"
- ansible_become_user: root
- ws_user: "{{ ws_user.stdout }}"
-
-- name: include distribution specific task
- include_tasks: "_{{ ansible_distribution | lower }}.yml"
- ignore_errors: true
-
-- name: generate doas configuration
- lineinfile:
- path: /etc/doas.conf
- regexp: "^permit persist keepenv {{ ws_user }} as root"
- line: "permit persist keepenv {{ ws_user }} as root"
- owner: root
- mode: 0644
- create: true
-
-- name: check sudo binary path
- shell: which sudo
- register: sudo
- ignore_errors: true
-
-- name: uninstall sudo binary
- package:
- name: sudo
- state: absent
- when: sudo.rc == 0
- register: sudo
- ignore_errors: true
-
-- name: setup dotfiles from upstream and user script
- meta: end_host
remember that computers suck.