Code Monkey home page Code Monkey logo

catalogapp's Introduction

Catalog App

Catalog App is an application that provides a list of items within a variety of categories as well as provide a user registration and authentication system. Registered users will have the ability to post, edit and delete their own items.

Installation

Python==3 or greater
$ pip install -r requirements.txt

Set up the database

in this app I use PostgreSQL, with user grader
You can modify database setting at database.py if you use different database or different user name
to initiate database, run $ python init_db.py

Usage

Once installed the packages and set up your database, run $ python views.py to start flask server.
you can then open main page at http://localhost:8000/ , inside the main page, click Register button to register a new user or click login button to login with google sign in.
To fetch json data of a catalog, go to http://localhost:8000/api/catalog/catalog-name/items/json
you can get item detail in json format by typing http://localhost:8000/api/item/item-slug/json

after logged in, click your name at the header section to open console page, at console page, you will be able to create, edit, delete catalogs or items there, you can also go to console page by typing http://localhost:8000/my-console at your browser.

Deployment

This App is deployed at Amazon Lightsail on Ubuntu 16.04
Web server: Apache2 ip address: 13.59.217.2
URL: skynet.run
The web server responds on port 80
At the server side, I created a new user and given sudo access, also allow the new user to ssh the server with modified port. The fire wall had set to only allow SSH, HTTP and NTP.

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.