Skip to content

Commit

Permalink
Release v1.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
app-generator committed May 25, 2022
1 parent eb925b1 commit b6c4f69
Show file tree
Hide file tree
Showing 219 changed files with 41,842 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
DEBUG=True

# Flask ENV
FLASK_APP=run.py
FLASK_ENV=development

# Used for CDN (in production)
ASSETS_ROOT=/static/assets # !!! Without Slash at the end !!!
13 changes: 13 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
flask/
*.pyc
dev
node_modules
app/database.db
app/build
yarn.lock
yarn-error.log
*.psd
env/
env__/
.vscode/symbols.json
app/db.sqlite3
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Change Log

## [1.0.3] 2022-05-25

- Built with [Black Dashboard Generator](https://appseed.us/generator/black-dashboard/)
- Timestamp: `2022-05-25 09:31`
- Codebase Improvements
- Assets Management via `.env`
- `ASSETS_ROOT` variable

## [1.0.2] 2022-05-20

- Version built with [Black Dashboard Generator](https://appseed.us/generator/black-dashboard/)
Expand Down
14 changes: 14 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
FROM python:3.9

COPY . .

# set environment variables
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1

# install python dependencies
RUN pip install --upgrade pip
RUN pip install --no-cache-dir -r requirements.txt

# gunicorn
CMD ["gunicorn", "--config", "gunicorn-cfg.py", "run:app"]
32 changes: 32 additions & 0 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# MIT License

Copyright (c) 2019 - present [AppSeed](http://appseed.us/)

<br />

## Licensing Information

<br />

| Item | - |
| ---------------------------------- | --- |
| License Type | MIT |
| Use for print | **YES** |
| Create single personal website/app | **YES** |
| Create single website/app for client | **YES** |
| Create multiple website/apps for clients | **YES** |
| Create multiple SaaS applications | **YES** |
| End-product paying users | **YES** |
| Product sale | **YES** |
| Remove footer credits | **YES** |
| --- | --- |
| Remove copyright mentions from source code | NO |
| Production deployment assistance | NO |
| Create HTML/CSS template for sale | NO |
| Create Theme/Template for CMS for sale | NO |
| Separate sale of our UI Elements | NO |

<br />

---
For more information regarding licensing, please contact the AppSeed Service < *support@appseed.us* >
1 change: 1 addition & 0 deletions Procfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
web: gunicorn run:app --log-file=-
193 changes: 193 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,193 @@
# [Black Dashboard](https://appseed.us/generator/black-dashboard/) Flask/Jinja

Open-source **Flask/Jinja Template** generated by `AppSeed` op top of **[Black Dashboard](https://appseed.us/generator/black-dashboard/)**, a modern `Bootstrap` dashboard design. The project is a super simple Flask project WITHOUT database, ORM, or any other hard dependency. The project can be used as a codebase for future project or to migrate the Jinja files and assets to a legacy Python-based project that uses Jinja as template engine (Flask, Bottle, Django).

<br />

> Built with [Black Dashboard Generator](https://appseed.us/generator/black-dashboard/)
- Timestamp: `2022-05-25 09:31`
- Build ID: `71447494-cfd1-4127-a04a-ca740b1be8bb`
- **Free [Support](https://appseed.us/support/)** (registered users) via `Email` and `Discord`

<br />

> Features
- `Up-to-date dependencies`
- Render Engine: Flask / [Jinja2](https://jinja.palletsprojects.com/)

<br />

![Black Dashboard - Full-Stack Starter generated by AppSeed.](https://user-images.githubusercontent.com/51070104/169471556-144ea706-0965-4f7d-8493-da9570085367.png)

<br />


## ✨ Start the app in Docker

> **Step 1** - Download the code from the GH repository (using `GIT`)
```bash
$ # Get the code
$ git clone https://github.com/appseed-projects/<YOUR_BUILD_ID>.git
$ cd <YOUR_BUILD_ID>
```

<br />

> **Step 2** - Edit `.env` and set `DEBUG=True`. This will activate the `SQLite` persistance.
```txt
DEBUG=True
```

<br />

> **Step 3** - Start the APP in `Docker`
```bash
$ docker-compose up --build
```

Visit `http://localhost:85` in your browser. The app should be up & running.

<br />


## ✨ How to use it

> Download the code
```bash
$ # Get the code
$ git clone https://github.com/appseed-projects/71447494-cfd1-4127-a04a-ca740b1be8bb.git
$ cd 71447494-cfd1-4127-a04a-ca740b1be8bb
```

<br />

### 👉 Set Up for `Unix`, `MacOS`

> Install modules via `VENV`
```bash
$ virtualenv env
$ source env/bin/activate
$ pip3 install -r requirements.txt
```

<br />

> Set Up Flask Environment
```bash
$ export FLASK_APP=run.py
$ export FLASK_ENV=development
```

<br />

> Start the app
```bash
$ flask run
```

At this point, the app runs at `http://127.0.0.1:5000/`.

<br />

### 👉 Set Up for `Windows`

> Install modules via `VENV` (windows)
```
$ virtualenv env
$ .\env\Scripts\activate
$ pip3 install -r requirements.txt
```

<br />

> Set Up Flask Environment
```bash
$ # CMD
$ set FLASK_APP=run.py
$ set FLASK_ENV=development
$
$ # Powershell
$ $env:FLASK_APP = ".\run.py"
$ $env:FLASK_ENV = "development"
```

<br />

> Start the app
```bash
$ flask run
```

At this point, the app runs at `http://127.0.0.1:5000/`.

<br />

## ✨ Code-base structure

The project has a simple, intuitive structure presented bellow:

```bash
< PROJECT ROOT >
|
|-- apps/__init__.py
|-- apps/
| |-- static/
| | |-- <css, JS, images> # CSS files, Javascripts files
| |
| |-- templates/
| |
| |-- includes/ # Page chunks, components
| | |
| | |-- navigation.html # Top bar
| | |-- sidebar.html # Left sidebar
| | |-- scripts.html # JS scripts common to all pages
| | |-- footer.html # The common footer
| |
| |-- layouts/ # App Layouts (the master pages)
| | |
| | |-- base.html # Used by common pages like index, UI
| | |-- base-fullscreen.html # Used by auth pages (login, register)
| |
| index.html # The default page
| page-404.html # Error 404 page (page not found)
| page-500.html # Error 500 page (server error)
| *.html # All other pages provided by the UI Kit
|
|-- requirements.txt
|
|-- run.py
|
|-- ************************************************************************
```

<br />

## ✨ PRO Version

> For more components, pages and priority on support, feel free to take a look at this amazing starter:
Black Dashboard is a premium Bootstrap Design now available for download in Django. Made of hundred of elements, designed blocks, and fully coded pages, Black Dashboard PRO is ready to help you create stunning websites and web apps.

- 👉 [Black Dashboard PRO Flask](https://appseed.us/product/black-dashboard-pro/flask/) - Product Page
- 👉 [Black Dashboard PRO Flask](https://flask-black-dashboard-pro.appseed-srv1.com/) - LIVE Demo

<br >

![Black Dashboard PRO - Full-Stack Starter generated by AppSeed.](https://user-images.githubusercontent.com/51070104/169471630-e96cec9b-ef57-4c06-9b36-62b9bbf255f3.png)

<br />

---
[Black Dashboard](https://appseed.us/generator/black-dashboard/) Flask/Jinja - Open-source starter generated by **[AppSeed Generator](https://appseed.us/generator/)**.
20 changes: 20 additions & 0 deletions apps/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# -*- encoding: utf-8 -*-
"""
Copyright (c) 2019 - present AppSeed.us
"""

import os

# import Flask
from flask import Flask

from .config import Config

# Inject Flask magic
app = Flask(__name__)

# load Configuration
app.config.from_object( Config )

# Import routing to render the pages
from apps import views
18 changes: 18 additions & 0 deletions apps/config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# -*- encoding: utf-8 -*-
"""
Copyright (c) 2019 - present AppSeed.us
"""

import os

class Config(object):

basedir = os.path.abspath(os.path.dirname(__file__))

DEBUG = (os.getenv('DEBUG', 'False') == 'True')

# Assets Management
ASSETS_ROOT = os.getenv('ASSETS_ROOT', '/static/assets')

# App Config - the minimal footprint
SECRET_KEY = os.getenv('SECRET_KEY', 'S#perS3crEt_9999')
Empty file added apps/static/assets/.gitkeep
Empty file.
Loading

0 comments on commit b6c4f69

Please sign in to comment.