Giter VIP home page Giter VIP logo

pgsandbox's Introduction

pgSandbox

a first attempt at a database wrapper app over postgres

instructions

Change the values in appInfo.json. host should reflect the host where the app will be served and name should reflect the display name of the application. Also add a line sparkPostApiKey=thisIsYourKey, substituting your SparkPost API key, to the file .env, creating such a file if it doesn't exist.

to install Node and NPM

I recommend that you manage Node/NPM versions using NVM. Install it like so:

curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.29.0/install.sh | bash

After you've installed NVM, you'll need to start a new shell in order to use it. you can either close and reopen your shell or start a new one, like so:

bash

Next, use NVM to install the version of Node and NPM specified for the project.

nvm install

Use NVM to load Node and NPM into your PATH so that you can run Node and NPM commands. You'll need to do this in each new shell.

nvm use

to install dependencies

npm install

to set up the database

The app needs a local Postgres database named sandbox with user sandboxUser. To run the script that sets this up (including installing Postgres on Ubuntu):

npm run dbSetup

to create an SSL key and a self-signed certificate

npm run cert

to run the tests

npm test

to lint the code

npm run lint

to run the application

This will run the application synchronously.

sudo $(which node) index.js

Alternatively, this will run the application and free the current shell.

npm start

pgsandbox's People

Contributors

robertwarrengilmore avatar

Watchers

 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.