Skip to content

Commit 91e2bf5

Browse files
author
Alok-Nayak
committed
github action adv: matrix strategy
1 parent 5900f9d commit 91e2bf5

4 files changed

Lines changed: 128 additions & 0 deletions

File tree

.github/workflows/app.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
from flask import Flask, render_template
2+
app = Flask(__name__)
3+
4+
5+
@app.route('/')
6+
def hello_world():
7+
return render_template('index.html')
8+
9+
10+
@app.route('/health')
11+
def health():
12+
return 'Server is up and running'
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Python Lint
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
jobs:
8+
validate:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: checkout code
13+
uses: action/checkout@v4
14+
15+
steps:
16+
- name: setup python
17+
uses: actions/setup-python@v5
18+
with:
19+
python-version: "3.13"
20+
21+
22+
- name: install libraries & dependencies
23+
run: pip install -r requirements.txt
24+
25+
- name: run linter
26+
run: flake8 app.py
27+

.github/workflows/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
flake8
Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
6+
<title>DevOps Zero To Hero</title>
7+
<style>
8+
* { margin: 0; padding: 0; box-sizing: border-box; }
9+
body {
10+
min-height: 100vh;
11+
display: flex;
12+
align-items: center;
13+
justify-content: center;
14+
background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
15+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
16+
color: #e0e0e0;
17+
}
18+
.container {
19+
text-align: center;
20+
padding: 2rem;
21+
max-width: 640px;
22+
}
23+
h1 {
24+
font-size: 2.5rem;
25+
margin-bottom: 0.5rem;
26+
background: linear-gradient(90deg, #00d2ff, #7b2ff7);
27+
-webkit-background-clip: text;
28+
-webkit-text-fill-color: transparent;
29+
}
30+
.badge {
31+
display: inline-block;
32+
margin: 1rem 0 2rem;
33+
padding: 0.4rem 1.2rem;
34+
border: 1px solid #7b2ff7;
35+
border-radius: 999px;
36+
font-size: 0.9rem;
37+
color: #c4b5fd;
38+
letter-spacing: 0.05em;
39+
}
40+
.cards {
41+
display: flex;
42+
gap: 1rem;
43+
justify-content: center;
44+
flex-wrap: wrap;
45+
}
46+
.card {
47+
background: rgba(255, 255, 255, 0.06);
48+
border: 1px solid rgba(255, 255, 255, 0.1);
49+
border-radius: 12px;
50+
padding: 1.5rem 1.8rem;
51+
min-width: 150px;
52+
flex: 1;
53+
}
54+
.card span {
55+
display: block;
56+
font-size: 0.75rem;
57+
text-transform: uppercase;
58+
letter-spacing: 0.1em;
59+
color: #9ca3af;
60+
margin-bottom: 0.4rem;
61+
}
62+
.card strong {
63+
font-size: 1.25rem;
64+
color: #f9fafb;
65+
}
66+
</style>
67+
</head>
68+
<body>
69+
<div class="container">
70+
<h1>DevOps Zero To Hero</h1>
71+
<div class="badge">Josh Batch 10</div>
72+
<div class="cards">
73+
<div class="card">
74+
<span>Framework</span>
75+
<strong>Flask 3.1</strong>
76+
</div>
77+
<div class="card">
78+
<span>Runtime</span>
79+
<strong>Python 3.14</strong>
80+
</div>
81+
<div class="card">
82+
<span>Deploy</span>
83+
<strong>AWS ECS</strong>
84+
</div>
85+
</div>
86+
</div>
87+
</body>
88+
</html>

0 commit comments

Comments
 (0)