This is a front-end (HTML, CSS, front-end frameworks like Bootstrap) and back-end (Python with Jinja2 and Google App Engine - GAE) project intended to provide a blog tool. The blog only allows text content for both posts and comments. User can edit/delete posts and comments, also like other user's posts. Users can registrate themselves using just username and password, e-mail is optional. Sensitive information (like password) of the blog is stored using hash algorithms.
This project use external library other than the ones included in Python Source Libraries. The external libraries are:
- google.appengine
- jinja2
- webapp2
Please make sure to have it installed before moving forward. Aditional instructions on how to install GAE (MacOS ONLY) are provided below:
- Install Python. Specific version 2.7 in order to the GAE SDK to work properly
- Install Google Cloud SDK and follow the instructions in this page
- After the installation, from the terminal, run the command
gcloud components install app-engine-python
- Make yourself a new GAE project
- Ok, time to test it.
You can test a fully working live demo following these steps:
- Open a terminal and check Python is installed and running properly
- You can try 'python --version' in terminal and check the output
- Go to
/project
folder in terminal - Verify you can run the command below.
dev_appserver.py
- No errors should araise and
localhost:8080
is up and running
You can deploy a fully working live app following these steps:
- Go to
/project
folder in terminal - Set a default project where you want to deploy the application (after creating it):
gcloud config set project <your_project_name>
- Verify you can run the command below and insert
Y
for the input after running itgcloud app deploy
- VERY IMPORTANT STEP: GAE uses index on tables to improve performance and make sure users are not consuming a lot
of resources (freemium account, so don't abuse rule :) ). The file
index.yaml
must be sent to the server. Just run:gcloud datastore create-indexes index.yaml
- Wait for some time until the indexes are updated and created. You can follow the status in here
- No errors should araise and your project should be running on
https://<your_gae_project>.appspot.com
Click above and feel free to get in touch in case of trouble or suggestions.