This is a simple movie rental application API built in GO. The objective was to try and learn GO concepts. Apart from the api, it contains a worker that periodically send emails to defaulter every day.
It was built with lot of struggles and love โค๏ธ
NOTE
- Before the fourth step, you should have created a database for this application
- The supported database is Postgres
-
Clone this repo
git clone https://github.com/rammyblog/rent-movie
-
Change directory to project directory
cd rent-movie
-
Copy
.env
templatecp .env.example .env
-
Add correct database credentials to the
.env
file, credentials include:PORT
: This is the port the application will be served onDB_HOST
: This is your database host name/IP addressDB_NAME
: This is the name of the database created for the applicationDB_USER
: This is your database userDB_PORT
: This is your database portDB_PASS
: This is your database password if any, it should be left blank if no password is configured (localhost)JWT_SECRET
This is for auth.. You can put random string there
-
Seed Movies Data
make seed
-
Run application
make run
This will serve this application on the port you specified in the
.env
file.
The API is documented here ๐๐
https://documenter.getpostman.com/view/15213147/2s9YC1WuHX
Contributor Name | Role | Tool | Language(s) |
---|---|---|---|
Babatunde Onasanya | Developer | VSCode | Go |