mirror of
https://github.com/telekom-security/tpotce.git
synced 2025-10-26 18:24:45 +00:00
Compare commits
1 commit
8069200e53
...
a32035c157
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a32035c157 |
1 changed files with 57 additions and 2 deletions
|
|
@ -145,6 +145,32 @@
|
|||
- "Raspbian"
|
||||
- "Ubuntu"
|
||||
|
||||
- name: Install exa (Debian, Raspbian, Ubuntu)
|
||||
package:
|
||||
name:
|
||||
- exa
|
||||
state: latest
|
||||
update_cache: yes
|
||||
register: exa_install_result
|
||||
ignore_errors: yes
|
||||
when: ansible_distribution in ["Debian", "Raspbian", "Ubuntu"]
|
||||
tags:
|
||||
- "Debian"
|
||||
- "Raspbian"
|
||||
- "Ubuntu"
|
||||
|
||||
- name: Install eza (if exa failed)
|
||||
package:
|
||||
name:
|
||||
- eza
|
||||
state: latest
|
||||
update_cache: yes
|
||||
when: exa_install_result is failed
|
||||
tags:
|
||||
- "Debian"
|
||||
- "Raspbian"
|
||||
- "Ubuntu"
|
||||
|
||||
- name: Install grc from remote repo (AlmaLinux, Rocky)
|
||||
ansible.builtin.dnf:
|
||||
name: 'https://github.com/kriipke/grc/releases/download/1.13.8/grc-1.13.8-1.el7.noarch.rpm'
|
||||
|
|
@ -163,6 +189,7 @@
|
|||
- cracklib
|
||||
- curl
|
||||
- dnf-plugins-core
|
||||
- exa
|
||||
- git
|
||||
- grc
|
||||
- htop
|
||||
|
|
@ -173,6 +200,7 @@
|
|||
- wget
|
||||
state: latest
|
||||
update_cache: yes
|
||||
register: exa_install_result
|
||||
when: ansible_distribution in ["AlmaLinux", "Rocky"]
|
||||
tags:
|
||||
- "AlmaLinux"
|
||||
|
|
@ -197,6 +225,7 @@
|
|||
- cronie
|
||||
- curl
|
||||
- dnf-plugins-core
|
||||
- exa
|
||||
- git
|
||||
- grc
|
||||
- htop
|
||||
|
|
@ -207,6 +236,7 @@
|
|||
- wget
|
||||
state: latest
|
||||
update_cache: yes
|
||||
register: exa_install_result
|
||||
when: ansible_distribution in ["Fedora"]
|
||||
tags:
|
||||
- "Fedora"
|
||||
|
|
@ -234,6 +264,7 @@
|
|||
- ca-certificates
|
||||
- cracklib
|
||||
- curl
|
||||
- exa
|
||||
- git
|
||||
- grc
|
||||
- htop
|
||||
|
|
@ -241,6 +272,7 @@
|
|||
- wget
|
||||
state: latest
|
||||
update_cache: yes
|
||||
register: exa_install_result
|
||||
when: ansible_distribution in ["openSUSE Tumbleweed"]
|
||||
tags:
|
||||
- "openSUSE Tumbleweed"
|
||||
|
|
@ -697,7 +729,7 @@
|
|||
when: ansible_distribution in ["AlmaLinux", "Debian", "Fedora", "openSUSE Tumbleweed", "Raspbian", "Rocky", "Ubuntu"]
|
||||
failed_when: ansible_user_id == "root"
|
||||
|
||||
- name: Add aliases (All)
|
||||
- name: Add aliases with exa (All)
|
||||
blockinfile:
|
||||
path: ~/.bashrc
|
||||
block: |
|
||||
|
|
@ -705,10 +737,13 @@
|
|||
alias dpsw='watch -c bash -ic dps'
|
||||
alias mi='micro'
|
||||
alias sudo='sudo '
|
||||
alias ls='exa'
|
||||
alias ll='exa -hlg'
|
||||
alias la='exa -hlag'
|
||||
marker: "# {mark} ANSIBLE MANAGED BLOCK"
|
||||
insertafter: EOF
|
||||
state: present
|
||||
when: ansible_distribution in ["AlmaLinux", "Debian", "Fedora", "openSUSE Tumbleweed", "Raspbian", "Rocky", "Ubuntu"]
|
||||
when: exa_install_result is succeeded and ansible_distribution in ["AlmaLinux", "Debian", "Fedora", "openSUSE Tumbleweed", "Raspbian", "Rocky", "Ubuntu"]
|
||||
tags:
|
||||
- "AlmaLinux"
|
||||
- "Debian"
|
||||
|
|
@ -718,6 +753,26 @@
|
|||
- "Rocky"
|
||||
- "Ubuntu"
|
||||
|
||||
- name: Add aliases with eza (Debian, Raspbian, Ubuntu)
|
||||
blockinfile:
|
||||
path: ~/.bashrc
|
||||
block: |
|
||||
alias dps='grc --colour=on docker ps -f status=running -f status=exited --format "table {{'{{'}}.Names{{'}}'}}\\t{{'{{'}}.Status{{'}}'}}\\t{{'{{'}}.Ports{{'}}'}}" | sort'
|
||||
alias dpsw='watch -c bash -ic dps'
|
||||
alias mi='micro'
|
||||
alias sudo='sudo '
|
||||
alias ls='eza'
|
||||
alias ll='eza -hlg'
|
||||
alias la='eza -hlag'
|
||||
marker: "# {mark} ANSIBLE MANAGED BLOCK"
|
||||
insertafter: EOF
|
||||
state: present
|
||||
when: exa_install_result is failed and ansible_distribution in ["Debian", "Raspbian", "Ubuntu"]
|
||||
tags:
|
||||
- "Debian"
|
||||
- "Raspbian"
|
||||
- "Ubuntu"
|
||||
|
||||
- name: Clone / Update T-Pot repository (All)
|
||||
git:
|
||||
repo: 'https://github.com/telekom-security/tpotce'
|
||||
|
|
|
|||
Loading…
Reference in a new issue