Forum Backend API built with Golang, GIn Framework, GORM, PostgreSQL/MySQL
This is a forum API built with Golang
[Technologies · · Installations · · Tests · Author
https://github.com/victorsteven/Forum-App-Go-Backend.git
Ensure that you have your .env set up and have created your database
$ DB_HOST=127.0.0.1
In the root directory, run the command
$ go run main.go
http://localhost:8080
as base url for endpointsDocker is the default setting for this project
$ DB_HOST=forum-postgres
In the root directory, run the command:
$ docker-compose up --build
http://localhost:8888
as base url for endpointsNavigate to the tests directory and run
$ go test -v ./...
If you have set up the Dockerfile.test and the docker-compose.test.yml files above, from the root directory of the app.
$ docker-compose -f docker-compose.test.yml up --build