Coder Social home page Coder Social logo

go-crud-k8s-demo's Introduction

go-crud-k8s-demo

A very basic demo for a CRUD API built in golang and interfacing with a Postgresql DB

Originally, the intended purpose of this small demo app was to showcase a simple way to provision k8s resources on-demand for feature branches, however the demo may be interesting beyond that use-case, so I've decided to make it available here.

Please note that the example is still WIP and the application currently only exposes two very simple GET endpoints and does not cache anything.

Configuration Options

The easiest way to configure the application is to set the appropriate environment variables.

Available options:
APPLICATION_PORT Port the application server binds to (default: 8080)
ENABLE_DEV Set dev environment
ENABLE_TRACE If set, logger is configured to print file and line it is called from DB_TIMEOUT Database timeout in seconds
DB_HOST Database Hostname DB_PORT Database Port
DB_USER Database User DB_PASS Database Password
DB_NAME Database Name DB_SSL_DISABLE disable ssl mode

Testing locally

You can get started by navigating to the migrations folder and running the run_migration.sh script. It will download the test data, launch a postgres container based on the official image and load the test data to the database

go-crud-k8s-demo's People

Contributors

agschrei avatar

Watchers

 avatar

Forkers

wenj91

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.