Hyperling
3109891a7e
* Add another requirement for Debian to download key. * Add setup script instead of using scm.hyperling.com. * Fix setup permissions. * Starting effort to remove share drives from script. Downsizing homelab. * Remove files which are no longer useful without mounts. * Allow initializing on alternate branches. * Fix Lynis and NMap log locations. * Remove deleted files from main. * Fix nmap filename. * Remove _name from report variables.
53 lines
1.2 KiB
YAML
53 lines
1.2 KiB
YAML
---
|
|
# Create file to easily push git changes and call SCM.
|
|
|
|
- name: General | Scripts | User | scm.sh
|
|
blockinfile:
|
|
path: "{{ user_user.home }}/bin/scm.sh"
|
|
block: |
|
|
# 20210211 - Make life easier!
|
|
push.sh
|
|
time curl https://scm.hyperling.com | sudo bash
|
|
marker: '{mark}'
|
|
marker_begin: "#!{{ bash_exec.stdout }}"
|
|
marker_end: "exit 0"
|
|
state: present
|
|
create: yes
|
|
|
|
- name: General | Scripts | User | scm.sh Permissions
|
|
file:
|
|
path: "{{ user_user.home }}/bin/scm.sh"
|
|
mode: '0755'
|
|
|
|
|
|
- name: General | Scripts | User | scm-dev.sh
|
|
blockinfile:
|
|
path: "{{ user_user.home }}/bin/scm-dev.sh"
|
|
block: |
|
|
# 20210713 - Make life easier for development!
|
|
|
|
## Variables ##
|
|
|
|
# Use a specific branch if it was asked for.
|
|
branch="dev"
|
|
if [[ $1 != "" ]]; then
|
|
branch="$1"
|
|
fi
|
|
|
|
|
|
## Main ##
|
|
|
|
push.sh
|
|
time sudo {{ ansible_pull_exec.stdout }} -U {{ repo_github }} --checkout $branch
|
|
|
|
marker: '{mark}'
|
|
marker_begin: "#!{{ bash_exec.stdout }}"
|
|
marker_end: "exit 0"
|
|
state: present
|
|
create: yes
|
|
|
|
- name: General | Scripts | User | scm-dev.sh Permissions
|
|
file:
|
|
path: "{{ user_user.home }}/bin/scm-dev.sh"
|
|
mode: '0755'
|