Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- su
- apt-get install sudo
- adduser motd sudo
- nano /etc/sudoers # Then add "motd ALL=(ALL:ALL) ALL" line, then save the file
- exit
- sudo apt-get update
- sudo apt-get install build-essential libssl-dev libsqlite3-dev openssl
- wget https://www.python.org/ftp/python/3.6.1/Python-3.6.1.tgz
- tar xzvf Python-3.6.1.tgz
- cd Python-3.6.1
- ./configure
- make
- sudo make install
- cd ..
- sudo apt-get install proftpd # Then select "inetd" option
- sudo nano /etc/proftpd/proftpd.conf # Then turn IPv6 support off
- sudo service proftpd restart
- ip addr
- sudo pip3 install virtualenv
- mkdir flask
- cd flask
- virtualenv venv
- source venv/bin/activate
- pip3 install flask
- pip3 install flask-sqlalchemy
- pip3 install uwsgi
- pip3 install path.py
- touch settings.py
- nano settings.py # Then add two following lines:
- SQLALCHEMY_DATABASE_URI = "sqlite:////home/motd/flask/database.db"
- SECRET_KEY = "(JUST ENTER RANDOM STUFF HERE)"
- uwsgi --master --http :8080 --http-websockets --wsgi-file application.py --venv venv --ugreen --async 100
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement