Starter project template using the following libraries/frameworks:
Services for CI & CD:
To get the project, you need to install Go and set your Go workspace (i.e. $GOPATH
) first.
$ go get github.com/app8izer/go-gin-ng6-starter
Alternatively, use git to clone the project:
$ git clone https://github.com/app8izer/go-gin-ng6-starter.git
If not yet installed, install govendor via:
$ go get -u github.com/kardianos/govendor
To install the golang dependencies, run
$ govendor sync
in root of project.
If not yet installed, install node + npm/yarn, e.g. for Mac OS run
$ brew install yarn
which will also install Node.js if it is not already installed.
To install the Angular dependencies, run
$ cd ./frontend
$ yarn install
in root of project.
If not yet installed, install protoc, e.g. for Mac OS:
$ brew install protoc
To compile the schema to Go and Typescript sources run
$ cd ./proto
$ sh ./compile_proto.sh
in root of project.
To start the application with PostgreSQL database, Golang backend, and Angular frontend, the following steps are required.
Run
$ docker-compose -f docker-compose.dev.yml
in root of project directory.
This will fire up a database listening on port 5432
of your localhost
.
To start the backend server on port 8080
run
$ cd ./backend
$ go run main.go
in root of project directory.
To start the frontend server on port 4200
run
$ cd ./frontend
$ yarn run dev
in root of project directory.