Browse Source

+ installing tmux plugin manager for root_account role

+ starship install via yadm role (multi use installation) and installing Nerd Font
* change straship character for not privileged user
* fix path to normalized css for default nginx page
* own custom roles (allow releaseinfo change and install locales) moved to playbooks dir

#861m7vaer Шаблон операционной системы на Debian 10
master
dimti 2 years ago
parent
commit
cf50453d7d
  1. 2
      debops/nginx.yml
  2. 4
      debops/root_account.yml
  3. 6
      debops/system_users.yml
  4. 30
      debops/yadm.yml
  5. 16
      nginx-only.yml
  6. 6
      playbooks/own/allow-releaseinfo-change.yml
  7. 10
      playbooks/own/locales.yml

2
debops/nginx.yml

@ -81,7 +81,7 @@
- name: Copy normalized.css
template:
src: var/www/lxc_host/normalized.css
src: var/www/lxc_host/normalize.css
dest: '/var/www/{{ lxc_host }}/'
mode: 0644
owner: '{{ lxc_host }}'

4
debops/root_account.yml

@ -15,6 +15,10 @@
# root_account__dotfiles_enabled: True
# root_account__dotfiles_repo: 'https://vcs.wpstudio.ru/gitea/dotfiles.git'
post_tasks:
- name: Tmux Plugins Manager
shell: git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm && ~/.tmux/plugins/tpm/bin/install_plugins
roles:
- role: root_account
tags: [ 'role::root_account', 'skip::root_account' ]

6
debops/system_users.yml

@ -18,6 +18,12 @@
vars_files:
- ./../vars/system_users.yml
post_tasks:
- name: Change starship character to dollar sign
shell: "sed -i 's/#/\\\\$/g' /home/{{ lxc_host }}/.config/starship.toml"
args:
executable: /bin/bash
roles:
- role: libuser

30
debops/yadm.yml

@ -23,6 +23,36 @@
yadm__default_dotfiles:
- name: 'gitea'
git: 'https://vcs.wpstudio.ru/gitea/dotfiles.git'
yadm__packages:
- curl
- git
- ncdu
- fontconfig
- vim
- direnv
post_tasks:
- name: Starship
shell: |
curl -sS https://starship.rs/install.sh | sh -s -- -f
- name: Nerd Font
shell: |
download_font () {
url="https://raw.githubusercontent.com/ryanoasis/nerd-fonts/master/patched-fonts/SourceCodePro/Regular/complete/${1// /%20}"
path="/usr/share/fonts/$1"
curl -s -o "$path" "$url"
}
install_fonts () {
download_font "Sauce Code Pro Nerd Font Complete.ttf"
fc-cache -fv > /dev/null
}
install_fonts
args:
executable: /bin/bash
roles:
- role: keyring

16
nginx-only.yml

@ -1,12 +1,10 @@
---
- hosts: debian10
roles:
- release-changed
- locales
#- import_playbook: debops/tzdata.yml
#- import_playbook: debops/pki.yml
- import_playbook: playbooks/own/allow-releaseinfo-change.yml
- import_playbook: playbooks/own/locales.yml
- import_playbook: debops/tzdata.yml
- import_playbook: debops/pki.yml
- import_playbook: debops/yadm.yml
- import_playbook: debops/root_account.yml
#- import_playbook: debops/sudo.yml
#- import_playbook: debops/system_users.yml
#- import_playbook: debops/nginx.yml
- import_playbook: debops/sudo.yml
- import_playbook: debops/system_users.yml
- import_playbook: debops/nginx.yml

6
playbooks/own/allow-releaseinfo-change.yml

@ -0,0 +1,6 @@
---
- name: Resolve error for debian10 buster versions an apt update procedures
hosts: [ 'debian10' ]
tasks:
- name: Allow release info changed
shell: apt --allow-releaseinfo-change update

10
playbooks/own/locales.yml

@ -0,0 +1,10 @@
---
- name: Configure Locales
hosts: [ 'debian10' ]
tasks:
- name: Setup EN & RU UTF-8 locales
shell: |
apt install -y locales && \
sed -i 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \
sed -i 's/# ru_RU.UTF-8 UTF-8/ru_RU.UTF-8 UTF-8/' /etc/locale.gen && \
locale-gen
Loading…
Cancel
Save