An application continuum style example using Golang that includes a single web application with 2 background workers.
- Basic web application
- Data analyzer
- Data collector
The example showcases on the below technologies -
- Language golang Golang
- Web Framework Gorilla/mux
- Build tool Golang
- Testing tools Testify
- Production Google's Cloud Platform
Install the following prerequisites.
Create a user and database.
psql postgres < databases/create_databases.sql
Run the tests.
go clean -testcache && go test ./...
Run the apps locally.
go run cmd/basicwebapp/app.go
Build and run the apps locally.
go install cmd/basicwebapp/app.go
~/go/bin/app
Build with Pack.
pack build golang-starter --builder paketobuildpacks/builder:tiny
Modify you local database file permissions.
chmod 775 ./databases/docker/initdb.d/create-databases.sh
chmod 775 ./databases/docker/migrate-databases.sh
Run with docker compose.
docker-compose up
That's a wrap for now.