Softsuite - Start from gofiber boilerplate and plan to build large projects

Softsuite

Thanks to Cozy (ItsCosmas) to build gofiber boilerplate. I start learning gofiber because of its performance. Also, the following gofiber features could make the great projects.

  • Express-inspired
  • Robust routing
  • Serve static files
  • Extreme performance
  • API ready
  • Flexible middleware support
  • Low memory footprint
  • Template engine
  • Websocket support
  • Rate limiter

Running and Developing locally

  1. Create .env at src, i.e.
cp src/.env.example src/.env
  1. Download Swag for generating docs
go get -u github.com/swaggo/swag/cmd/swag
  1. Run
  • NOTE: You have to generate swagger docs before running the app.
# Terminal 1
swag init -g src/api/app.go --output ./src/api/docs # Generates Swagger

# Terminal 2
docker-compose --env-file ./src/.env up        # docker-compose up (Run App With AutoReload)
docker-compose --env-file ./src/.env down      # docker-compose down (Shutdown App)
  • API http://localhost:8000/api/v1
  • Swagger Doc http://localhost:8000/api/v1/docs

Packaging For Production

  1. Create .env at src, i.e.
cp src/.env.example src/.env
  1. Update your .env variables for production
  • Point to your prod database
  • Update JWT issuer, secret key , blah blah
  • Basically just follow good production practice
  1. Download Swag for generating docs
go get -u github.com/swaggo/swag/cmd/swag
  • Generate Swagger Docs. You have to generate swagger docs before packaging the app.
swag init -g src/api/app.go --output ./src/api/docs # Generates Swagger
  1. Build Your Image
  • Permission the build script to run.
chmod +x docker-build.sh

  • You could set the image port on Dockerfile.prod
  • Run the build script. You must provide a version tag as shown below.
./docker-build.sh -v gofiber:1.0.0
Owner
Mai
Cisco CCIE R&S #18148 and ReactJS Developer
Mai
Similar Resources

A tool to automate the setup and running of projects

Project CLI This project is still a work in progress but the mvp is working Are you tired of forgetting which commands to run or are you annoyed by th

Nov 30, 2021

Architecture checks for Go projects

Arch-Go Architecture checks for Go projects Supported rules Dependencies Checks Supports defining import rules Allowed dependencies Not allowed depend

Dec 20, 2022

General purpose reloader for all projects.

leaf General purpose reloader for all projects. Command leaf watches for changes in the working directory and runs the specified set of commands whene

Nov 8, 2022

Handy commands to run in Go projects

Handy commands to run in Go projects

Jan 3, 2023

Contextual information about your git projects, right on the command-line

Contextual information about your git projects, right on the command-line

gitty gitty is a smart little CLI helper for git projects, that shows you all the relevant issues, pull requests and changes at a quick glance. It cur

Jan 8, 2023

depstat is a dependency analyzer for Go modules enabled projects.

depstat is a dependency analyzer for Go modules enabled projects.

depstat is a dependency analyzer for Go modules enabled projects. It runs as part of the Kubernetes CI pipeline to help evaluate dependency updates to Kubernetes.

Nov 1, 2022

CLI for Setting up projects

CLI for Setting up projects

Lemonade CLI for setting up projects Installation Install lemonade into your local machine. Prerequisites: Go v1.16+ Download Go from golang.org Clone

Jan 8, 2022

Powerful CLI written in GO to generate projects in various technologies

Powerful CLI written in GO to generate projects in various technologies

Barca CLI is a project generator written in GO and its purpose is to build and configure HTTP servers, web proxy, SPA/PWA, Blog and custom landing page. It's easy, fast and productive.

Aug 26, 2022

Godzillacli - Create, Run Godzilla Projects Using Godzilla CLI

godzillacli Create, Run Godzilla Projects Using Godzilla CLI About: godzillacli

Jan 23, 2022
A tool to enumerate all the command-line arguments used to start a Linux process written in Go.
A tool to enumerate all the command-line arguments used to start a Linux process written in Go.

ranwith A tool to enumerate all the command-line arguments used to start a Linux process written in Go. ranwith uses the Linux /proc directory to obta

Jun 30, 2022
Start Go command line apps with ease
Start Go command line apps with ease

Start Start Go command line apps with ease Executive Summary The start package for Go provides two basic features for command line applications: Read

Oct 29, 2021
Vfkit - Simple command line tool to start VMs through virtualization framework

vfkit - Simple command line tool to start VMs through virtualization framework v

Oct 21, 2022
lls is lightweight ls. Using lls, you can get a list of files in a directory that contains a large number of files.

lls lls is lightweight ls. Using lls, you can get a list of files in a directory that contains a large number of files. How? You allocate a buffer for

Dec 29, 2022
Command-line tool to organize large directories of media files recursively by date, detecting duplicates.

go-media-organizer Command-line tool written in Go to organise all media files in a directory recursively by date, detecting duplicates.

Jan 6, 2022
A tool to manage all your boilerplate from cli and generate files for you !

A tool to manage all your boilerplate from cli and generate files for you !

Jul 20, 2022
Onion-Layer-Golang - A web application boilerplate built with go and clean architecture
Onion-Layer-Golang - A web application boilerplate built with go and clean architecture

go-clean-architecture-web-application-boilerplate A web application boilerplate

May 4, 2022
:zap: boilerplate template manager that generates files or directories from template repositories
:zap: boilerplate template manager that generates files or directories from template repositories

Boilr Are you doing the same steps over and over again every time you start a new programming project? Boilr is here to help you create projects from

Jan 6, 2023
create boilerplate structure for neovim plugins

boilit Boil yourself a sweet plugin Installation • Usage Ain't nobody got time to create plugin directories: boilit yourself! boilit creates boilerpla

Dec 28, 2022
Libraries and CLIs for my personal all-in-one productivity system including components like bookmarks, notes, todos, projects, etc.

bntp.go Libraries and CLIs for my personal all-in-one productivity system including components like bookmarks, notes, todos, projects, etc. Neovim int

Sep 13, 2022