How to make simple key value based checklist api with golang stdlib for not master users?
- InMemory database (with bg save option).
- Set, Get, GetAll, Del, Stats, Flush methods allowed.
- POST and GET methods are equal. Use the method which you prefer most. (whatever you want)
- Logged all requests
- Postman Collections, Docker, Local and DO Server build option is ready to use
- No UI only restful api (Sorry)
- Thats its all :)
Without build
go run . --addr ":3000" --dbpath "./store.db" --bgsave 1m0s --logpath "./service-http.log"
Open your browser and go to localhost:3000
Welcome Home
Ready to use
Select below one of them for easy installation.
- Docker Build First Have to download and install Docker Desktop App
If you want build image only
docker build -t my-mini-checklist .
After run the command
docker-compose up --build
Finish the install and only one container is up Open your browser and go to localhost:3000
Welcome Home
Ready to use
- Local Build
Run sh command for generate executable "my-mini-checklist" file to build folder
./build.sh my-mini-checklist
Run the server with options
cd build
chmod +x my-mini-checklist
./my-mini-checklist --addr ":3000" --dbpath "./store.db" --bgsave 1m0s --logpath "./service-http.log"
Open your browser and go to localhost:3000
Welcome Home
Ready to use
- Github Actions Deploy DO Server (ASAP)
NOT READY
-
Postman collection file for all routes is ready to import.
- Pls go to docs folder and import "My-Mini-Checklist.postman_collection.json" file to Postman App -> Collection Tab in your computer
- Go to Postman App -> Enviroments tab. Import all environments "My-Mini-Checklist Dev Env.postman_environment.json", "My-Mini-Checklist Prod Env.postman_environment.json", "My Workspace.postman_globals.json"
- Run the "my-mini-checklist" server which deploy process you choose
- Select "My-Mini-Checklist" collection folder in Postman App
- Select "Prod or Dev Environment" (right up side the header)
- Click the "Run" button (right up side the header)
- Good lock
NOTE: If not selected environment, Postman collections always request localhost:3000
- Run Go test command
go test
or more detail option:
go test -v
or
go test -v --race
Distributed under the MIT License. See LICENSE for more details.