Fixed 404 errors and 500 error #15
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# GitHub Workflow: Check Open-O | |
# | |
# Description: | |
# This workflow automates the build, testing, and code quality checks for | |
# the Open-O Maven project. It ensures the project builds successfully and adheres | |
# to coding standards defined by Checkstyle. | |
# | |
# Usage: | |
# - Triggered by pull requests targeting the following branches: | |
# - main | |
# - develop/alpaca | |
# - develop/bullfrog | |
# - develop/coyote | |
# - develop/dolphin | |
# | |
# Key Jobs: | |
# - build: | |
# - Checks out the source code, builds Docker containers, generates Make files, | |
# builds the project, and runs unit tests while compiling JSP files. | |
# - checkstyle: | |
# - Checks out the source code, builds Docker containers, and runs the | |
# Maven Checkstyle plugin to enforce code style guidelines. | |
# | |
# License: | |
# This GitHub Workflow file is part of the Open-O project and is subject | |
# to the licensing terms outlined in the repository's LICENSE file. | |
# | |
# Last Updated: | |
# January 31, 2025 | |
name: Check Open-O | |
on: | |
pull_request: | |
branches: | |
- main | |
- develop/alpaca | |
- develop/bullfrog | |
- develop/coyote | |
- develop/dolphin | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Cache Docker layers | |
uses: actions/cache@v3 | |
with: | |
path: /home/runner/.docker | |
key: ${{ runner.os }}-docker-${{ github.sha }} | |
restore-keys: | | |
${{ runner.os }}-docker- | |
- name: Cache Maven packages | |
uses: actions/cache@v3 | |
with: | |
path: ~/.m2 | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
restore-keys: | | |
${{ runner.os }}-maven- | |
- name: Build Docker containers | |
uses: hoverkraft-tech/[email protected] | |
with: | |
compose-file: ".devcontainer/docker-compose.yml" | |
- name: Generate make file | |
run: docker exec devcontainer-open-o-1 .devcontainer/development/scripts/make lock | |
- name: Build project | |
run: docker exec devcontainer-open-o-1 .devcontainer/development/scripts/make install | |
- name: Run unit tests & build JSP files | |
run: docker exec devcontainer-open-o-1 mvn package -Pjspc | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Cache Docker layers | |
uses: actions/cache@v3 | |
with: | |
path: /home/runner/.docker | |
key: ${{ runner.os }}-docker-${{ github.sha }} | |
restore-keys: | | |
${{ runner.os }}-docker- | |
- name: Cache Maven packages | |
uses: actions/cache@v3 | |
with: | |
path: ~/.m2 | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
restore-keys: | | |
${{ runner.os }}-maven- | |
- name: Build Docker containers | |
uses: hoverkraft-tech/[email protected] | |
with: | |
compose-file: ".devcontainer/docker-compose.yml" | |
- name: Run Maven Checkstyle plugin | |
run: docker exec devcontainer-open-o-1 mvn checkstyle:checkstyle |