Fix mdBook rendering issues with nested sections

This commit is contained in:
Hugh Ratsch
2025-03-02 11:28:31 -06:00
parent e4ba16bfc7
commit be1c0d3dc9
9 changed files with 246 additions and 101 deletions
+10 -4
View File
@@ -18,28 +18,34 @@
## User Management [👤]
- [User Management Solutions](solutions/user-management.md)
- [Creating Users with Specific Requirements (v1-S1)](solutions/user-management.md#scenario-creating-users-with-specific-requirements)
- [Departmental User Structure (v1-S1 Expanded)](solutions/user-management.md#scenario-creating-users-with-specific-requirements-1)
- [Creating Users with Specific Requirements (v1-S1)](solutions/user-management.md#scenario-creating-users-with-specific-requirements)
- [Departmental User Structure (v1-S1 Expanded)](solutions/user-management.md#scenario-creating-users-with-specific-requirements-1)
## Storage Management [💾]
- [Storage Management Solutions](solutions/storage-management.md)
- [LVM Configuration and Extension (v1-S2)](solutions/storage-management.md#scenario-create-a-new-2gb-partition-on-devsdb-and-extend-the-logical-volume-by-500mb-using-lvm)
- [LVM Configuration and Extension (v1-S2)](solutions/storage-management.md#scenario-v1-s2-lvm-configuration-and-management)
- [Create and Extend Logical Volume (v1-S2)](solutions/storage-management.md#scenario-v1-s2-create-a-new-2gb-partition-on-devsdb-and-extend-the-logical-volume-by-500mb-using-lvm)
## Service Management [⚙️]
- [Service Management Solutions](solutions/service-management.md)
- [Time Synchronization and Security (v1-S3)](solutions/service-management.md#scenario-time-synchronization-and-security-configuration)
- [Time Synchronization and Security (v1-S3)](solutions/service-management.md#scenario-v1-s3-time-synchronization-and-security-configuration)
## Networking [🌐]
- [Network Solutions](solutions/networking.md)
- [Network Interface Configuration (v1-S7)](solutions/networking.md#scenario-v1-s7-network-interface-configuration)
## Security [🔒]
- [Security Solutions](solutions/security.md)
- [SELinux and Firewall Configuration (v1-S3)](solutions/security.md#scenario-v1-s3-selinux-and-firewall-configuration)
## Container Management [📦]
- [Container Management Solutions](solutions/container-management.md)
- [Container Deployment (v1-S4)](solutions/container-management.md#scenario-v1-s4-container-management)
## System Recovery & Maintenance [🔧]
- [System Recovery Solutions](solutions/system-recovery.md)
- [System Recovery and Maintenance (v1-S5)](solutions/system-recovery.md#scenario-v1-s5-system-recovery-and-maintenance)
## Shell Scripting [📜]
- [Shell Scripting Solutions](solutions/shell-scripting.md)
- [File Management Script (v1-S6)](solutions/shell-scripting.md#scenario-v1-s6-shell-scripting)
+60 -11
View File
@@ -34,30 +34,79 @@ From Practice Scenarios v1, Scenario 7:
# Check routing
ip route show
```
[My explanation will go here after completing the exercise]
The first step is to identify the current network configuration to understand what needs to be changed.
2. Configure Network Interface
2. Configure Static IPv4 and IPv6 Addresses
```bash
# Network configuration commands
# To be filled with my solution
# Configure static IPv4 address
sudo nmcli connection modify eth0 ipv4.addresses 192.168.1.100/24 ipv4.method manual
# Configure static IPv6 address
sudo nmcli connection modify eth0 ipv6.addresses 2001:db8:1234:5678::100/64 ipv6.method manual
# Set default gateways
sudo nmcli connection modify eth0 ipv4.gateway 192.168.1.1
sudo nmcli connection modify eth0 ipv6.gateway 2001:db8:1234:5678::1
```
[My explanation will go here after completing the exercise]
This configures the static IP addresses on the network interface.
3. Apply and Verify Changes
3. Set Hostname
```bash
# Set hostname
sudo hostnamectl set-hostname rhcsa.example.com
# Update /etc/hosts
sudo echo "127.0.0.1 rhcsa.example.com rhcsa" >> /etc/hosts
```
This sets the system hostname and updates the hosts file.
4. Configure DNS Resolution
```bash
# Configure DNS servers
sudo nmcli connection modify eth0 ipv4.dns "8.8.8.8 8.8.4.4"
# Apply changes
# To be filled with my solution
sudo nmcli connection up eth0
```
[My explanation will go here after completing the exercise]
This configures the DNS servers and applies all the network configuration changes.
5. Configure Firewall Zones
```bash
# Create a new zone for restricted access
sudo firewall-cmd --permanent --new-zone=restricted
# Add services to the zone
sudo firewall-cmd --permanent --zone=restricted --add-service=ssh
sudo firewall-cmd --permanent --zone=restricted --add-service=http
# Add source network to the zone
sudo firewall-cmd --permanent --zone=restricted --add-source=192.168.1.0/24
# Reload firewall
sudo firewall-cmd --reload
```
This sets up a new firewall zone that restricts access to only SSH and HTTP from the local network.
### Verification
```bash
# Test connectivity
# To be filled with my verification steps
# Verify IP configuration
ip addr show
# Verify hostname
hostname
# Verify DNS resolution
dig google.com
# Verify firewall zones
sudo firewall-cmd --list-all-zones
```
### Key Learnings
- [To be filled after completing the exercise]
- Network configuration with NetworkManager
- IPv4 and IPv6
- Firewall zone management
- DNS configuration
## Skills Demonstrated
- Network Configuration
+55 -77
View File
@@ -32,46 +32,80 @@ From Practice Scenarios v1, Scenario 3 (Security Part):
# Check SELinux contexts
ls -Z /var/www/html
```
[Explanation of current state]
First we verify that SELinux is in enforcing mode and check the current contexts for the web server directory.
2. Configure SELinux Policies
```bash
# Set SELinux boolean
setsebool -P httpd_can_network_connect on
# Install SELinux policy utilities
sudo dnf install policycoreutils-python-utils
# Allow Apache to listen on port 8080
sudo semanage port -a -t http_port_t -p tcp 8080
# Modify context
semanage fcontext -a -t httpd_sys_content_t "/custom/path(/.*)?"
# Set SELinux boolean for network connections
sudo setsebool -P httpd_can_network_connect on
```
[Explanation of configuration]
This configures SELinux to allow Apache to listen on port 8080 and enables network connections.
3. Configure Firewall
```bash
# To be filled with my solution
# Check current firewall status
sudo firewall-cmd --list-all
# Allow HTTP and HTTPS
sudo firewall-cmd --permanent --add-service=http
sudo firewall-cmd --permanent --add-service=https
# Allow custom port 8080
sudo firewall-cmd --permanent --add-port=8080/tcp
# Reload firewall
sudo firewall-cmd --reload
```
[My explanation will go here after completing the exercise]
This configures the firewall to allow incoming connections on ports 80, 443, and 8080.
4. Secure SSH Configuration
```bash
# To be filled with my solution
# Make a backup of sshd_config
sudo cp /etc/ssh/sshd_config /etc/ssh/sshd_config.bak
# Edit SSH configuration
sudo vi /etc/ssh/sshd_config
```
[My explanation will go here after completing the exercise]
Add or modify these lines:
```
PermitRootLogin no
PasswordAuthentication no
PubkeyAuthentication yes
```
```bash
# Restart SSH service
sudo systemctl restart sshd
```
This secures SSH by disabling root login and password authentication, requiring key-based authentication.
### Verification
```bash
# Verify SELinux status
sestatus
# Verify SELinux port configuration
sudo semanage port -l | grep http_port_t
# Check audit logs
ausearch -m AVC -ts recent
# Verify firewall configuration
sudo firewall-cmd --list-all
# Test functionality
curl localhost/custom/path
# Verify SSH configuration
sudo sshd -T | grep -E 'permitrootlogin|passwordauthentication|pubkeyauthentication'
# Test Apache on port 8080
curl localhost:8080
```
### Key Learnings
- Understanding of SELinux concepts
- Security best practices
- Troubleshooting methodology
- Understanding of SELinux port contexts
- Firewall configuration with firewalld
- SSH security best practices
- Verification methodology
## Skills Demonstrated
- SELinux Management
@@ -96,37 +130,7 @@ From Practice Scenarios v2, Scenario 5:
- Required Outcome: Hardened system with granular access controls and application-specific security
### Solution Steps
1. Configure SELinux for custom application
```bash
# To be filled with my solution
```
[My explanation will go here after completing the exercise]
2. Implement firewalld rich rules
```bash
# To be filled with my solution
```
[My explanation will go here after completing the exercise]
3. Set up ACLs and sudo restrictions
```bash
# To be filled with my solution
```
[My explanation will go here after completing the exercise]
4. Configure password policies
```bash
# To be filled with my solution
```
[My explanation will go here after completing the exercise]
### Verification
```bash
# To be filled with my verification steps
```
### Key Learnings
- [To be filled after completing the exercise]
[To be filled when I complete this exercise]
## Scenario: [v3-S5] Comprehensive Security Setup
@@ -154,30 +158,4 @@ From Practice Scenarios v3, Scenario 5:
- Required Outcome: Enterprise-grade security implementation with custom policies
### Solution Steps
1. Develop comprehensive SELinux strategy
```bash
# To be filled with my solution
```
[My explanation will go here after completing the exercise]
2. Configure advanced firewalld setup
```bash
# To be filled with my solution
```
[My explanation will go here after completing the exercise]
3. Implement hardened SSH configuration
```bash
# To be filled with my solution
```
[My explanation will go here after completing the exercise]
### Verification
```bash
# To be filled with my verification steps
```
### Key Learnings
- [To be filled after completing the exercise]
[Additional scenarios will be documented here as completed]
[To be filled when I complete this exercise]
+2 -4
View File
@@ -85,8 +85,8 @@ curl localhost
### Environment
- OS Version: RHEL/Rocky Linux
- Initial State:
- Required Outcome:
- Initial State: Default installation without time sync or security configurations
- Required Outcome: Properly configured time synchronization, firewall, SELinux, SSH, and automated updates
### Solution Steps
1. Configure chronyd to sync with time server 'time.example.com'
@@ -103,8 +103,6 @@ curl localhost
# Save and exit
:wq
The output should show the chrony service enabled and running
# Enable and start service
sudo systemctl enable chronyd
sudo systemctl start chronyd
+1 -1
View File
@@ -14,7 +14,7 @@ This section documents my solutions to storage management scenarios, including p
## Scenario: [v1-S2] LVM Configuration and Management
### Original Problem
[To be filled with actual scenario]
Create a new 2GB partition and configure it with LVM.
### Environment
- OS Version: RHEL/Rocky Linux
+16 -3
View File
@@ -10,7 +10,7 @@ This section contains my solutions to various user management scenarios from the
| [v2-S1] | System Access and File Management - Practice Scenarios v2 |
| [v3-S1] | Advanced User Management - Practice Scenarios v3 |
## Scenario: [v1-S1] Creating Users with Specific Requirements
## Scenario: Creating Users with Specific Requirements
### Original Problem
From Practice Scenarios v1: Create a user named 'john' with a custom shell and home directory.
@@ -54,7 +54,7 @@ From Practice Scenarios v1: Create a user named 'john' with a custom shell and h
***
***
## Scenario: [v1-S1] Creating Users with Specific Requirements (Expanded)
## Scenario: Creating Users with Specific Requirements-1
### Original Problem
- Create a new user called 'analyst1' with home directory '/home/analyst1'
@@ -109,7 +109,20 @@ From Practice Scenarios v1: Create a user named 'john' with a custom shell and h
This sets the password expiry for 'analyst1' to 90 days
### Verification
Commands used to verify the solution works correctly
Commands used to verify the solution works correctly:
```bash
# Verify user creation
id analyst1
# Verify group membership
groups analyst1
# Verify directory permissions
ls -la /data/reports
# Verify password expiry
sudo chage -l analyst1
```
### Key Learnings
- Understanding of useradd, groupadd, usermod, mkdir, chown, chmod, chage commands