Code Monkey home page Code Monkey logo

asset-manager's Introduction

Asset Manager

Spring boot application to:

  • Upload assets
  • List uploaded assets
  • Archive assets

Requirements

  • JDK 1.8
  • Maven 3
  • Mongo 3.6

Testing the application:

At the project root level, run: mvn test

To run tests and build:

At the project root level, run: mvn clean install

To run locally:

  1. Install mongo 3.6

  2. Specify the following properties in src/main/resources/application.properties

    • aws.access.key.id={AWS_ACCESS_KEY}
    • aws.access.key.secret={AWS_SECRET_KEY}
    • aws.s3.bucket.name={AWS_BUCKET_NAME}
    • aws.region={AWS_REGION}
  3. At the project root level run:

    mvn spring-boot:run

    OR

    At the project root level:

    build: mvn clean install
    run: ./target/assetmanager.jar OR java -jar target/assetmanager.jar

To run on container:

Ensure docker and docker-compose is installed on the system
  • Add AWS details in docker-compose.yml file with
    • AWS_ACCESS_KEY
    • AWS_SECRET_KEY
    • AWS_BUCKET
    • AWS_REGION
At the project root level, run command:

docker-compose up

To deploy on an instance

  1. Ensure mongo service running and java 8 installed
  2. Copy the assetmanager.jar from target to the directory where you want to deploy
  3. run java -jar -Dspring.data.mongodb.database={db_name} -Dspring.data.mongodb.host={mongo_host} -Dspring.data.momgodb.port={mongo_port} -DAWS_ACCESS_KEY={your_access_key} -DAWS_SECRET_KEY={your_secret_key} -DAWS_BUCKET={bucket_name} -DAWS_REGION={aws_region_name} assetmanager.jar >> assetmanager.log &

api to run health check for the application

http://host:port/actuator/health

To test api-s, swagger is integrated which is accessible on

http://host:port/swagger-ui.html

asset-manager's People

Contributors

abhayprakashtiwari avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

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.