Giter Club home page Giter Club logo

ramengo's Introduction

LET THE GAMES BEGIN with RAMENGO

This repository is an attempt to showcase few of my Golang skills. Let the games begin!

Where is it hosted?

The following endpoint is hosted in a free cloud service (the cold start takes around 50 seconds):

https://ramengo-03li.onrender.com

SETUP (to run locally)

Requires Go 1.22 or higher.
Set the .env file using the .env.example as a template.

How to run (OPTION 1 - MAKE)

Just run the following commands:

# Clone the repository
git clone [email protected]:matsuboshi/ramengo.git

# Change to the project directory
cd ramengo

# Set the .env file
cp .env.example .env

# Export the environment variables
source ./scripts/export_envs.sh

# Run the application
make run

Then follow the instructions along.

How to run (OPTION 2 - DOCKER)

Just run the following commands:

# Clone the repository
git clone [email protected]:matsuboshi/ramengo.git

# Change to the project directory
cd ramengo

# Set the .env file
cp .env.example .env

# Build the image, create and run the container
docker-compose up -d --build

Then follow the instructions to test the API.

When you are done testing, you can stop and remove the container:

# Stop and remove the container
docker-compose down

How to test (CURL)

RouteCURL
GET broths
curl http://localhost:8080/broths -X GET \
-H 'x-api-key: ZtVdh8XQ2U8pWI2gmZ7f796Vh8GllXoN7mr0djNf'
GET proteins
curl http://localhost:8080/proteins -X GET \
-H 'x-api-key: ZtVdh8XQ2U8pWI2gmZ7f796Vh8GllXoN7mr0djNf'
POST order
curl http://localhost:8080/order -X POST \
-H "x-api-key: ZtVdh8XQ2U8pWI2gmZ7f796Vh8GllXoN7mr0djNf" \
-H "Content-Type: application/json" \
-d '{"brothId": "1", "proteinId": "1"}'

Happy testing!

ramengo's People

Contributors

matsuboshi avatar

Stargazers

Lucas Daniel avatar  avatar

Watchers

 avatar

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.