Skip to content

sur309/Sample_Gaming_App

Repository files navigation

Snake Game for OpenShift (ROSA)

This is a simple static Snake game built with HTML, CSS, and JavaScript. It is containerized with Docker and ready for deployment on a ROSA (OpenShift) cluster using oc commands.

Features

  • Classic Snake gameplay
  • Responsive design
  • Easy to deploy on OpenShift

Getting Started

1. Build the Docker Image

docker build -t <your-image-name>:latest .

2. Push the Image to a Registry

docker tag <your-image-name>:latest <your-registry>/<your-image-name>:latest
docker push <your-registry>/<your-image-name>:latest

3. Update the Deployment YAML

Edit openshift-deployment.yaml and set the correct image name under spec.template.spec.containers.image.

4. Deploy to OpenShift (ROSA)

oc apply -f openshift-deployment.yaml

5. Access the Game

After deployment, get the route URL:

oc get route snake-game

Open the URL in your browser to play!


Project Structure

  • index.html - Main HTML file
  • style.css - Game styling
  • snake.js - Game logic
  • Dockerfile - Container build file
  • openshift-deployment.yaml - OpenShift deployment, service, and route

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors