Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
7ff55d7
Update README.md
Cre-eD May 15, 2025
a057c02
Publish labs 01-06
Cre-eD Jan 7, 2026
2fbd476
Add lectures 11-16, quizzes & update lab18 landing page
Cre-eD Jan 17, 2026
9a363bf
Updated Looking Ahead with correct lab descriptions
Cre-eD Jan 17, 2026
e391e97
Updated the Course Completion section to mention 16-18 labs
Cre-eD Jan 17, 2026
888cd53
Updated the duration badge
Cre-eD Jan 17, 2026
2b850a9
Removed duplicates and updated all references
Cre-eD Jan 17, 2026
c871131
Updated lab1
Cre-eD Jan 18, 2026
d57fde0
Update lecs
Cre-eD Jan 22, 2026
9c7a125
feat: implement lab01 devops info service
Jan 27, 2026
2b900ad
irst commit
Feb 3, 2026
d4d7900
feat: add dockerfile and containerize python app for Lab 2
Feb 3, 2026
434d4c5
add: task 1, task 2
Feb 10, 2026
e1081c6
fix: remove requirements-dev from workflow
Feb 10, 2026
9c8c0a1
fix: workflow
Feb 10, 2026
6b4e9f2
fix: github_token
Feb 10, 2026
ddc653f
add: task 3
Feb 10, 2026
5d9ad10
lab03 done
Feb 10, 2026
ff02317
fix: LAB03.md screenshots
Feb 10, 2026
45d43b1
lab04 done
Feb 19, 2026
ba4fd5d
lab05 done
Feb 25, 2026
477fa66
lab done
Mar 4, 2026
3fe3255
fixed branches for workflow run
Mar 4, 2026
6a4c9c3
fix: branches for workflow
Mar 4, 2026
7653b36
fix lint
Mar 4, 2026
4bf6800
fix: run ansible-lint
Mar 4, 2026
9dd4bdb
with ansible-lint --fix
Mar 4, 2026
c969827
fix
Mar 5, 2026
ffc156f
fix
Mar 5, 2026
98b17f3
test ssh-keyscan fail
Mar 5, 2026
203d073
fix
Mar 5, 2026
bd19443
documenttion complete
Mar 5, 2026
b5ec477
lab done
Mar 12, 2026
e148a93
fix
Mar 12, 2026
ee1eb87
remove .env
Mar 12, 2026
b5357c7
fix: ansible host
Mar 12, 2026
0efca67
lab done
Mar 19, 2026
8973b2c
lab done
Mar 26, 2026
0c39d17
Added big files to gitignore
Mar 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 79 additions & 0 deletions .github/workflows/ansible-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
name: Ansible Deployment

on:
push:
branches: [main, master, lab06]
paths:
- "ansible/**"
- ".github/workflows/ansible-deploy.yml"
pull_request:
branches: [main, master, lab06]
paths:
- "ansible/**"

jobs:
lint:
name: Ansible Lint
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"

- name: Install dependencies
run: |
pip install ansible ansible-lint

- name: Run ansible-lint
env:
ANSIBLE_VAULT_PASSWORD: ${{ secrets.ANSIBLE_VAULT_PASSWORD }}
run: |
cd ansible
echo "$ANSIBLE_VAULT_PASSWORD" > /tmp/vault_pass
export ANSIBLE_VAULT_PASSWORD_FILE=/tmp/vault_pass
ansible-lint playbooks/*.yml
rm /tmp/vault_pass

deploy:
name: Deploy Application
needs: lint
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"

- name: Install Ansible
run: pip install ansible

- name: Setup SSH
run: |
mkdir -p ~/.ssh
echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa

- name: Deploy with Ansible
env:
ANSIBLE_VAULT_PASSWORD: ${{ secrets.ANSIBLE_VAULT_PASSWORD }}
ANSIBLE_HOST_KEY_CHECKING: False
run: |
cd ansible
echo "$ANSIBLE_VAULT_PASSWORD" > /tmp/vault_pass
ansible-playbook playbooks/deploy.yml \
-i inventory/hosts.ini \
--vault-password-file /tmp/vault_pass
rm /tmp/vault_pass

- name: Verify Deployment
run: |
sleep 10
curl -f http://${{ secrets.VM_HOST }}:5000 || exit 1
curl -f http://${{ secrets.VM_HOST }}:5000/health || exit 1
67 changes: 67 additions & 0 deletions .github/workflows/python-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: Python CI

on:
push:
paths:
- "app_python/**"
- ".github/workflows/python-ci.yml"
pull_request:
paths:
- "app_python/**"

jobs:
test-and-build:
runs-on: ubuntu-latest

steps:
- name: Checkout repo
uses: actions/checkout@v4

- name: Cache pip dependencies
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('app_python/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"

- name: Install dependencies
run: |
pip install --upgrade pip
pip install -r app_python/requirements.txt

- name: Run tests
run: |
cd app_python
pytest

- name: Docker login
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Set Docker image version
run: echo "VERSION=$(date +%Y.%m.%d)" >> $GITHUB_ENV

- name: Build and push Docker image
uses: docker/build-push-action@v6
with:
context: app_python
push: true
tags: |
${{ secrets.DOCKERHUB_USERNAME }}/devops-info-python:${{ env.VERSION }}
${{ secrets.DOCKERHUB_USERNAME }}/devops-info-python:latest

- name: Install Snyk
run: npm install -g snyk

- name: Run Snyk test
env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
run: snyk test --all-projects --severity-threshold=high
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
test
minikube-darwin-arm64
*.dmg
*.pkg
minikube*
Loading
Loading