go.blueprint
A golang project blueprint.
Getting Started
Run the application:
make go-run
Execute the tests:
make go-test
Docker
Build the Docker image:
make docker-build
Run the Docker image:
make docker-run
Directory Structure
build
contains all shell scripts needed to build and test the application.cmd
contains the source code! By convention, the source directory is namedcmd
, within, there is another directory with the name of the project - in this caseblueprint
. This directory contains themain.go
file that runs the Go application. The rest of the source is further divided into modules in this directory.config
contains files with all required environment variables.pkg
contains a Go package that only contains the global app version string. This is substituted for the actual version computed from the commit hash during build.
Contribution Guidelines
Never commit directly to master, create a feature branch and submit a pull request.