No description
Find a file
2021-11-08 02:34:32 +01:00
database/migrations Stuff 2021-11-08 02:25:36 +01:00
pkg Stuff 2021-11-08 02:25:36 +01:00
static init 2021-11-03 02:10:36 +01:00
templates Logout 2021-11-04 03:04:05 +01:00
vendor Stuff 2021-11-08 02:25:36 +01:00
.gitignore init 2021-11-03 02:10:36 +01:00
docker-compose.yml Stuff 2021-11-08 02:25:36 +01:00
go.mod Stuff 2021-11-08 02:25:36 +01:00
go.sum Stuff 2021-11-08 02:25:36 +01:00
layoutmiddleware.go init 2021-11-03 02:10:36 +01:00
main.go Stuff 2021-11-08 02:25:36 +01:00
readme.md Stuff 2021-11-08 02:34:32 +01:00

Sample Webapplication in Go

Sample Webapplication in go, create a kind of skeleton for monolith webapplicaion. Useed to create a small MVP Project.

Structur

Create (self contained) pkg for a group of pages. The pkg included the View and Go files for the Pages e.g. user pages.

Including Packages

Features

Global Layout

The "globale layout" is put arround each response from a pkg web response. It read the response buffer from and use the content to parse the layout.tmpl. It works via middelware

JWT-Auth

todo

Migrations

Its possitlbe to execute the migrations via go run ./ migrate. It execute the migration files in database/migrations/*.sql

One Binary

Everything (include templaes and migration) can be added in one binary

Make commands

todo

Dev

Test für das entwickeln von Monolith webanwendung mit html gui in go.

Es gibt unabhängige packages im pkg ordner die eine oder mehrere seiten beinhalten können. Jedes pkg beinhaltet alles um funktionieren zu können.

Das layout gibt es einmal zentral und wird per chi middelware reingereicht.

Alles ist in einem binary

next steps

  • conifg per env
  • makefile
  • ci/Cd bis docker image bauen