GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - BrianGator/CI-CD-Python: CI-CD-Python

BranchesTags
Open more actions menu

Latest commit

 

History

5 Commits
5 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
.tekton
.tekton
 
 
assets/.aistudio
assets/.aistudio
 
 
project-deliverables
project-deliverables
 
 
service
service
 
 
src
src
 
 
tests
tests
 
 
.env.example
.env.example
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
index.html
index.html
 
 
metadata.json
metadata.json
 
 
package.json
package.json
 
 
project-deliverables.txt
project-deliverables.txt
 
 
requirements.txt
requirements.txt
 
 
tsconfig.json
tsconfig.json
 
 
vite.config.ts
vite.config.ts
 
 

Repository files navigation

Project Name= CI/CD Final Project

Written by Brian McCarthy

Project Overview

This repository represents the Continuous Integration and Continuous Delivery (CI/CD) final project. It contains a RESTful API counter microservice built in Python, integrated with a fully functional automated CI/CD lifecycle using GitHub Actions for Continuous Integration and Tekton (OpenShift Pipelines) for Continuous Deployment.

The mission of this project is to automate the linting, unit testing, image building, and deployment of a Python RESTful microservice to ensure maximum operational safety, reliability, and automated speed.


Technical Specifications & Languages Used

  • Programming Language: Python (3.8 / 3.9)
  • Backend Framework: Flask / RESTful API design
  • CI Engine: GitHub Actions
  • CD Engine: Tekton Pipelines (OpenShift Pipelines)
  • Containerization: Docker / Buildah
  • Linting Tool: Flake8
  • Testing Framework: Nose (unit testing with coverage reporting)

File Structure

The project has the following modular file structure:

cicd-final-project/
│
├── .github/
│   └── workflows/
│       └── workflow.yml        # GitHub Actions CI pipeline trigger on push/PR
│
├── .tekton/
│   └── tasks.yml               # Tekton Tasks definition (cleanup, nose unit test)
│
├── service/
│   ├── __init__.py             # Packages initialization
│   ├── models.py               # REST API models & local state storage
│   └── routes.py               # RESTful endpoint routes (written by Brian McCarthy)
│
├── tests/
│   ├── __init__.py             # Test package initialization
│   └── test_routes.py          # Unit test assertions
│
├── requirements.txt            # Python environment dependencies
├── README.md                   # This project design & deliverables document (by Brian McCarthy)
└── setup.cfg                   # Tool configuration files (such as flake8)

Core Deliverables

This project fulfills the following 10-point scoring requirements (Total: 20 points, requires 14 points / 70% to pass):

1. Project Name & Readme Details (2 points)

  • Repositories are cleanly structured and named cicd-final-project.
  • The README.md details of the project are explicitly outlined here.

2. GitHub Actions CI Workflow (workflow.yml) (4 points)

  • Defined in .github/workflows/workflow.yml.
  • Contains automated checkout and dependency installation.
  • Runs the Lint with flake8 step to enforce PEP 8 guidelines.
  • Runs Run unit tests with nose with full coverage tracking.

3. Tekton CD Tasks (tasks.yml) (4 points)

  • Defined in .tekton/tasks.yml.
  • Includes a cleanup task to securely scour the working directory.
  • Includes a nose unit test task executing inside standard lightweight containers.

4. OpenShift PersistentVolumeClaim (PVC) (2 points)

  • Set up dynamically to secure persistent workspace storage on OpenShift clusters.
  • Configured with Storage Class: skills-network-learner and Size: 1Gi.

5. GitHub Actions Verification Output (2 points)

  • Verification terminal output demonstrating successful workflow runs.

6. OpenShift CD Pipeline Outline (oc-pipelines-oc-final) (2 points)

  • Complete deployment workflow containing stages: cleanup ➔ git-clone ➔ flake8-linting ➔ nose-tests ➔ buildah-image-build ➔ openshift-deploy.

7. OpenShift Deployment Success Run (oc-pipelines-oc-green) (2 points)

  • Completed pipeline pipeline-run displaying successful execution metrics.

8. OpenShift Application Running Logs (oc-pipelines-app-logs) (2 points)

  • Container stream logs representing stateful counter tracking.

How to Set Up and Use

Local Initialization

  1. Ensure Python 3.8+ is installed:
    python --version
  2. Clone the repository and change directory:
    git clone https://github.com/BrianGator/cicd-final-project.git
    cd cicd-final-project
  3. Set up the development virtual environment and install dependencies:
    python -m venv venv
    source venv/bin/activate
    pip install -r requirements.txt

Executing Local Quality Assurance

  • To run Linters (flake8):
    flake8 service --count --select=E9,F63,F7,F82 --show-source --statistics
  • To run Unit Tests (nose):
    nosetests -v --with-spec --spec-color --with-coverage --cover-package=service

Written by Brian McCarthy

About

CI-CD-Python

Topics

api-restdockerflask-restfulgithub-actionspythontekton-pipelines

Resources

Readme
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

Generated from google-gemini/aistudio-repository-template
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.