Upgrade & Secure Your Future with DevOps, SRE, DevSecOps, MLOps!

We spend hours on Instagram and YouTube and waste money on coffee and fast food, but won’t spend 30 minutes a day learning skills to boost our careers.
Master in DevOps, SRE, DevSecOps & MLOps!

Learn from Guru Rajesh Kumar and double your salary in just one year.


Get Started Now!

Rundeck Assignments 2 – Windows


Rundeck Student Assignments (Windows Local Node)

πŸ“ Setup Prerequisites:

  • Ensure PowerShell is available (default on Windows Server 2019)
  • The rundeck server itself is also the execution node
  • Students must create a project first (e.g., windows-lab)

πŸŽ“ Assignment List


Assignment 1: Hello World in PowerShell

Objective: Run a basic PowerShell script as a Rundeck job.

  • Job Name: hello-world
  • Step Type: Script β†’ PowerShell
  • Command: Write-Output "Hello from Rundeck on Windows Server!"
  • Expected Outcome: Job log displays the message.
  • Learning Outcome: Understand basic job creation and PowerShell execution.

Assignment 2: List Running Processes

Objective: Use Rundeck to list all currently running processes.

  • Job Name: list-processes
  • Script Step: Get-Process | Sort-Object CPU -Descending | Select-Object -First 10
  • Expected Outcome: Displays the top 10 CPU-consuming processes in the job log.
  • Bonus: Add a second step to export to a file in C:\rundeck\logs.

Assignment 3: Create a User-Supplied Directory

Objective: Use job options to accept a directory name and create it.

  • Job Name: create-directory
  • Job Option:
    • Name: foldername
    • Description: “Name of the folder to create in C:\rundeck”
  • Script Step: New-Item -Path "C:\rundeck\${option.foldername}" -ItemType Directory
  • Expected Outcome: Creates a folder with the given name.
  • Learning Outcome: Understand job options and user input.

Assignment 4: Disk Space Report

Objective: Generate a disk usage report for drive C:\.

  • Job Name: disk-space-report
  • Script Step: Get-PSDrive C | Format-List > C:\rundeck\disk_report.txt Get-Content C:\rundeck\disk_report.txt
  • Expected Outcome: Job log shows disk usage and a file is saved.

Assignment 5: System Health Check Workflow

Objective: Run a multi-step job that checks system health.

  • Job Name: system-health-check
  • Workflow Steps:
    1. Uptime: (Get-CimInstance Win32_OperatingSystem).LastBootUpTime
    2. CPU Load (5 seconds sample): Get-Counter '\Processor(_Total)\% Processor Time' -SampleInterval 5 -MaxSamples 1
    3. Memory Usage: Get-CimInstance Win32_OperatingSystem | Select-Object FreePhysicalMemory, TotalVisibleMemorySize
    4. Active Sessions: quser
  • Expected Outcome: Combined output of system diagnostics in job logs.

πŸ“ Optional Directory Structure for Files:

You may suggest students save outputs to:

C:\rundeck\
β”œβ”€β”€ logs\
β”‚   β”œβ”€β”€ disk_report.txt
β”‚   β”œβ”€β”€ process_list.txt
β”œβ”€β”€ backups\

πŸ“š Learning Objectives for Students

SkillLearned Through
Job creationHello World
PowerShell scriptingAll jobs
Job optionsAssignment 3
Logging/outputAssignment 2 & 4
WorkflowsAssignment 5

Subscribe
Notify of
guest
0 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments

Certification Courses

DevOpsSchool has introduced a series of professional certification courses designed to enhance your skills and expertise in cutting-edge technologies and methodologies. Whether you are aiming to excel in development, security, or operations, these certifications provide a comprehensive learning experience. Explore the following programs:

DevOps Certification, SRE Certification, and DevSecOps Certification by DevOpsSchool

Explore our DevOps Certification, SRE Certification, and DevSecOps Certification programs at DevOpsSchool. Gain the expertise needed to excel in your career with hands-on training and globally recognized certifications.

0
Would love your thoughts, please comment.x
()
x