Преглед изворни кода

package setup only at one place

master
Markus Katharina Brechtel пре 2 година
родитељ
комит
372a76e107
7 измењених фајлова са 49 додато и 34 уклоњено
  1. +0
    -17
      tasks/hostname.yaml
  2. +0
    -5
      tasks/keyboard_configuration.yaml
  3. +9
    -8
      tasks/main.yaml
  4. +0
    -4
      tasks/network.yaml
  5. +30
    -0
      tasks/shells/fish.yaml
  6. +6
    -0
      tasks/shells/xonsh.yaml
  7. +4
    -0
      vars/main.yaml

+ 0
- 17
tasks/hostname.yaml Прегледај датотеку

@@ -1,27 +1,10 @@
---

- setup:
gather_subset: '!all'
when: not root_target_directory is defined

- apt:
pkg: dbus
state: present
when:
- not root_target_directory is defined
- ansible_os_family == "Debian"

- name: hostname
hostname:
name: "{{inventory_hostname}}"
when: not root_target_directory is defined

- name: etc directory
file:
path: "{{ root_target_directory }}/etc"
state: directory
when: root_target_directory is defined

- name: hostname file
copy:
content: "{{inventory_hostname}}"


+ 0
- 5
tasks/keyboard_configuration.yaml Прегледај датотеку

@@ -1,10 +1,5 @@
---

- name: apt install console-setup
apt:
pkg: console-setup
when: not root_target_directory is defined

- name: default directory
file:
path: "{{ root_target_directory | default('') }}/etc/default"


+ 9
- 8
tasks/main.yaml Прегледај датотеку

@@ -1,5 +1,14 @@
---

# packages setup
- import_tasks: debian_repos.yaml
when:
- ansible_distribution == "Debian"
- not ansible_lsb.id is defined or ansible_lsb.id != "Raspbian"

- import_tasks: debian_packages.yaml
when: ansible_distribution == "Debian"

# user setup
- import_tasks: root_user.yaml
- import_tasks: ssh-agent.yaml
@@ -20,14 +29,6 @@

- import_tasks: network.yaml

# packages setup
- import_tasks: debian_repos.yaml
when:
- ansible_distribution == "Debian"
- not ansible_lsb.id is defined or ansible_lsb.id != "Raspbian"

- import_tasks: debian_packages.yaml
when: ansible_distribution == "Debian"
# shell setup
- import_tasks: shells/fish.yaml
tags:


+ 0
- 4
tasks/network.yaml Прегледај датотеку

@@ -1,9 +1,5 @@
---

- name: ensure resolvconf is installed
apt:
pkg: resolvconf

- name: link resolv.conf
file:
src: /run/resolvconf/resolv.conf


+ 30
- 0
tasks/shells/fish.yaml Прегледај датотеку

@@ -0,0 +1,30 @@
---

- name: fish package
apt:
pkg: fish

- name: fish config directory
file:
path: /etc/fish/conf.d
state: directory

- name: fish config files
copy:
src: shells/fish/global/
dest: /etc/fish/conf.d/
with_items:
- fish_title
- fish_prompt
- fish_greeting

# root user
- name: fish root user config directory
file:
path: /root/.config/fish/conf.d/
state: directory

- name: fish root user config files
copy:
src: shells/fish/root/
dest: /root/.config/fish/conf.d/

+ 6
- 0
tasks/shells/xonsh.yaml Прегледај датотеку

@@ -0,0 +1,6 @@
---

- name: xonsh config
copy:
src: shells/xonsh/xonshrc
dest: /etc/xonshrc

+ 4
- 0
vars/main.yaml Прегледај датотеку

@@ -61,6 +61,10 @@ debian_common_packages:
- python3-setuptools
- golang

# system
- console-setup
- dbus

# security tools
- openssh-client
- ssh-agent-filter