Git Product home page Git Product logo

palmquist's Introduction

palmquist

This webapp is a rewrite of the Beinecke Library legacy application Palmquist. The project can be built using Maven, and the resulting .war file can be dropped into Tomcat (or just launched with java). The stack is Spring Boot/MVC/Data.

The html files are in src/main/resources/templates.

All the backend logic is in package edu.yale.

Installation

  • Install Maven (and JDK). Download sqljdbc4 from [Microsoft] (https://www.microsoft.com/en-us/download/details.aspx?id=11774).

  • Specify the path to the database connection properties file in src/main/java/edu/yale/DatabaseInitializer class.

  • Specify either db.prop for "brothers server" or aws.prop for AWS RDS database called palmquist.

  • Copy the file to /tmp directory and make sure it matches DatabaseInitializer (e.g., /tmp/aws.prop in both places)

  • Build and Launch
# only the 1st time
mvn install:install-file -Dfile=sqljdbc4.jar -DgroupId=com.microsoft.sqlserver -DartifactId=sqljdbc4 -Dversion=4.0 -Dpackaging=jar

# go into the folder:
cd palmquist

# run the build and package it
mvn clean install

# to test it:

java -jar target/palmquist-0.0.1-SNAPSHOT.war

Deployment to AWS

For the remote server, scp to the AWS server the .war in target/ to /usr/share/tomcat/webapps, and rename it as ROOT.war so it deploys as the default context, as follows:

scp -i yul-palmquist-prod-app.pem palmquist/target/palmquist-0.0.1-SNAPSHOT.war [email protected]:/tmp/ROOT.war
scp -i yul-palmquist-prod-app.pem palmquist/src/main/resources/aws.prop [email protected]:/tmp

The folder where you're running this command should have the .pem file. Check paths to make sure you can reach the .war file.

We're copying the aws.prop file to /tmp/aws.prop, so that it can pick up db properties on load. You can delete it afterwards once the app is up and running.

Once you've copied (using scp) these files, log into AWS, and copy the .war file to /usr/share/tomcat/webapps. It will automatically expand the .war file to full directory. The app should now be running at 8080.

Try it

palmquist's People

Contributors

osmandin avatar tmacmath avatar osmandin1 avatar

Watchers

 avatar James Cloos 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.