Giter Club home page Giter Club logo

aces's Introduction

Anti-Cheat Enforcement System

ACES is a containerized web application designed to manage software-based assignments for instructors while providing guards against various forms of cheating. The application runs through Docker and utilizes Docker-Compose to build and manage different microservices, consisting of four main pieces:

  1. A web frontend (.NET Core MVC) for uploading assignments and managing students (for instructors), and a centralized location for downloading prepared assignments (for students).

  2. A database (Microsoft SQL Server) for tracking instructors, students, assignments, submissions, and student assignment commits.

  3. An HTTP API (Python) for uploading assignments and preparing assignments for individual student usage.

  4. A Git management web frontend (Gitea) for holding remote repositories generated by students.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

At minimum, running ACES requires an installation of Git and Docker (and, by extension, Docker-Compose). While Docker-Compose should come with most default installations of Docker (especially on macOS or Windows), separately installing Docker-Compose on Linux may be required, and it is suggested that you follow a guide based on your distribution.

Windows 10: Follow the instructions for setup on Docker's documentation. Make sure you have Windows 10 Professional or Enterprise, and that you are configured to run Linux containers, not Windows containers.

macOS: Follow the instructions for setup on Docker's documentation. A Homebrew installation should also be relatively painless, if you prefer. Since ACES-Factory will be manipulating folders on-disk (local to the repository), Docker should have access to macOS's filesystem (which is off by default). The easiest way to fix this is to go to System Preferences > Security & Privacy > Privacy tab > Full Disk Access and check the box next to Docker.

VirtualBox and/or Linux: Development environments for all of ACES have been successfully configured on Manjaro Linux (which has a Desktop environment) and Arch Linux (which is just a terminal). If you have the space, a Manjaro Linux virtual machine is an easy way to keep dependencies isolated from your hardware.

Once Manjaro is installed, the following commands should be enough to get you running:

sudo pacman -Syu docker docker-compose
sudo systemctl start docker.service
sudo systemctl enable docker.service
sudo usermod -aG docker $USER
reboot

Installing

Make sure Docker is started and verify your installation by running the following in the terminal and receiving roughly the following output (note that version numbers may differ):

$ docker version
Client: Docker Engine - Community
 Version:           19.03.12
 [...]

Server: Docker Engine - Community
 Engine:
  Version:          19.03.12
 [...]

Then, clone the repository and cd into the appropriate folder.

git clone https://github.com/bradleypeterson/ACES.git aces && cd aces/aces

To run all the components of ACES, run this command within the same folder:

docker-compose up -d

This will boot all the services required to run ACES and will pull, build, and attach networks to containers as necessary.

From here, navigate to http://localhost:8080 to verify that the web frontend and database are working.

To develop on a specific container, follow the instructions in the given container's README.md.

Dashboard

Database

Factory

Git Hooks

Running the tests

Coming soon!

Deployment

The true beauty of containerized applications is that running in development and running in production is virtually the same! Eventually a true CI/CD pipeline can replace this process, but for now, deployment is pretty trivial. Make sure you have SSH access to a server that has Docker, Docker-Compose, and Git.

Clone the repository onto the server, cd into the correct folder, and run docker-compose up -d.

git clone https://github.com/bradleypeterson/ACES.git aces
cd aces/aces
docker-compose up -d

Once everything is built, use docker-compose ps to observe all the running pieces of the application.

$ docker-compose ps
      Name                   Command              State              Ports
-------------------------------------------------------------------------------------
aces_dashboard_1   dotnet A.C.E.S.dll             Up      0.0.0.0:8080->80/tcp
aces_db_1          /opt/mssql/bin/sqlservr        Up      0.0.0.0:1433->1433/tcp
aces_factory_1     ash /app/entrypoint.sh         Up      0.0.0.0:8081->8080/tcp
aces_gitea_1       /usr/bin/entrypoint /bin/s     Up      0.0.0.0:222->22/tcp,
                   ...                                    0.0.0.0:3000->3000/tcp

Authors

Capstone Project Summer 2020:

  • @Aoshua
  • @TannerL
  • @Morgan-Jensen
  • @loganrios

aces's People

Contributors

extantdread avatar 16jhawkins avatar aoshua avatar morgan-jensen avatar loganrios avatar

Watchers

James Cloos avatar Joseph Hwang avatar Brad Peterson avatar  avatar

aces's Issues

Not persisting DB changes when pulling to new machine

Because our DB is running in a Docker container that is using a .bak file to re-create the database after the volume is destroyed (if docker system prune is run), when restoring from the .bak file, all data added to the DB during the previous run will be lost. When the app is actually on a server, it will not be powered down often, but when it is, it will loose that added data.

One potential solution is to add to the docker-compose.yml so that a "docker-compose down" command replaces the old .bak file with an updated one. That way even if the container crashes, little to no data will be lost.

Get docker containers built on VS Run

We ran out of time this semester, but I eventually came across lots of information to be able to manage the containers through Visual Studio (rather than typing "docker-compose up -d" in the console, just click run in Visual Studio). Here are some links that should be helpful to get this project headed in the correct direction.

Add miscellaneous features to Factory container

The following features are required but not yet added to the Factory container/service:

  • Write watermark, email, assignment number, and amount of watermarks to database upon service completion.
  • Delete .acesconfig.json file once assignment has been prepared.
  • Auto-delete prepared ZIP folder 10 minutes after creation to save server space.
  • Support other watermarking methods (file extensions, whitespacing)
  • Add in Git Hooks to prepared files

Furthermore, some additional features:

  • Allow for creation of assignment folders from uploaded ZIP. Should automate creation of .acesconfig.json files, init-ing with given Git templates (and as such, commit hooks), and publish to Gitea with username.

Git hook counting number of watermarks

I have gotten started on writing part of the code which will also count how many of each given watermark is in a given assignment. This needs to be finished as well as getting it sending the data to the database.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.