pastebean

module
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 10, 2022 License: GPL-3.0

README

pastebean

Implementing a pastebin clone as a microservice architecture.
Written using go-gin and gorm alongwith many other awesome open source Go libaries. Served using envoy proxy. Containerized and orchestrated using docker and docker-compose.

Try it out

Run using:

docker-compose -f docker-compose.yaml up

Create a paste:

curl -XPOST localhost:8000/create --data-raw '{"name": "paste1", "body": "This is a big paste body."}'

Retrieve the above created paste using the returned uuid:

curl localhost:8000/<16-digit-uuid>
Services
  • Create: A service that creates paste.
  • Read: A service that reads created paste.
Architecture

pastebean architecture

Development
  • Requirements:

    • make
    • go 1.17
    • docker
    • docker-compose
  • Build and run on your host and be ready for being haunted by cloud native evangelists:

    make pastebean-dirty
    
  • Build and run it in containers using docker compose:

    make pastebean-dc-dev
    
TODO
  • Blog/tutorial series
  • Polygot services using different protocols
  • Users and authorization and authentication
  • Dyanmic Envoy configuration and service discovery
  • More container orchestrators
  • Service mesh

Directories

Path Synopsis
pkg

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL