Skip to content

An online coding platform where user can log in and select problem from problem list and code..Upon submission user gets the output.

Notifications You must be signed in to change notification settings

HIMA10SHREE/Coding-platform

Repository files navigation

BUILT AN ONLINE CODING PLATFORM FROM SCRATCH AND DOCKERISED THE APPLICATION AND FINALLY HOSTED IN EC2 SERVER

BELOW ARE THE STEPS:

HOSTING A MERN APPLICATION ON EC2 INSTANCE

STEPS:

1.Launch the instance..(in mycase I launched t2.micro)

2.ssh to the instance and clone the github repo using git clone

3.install the latest node package(in my case I installed nodev18.18.0 since my different packages in the application was not supporting lower packages)

  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh
  curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash
  source ~/.bashrc
  nvm list-remote
  nvm install v18.18.0
  node -v

4.go inside the folder and enter the environment variables needed in the project along with other modules.

5.Open the port 3000 and 8000 in security group Screenshot (163)

6.run the command inside the ec2 Screenshot (160)

6.Hit the public IP in the ec2 server

Screenshot (161)

Commands to run docker:

building image:

  docker build -t imagename:version .

eg: docker build -t himashree/onlinecoding_platform:latest .

to containeraise image:

  docker container run -d -p 3000:3000 -p 8000:8000 himashree/onlinecoding_platform:latest

additional command:

to check continers:

  docker container ls

About

An online coding platform where user can log in and select problem from problem list and code..Upon submission user gets the output.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published