Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #! /bin/bash
- # !!This must be run as root!! #
- # The USB drive at this point should be manually mounted to /media/cdrom #
- # Create post_install directory in users home directory
- mkdir /home/admin/post_install
- # Copy post_install archive to home directory
- cp /media/cdrom/post_install/snapshot.tar /home/admin/post_install/
- # Untar snapshot.tar archive
- cd /home/admin/post_install
- tar xvf snapshot.tar
- # Add local repo to apt-get sources.list and update apt database
- echo "deb file:/home/admin/post_install/apt_install/archives /" | tee -a /etc/apt/sources.list
- apt-get update
- # Install required packages
- apt-get install -y --allow-unauthenticated build-essential nginx postgresql python python-dev python-pip upstart-sysv python-psycopg2
- # Install python modules using PIP
- pip install --no-index --find-links /home/admin/post_install/pip_install/ uwsgi
- pip install --no-index --find-links /home/admin/post_install/pip_install/ flask
- pip install --no-index --find-links /home/admin/post_install/pip_install/ flask_restful
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement