go-starter-project

command module
v1.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 28, 2020 License: MIT Imports: 2 Imported by: 0

README

Go-Starter-Project

Template of a generic project written in GO Go Build Status codecov Go Report Card Maintainability

The project uses Echo

For reading the .env file is used gotenv

Functionality 🍹

  • Definition of controllers
  • Definition of controllers GET and POST, in any case it is possible to define further methods
  • Data manipulation system retrieved from database MYSQL
  • Timed remote data recovery system
  • Queue request system
  • Configuration cache system via .env file
  • Database migration system

Installation

  • Clone or download the project in your own GOPATH
  • Download all dependecies with
go get -d ./...
  • Build the application
go build main.go
  • Ready to Go!

Configuration

In the root directory is present a .env.sample

export APP_NAME="Go-Starter-Project"
export STRING_CONNECTION="root:root@tcp(127.0.0.1:3306)/test?parseTime=true"
export APP_PORT=:8888
export USER_TIME_TO_REFRESH=30

Copy and rename in .env and fill with whatever you like

Useful commands

To interact with the application you need to FIRE!

Use the following command:

./Go-Starter-Project -fire

This will show the following message

commands:
  -fire go!         -> start the Server 
  -fire go-migrate  -> migrate database 
  -fire go-rollback -> rollback database 
  -fire go-config   -> show the current environment 

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL