Week 1 of KodeKloud’s 100 Days Challenge: Days 1-4 (Or: How I Learned to Stop Worrying and Love the Slow Labs
Jenkins
Source: Dev.to | Dec 19, 2025 (UTC)
I decided to torture myself with KodeKloud's 100 Days of DevOps challenge. The VMs load slower than continental drift, but the hands-on Linux practice is actually solid. Here's what I learned (and broke) in my first four days. **Day 1: Non-Interactive Users** The challenge was to create a user with a non-interactive shell. ``` bash sudo useradd -s /usr/sbin/nologin username getent passwd username
Enter fullscreen mode
Exit fullscreen mode
The mistake? I ran all these commands on the wrong host. Spent 10 minutes wondering why validation wasn’t working before realizing I was on my local terminal instead of SSH’d into the lab.
Lesson learned: Always double-check which host you’re on. Run hostname first.
Day 2: Temporary Users
The challenge was to create a user account with an expiration date.
This creates a ticking time bomb account—perfect for temporary contractors or intern access.
Bonus trick: Auto-lock account after 20 minutes:
bash echo "usermod --lock username" | at now + 20 minutes
Enter fullscreen mode
Exit fullscreen mode
The mistake? Did it on the wrong host. Again. 🤦
Day 3: Disabling Root SSH
The challenge was to disable root login across multiple servers.
Manual approach:
bash sudo vi /etc/ssh/sshd_config # Change: #PermitRootLogin no → PermitRootLogin no sudo systemctl restart sshd
Enter fullscreen mode
Exit fullscreen mode
Problem: I had to do this on three servers manually. Each SSH connection took 30 seconds—enough time to make coffee, question my life choices, and consider farming.
Automation solution:
bash for server in app1 app2 app3; do ssh $server "sudo sed -i 's/#PermitRootLogin no/PermitRootLogin no/' /etc/ssh/sshd_config && sudo systemctl restart sshd" done
Enter fullscreen mode
Exit fullscreen mode
My 30-minute nightmare became a 2-minute coffee break.
Lesson learned: If you’re doing something more than twice and it’s boring, automate it.
Day 4: File Permissions
The challenge was to make a script executable for all users.
bash chmod 755 /tmp/xfusioncorp.sh ls -l /tmp/xfusioncorp.sh
Залишити відповідь