Bringing readme up to date
This commit is contained in:
parent
f1bab89e11
commit
601a45c8ae
2 changed files with 27 additions and 3 deletions
29
README.md
29
README.md
|
@ -1,16 +1,32 @@
|
|||
# smash
|
||||
a bash.org clone built with Flask
|
||||
|
||||
## Technologies
|
||||
- python
|
||||
- Flask
|
||||
- PostgreSQL
|
||||
- SQLAlchemy
|
||||
|
||||
## Functionalities
|
||||
- Quote database
|
||||
- Tags for grouping and classifying quotes
|
||||
- Moderation queue, admin approval required for adding new quotes
|
||||
- Pagination
|
||||
- Ratings
|
||||
|
||||
## How to run
|
||||
This program is designed to be easy to deploy via Heroku. It can also run locally.
|
||||
Database is stored locally in an sqlite file.
|
||||
|
||||
First, you have to edit the config file (`config.json`). `DBNAME` needs to be a valid filename for the database. `APPNAME` is the name that will be displayed in the title bar in the browser, while `APPBRAND` is the name that will be displayed in the navbar on every page.
|
||||
First, you have to edit the config file (`config.json`). `APPNAME` is the name that will be displayed in the title bar in the browser, while `APPBRAND` is the name that will be displayed in the navbar on every page.
|
||||
|
||||
`SECRETKEY` will be used to encrypt and sign session cookies, so it needs to be a cryptographically-secure random string. `ADMINSECRET` will be used to elevate privileges to allow approving and deleting new quotes. There are no user accounts since there are no user-specific functionalities.
|
||||
|
||||
`MOTD` will be displayed on the index page.
|
||||
|
||||
`APPNAME` and `APPBRAND` will be loaded from the environment if they're left empty in the config.
|
||||
|
||||
Smash uses PostgreSQL. Before you start, you need to set `DATABASE_URL` environment variable to a valid URL leading to your database. If you install the Heroku plugin, it will be done automatically for you - you only need to do this manually if you want to run Smash locally.
|
||||
|
||||
After basic config is done, run this to start the server:
|
||||
|
||||
```
|
||||
|
@ -22,3 +38,12 @@ The program looks for `HEROKU` in the environment; if that variable is equal to
|
|||
The first time it's started it will create the local database and all required tables, as specified by models. After that it's ready to be used.
|
||||
|
||||
All logging is done by printing to stdout - heroku adds that to the app logs visible in the dashboard.
|
||||
|
||||
## Screenshots
|
||||

|
||||
|
||||

|
||||
|
||||

|
||||
|
||||

|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
{
|
||||
"APPBRAND": "",
|
||||
"APPNAME": "",
|
||||
"DBNAME": "smash.db",
|
||||
"SECRETKEY": "",
|
||||
"ADMINSECRET": "",
|
||||
"MOTD": "Welcome to the quote archive."
|
||||
|
|
Loading…
Add table
Reference in a new issue