Optimized .mds and meta/main.yml for user.

This commit is contained in:
Kevin Veen-Birkenbach 2025-03-14 12:37:15 +01:00
parent 632b4e9b22
commit 8a5997e54e
No known key found for this signature in database
GPG Key ID: 44D8F11FD62F878E
2 changed files with 49 additions and 1 deletions

View File

@ -1 +1,24 @@
This role executes tasks which are relevant for all users
# User Role
## Description
This role executes tasks that are relevant for all users by configuring essential shell files. It deploys customized templates for [`.bashrc`](https://wiki.archlinux.org/title/Bash#Startup_files) and [`.bash_profile`](https://wiki.archlinux.org/title/Bash#Login_shells) for any specified user. This ensures a consistent and enhanced shell environment across the system.
## Overview
Optimized for modular configuration, this role uses Jinja2 templates to create:
- A customized [`.bashrc`](https://wiki.archlinux.org/title/Bash#Startup_files) that sets up a dynamic welcome message, system information, and useful aliases.
- A standardized [`.bash_profile`](https://wiki.archlinux.org/title/Bash#Login_shells) that sources the `.bashrc` to ensure consistent behavior upon login.
The role adapts its file paths based on the target user (e.g. the [root user](https://en.wikipedia.org/wiki/Superuser) or a standard user), ensuring proper ownership and permissions.
## Purpose
The primary purpose of this role is to establish a consistent and informative shell environment for all users. By standardizing shell configuration, it helps improve usability and system management through clear and structured output upon login.
## Features
- **Shell Configuration:** Deploys customized [`.bashrc`](https://wiki.archlinux.org/title/Bash#Startup_files) and [`.bash_profile`](https://wiki.archlinux.org/title/Bash#Login_shells) files.
- **Dynamic Content:** Displays system information, load averages, memory usage, disk usage, CPU details, and top processes upon login.
- **User-Specific Customization:** Adapts file locations and ownership based on the target user.
- **Enhanced Usability:** Sets color-coded prompts and aliases for a better command-line experience.

25
roles/user/meta/main.yml Normal file
View File

@ -0,0 +1,25 @@
---
galaxy_info:
author: "Kevin Veen-Birkenbach"
description: "Executes common tasks for user environment configuration."
license: "CyMaIS NonCommercial License (CNCL)"
license_url: "https://s.veen.world/cncl"
company: |
Kevin Veen-Birkenbach
Consulting & Coaching Solutions
https://www.veen.world
min_ansible_version: "2.9"
platforms:
- name: Linux
versions:
- all
galaxy_tags:
- user
- bash
- ssh
- configuration
- administration
repository: "https://s.veen.world/cymais"
issue_tracker_url: "https://s.veen.world/cymaisissues"
documentation: "https://s.veen.world/cymais"
dependencies: []