user-microservice

command module
v0.0.0-...-fdb0c6d Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2019 License: Apache-2.0 Imports: 8 Imported by: 0

README

USER microservice

Build Status Coverage Status FOSSA Status

user-microservice is a set of API to manage users.
This project is written in GO, it store data in dynamodb.

Start the project

You can build the project by using the command

make build

After that you can run the project by using (please configure you own env variables) :

export GIN_MODE: debug \
    && export APP_PORT: 8080 \
    && export RUNNING_MODE: api \
    && export DYNAMODB_ENDPOINT:http://localhost:9000 \
    && export AWS_REGION: eu-west-1 \
    && export DYNAMODB_TABLE_NAME: user \
    && ./user-microservice

If you want to use a local dynamodb

Run dynamodb-local on docker

docker run -d -p 9000:8000 amazon/dynamodb-local

Create a dynamodb table (you need AWS cli)

aws dynamodb create-table --table-name user \
    --attribute-definitions \
        AttributeName=id,AttributeType=S \
    --key-schema AttributeName=id,KeyType=HASH \
    --provisioned-throughput ReadCapacityUnits=1,WriteCapacityUnits=1 \
    --endpoint-url http://localhost:9000

Use swagger

Swagger is configure in the app you can access to the APIs to the URL : http://localhost:8080/swagger/index.html

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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