Giter VIP home page Giter VIP logo

deploy-linux-server's Introduction

deploy-linux-server

  1. The IP address and SSH port.
  • 18.216.188.87:2200
  1. The complete URL to the hosted web application.
  1. A list of third-party resources.

All system packages have been updated to most recent versions.

  1. sudo apt-get update
  2. sudo apt-get upgrade
  3. sudo apt autoremove
  4. sudo reboot

Change ssh port from 22 to 2200

  1. sudo nano /etc/ssh/sshd_config
  2. Under the line: "# What ports, IPs and protocols we listen for". Modify Port 22 to Port 2200.
  3. Restart ssh sudo /etc/init.d/ssh restart

Setting firewall on ubuntu.

  1. sudo ufw default deny incoming
  2. sudo ufw default allow outgoing
  3. sudo ufw allow www
  4. sudo ufw allow 2200/tcp
  5. sudo ufw allow 123/tcp
  6. sudo ufw enable
  7. sudo reboot

Give grader access.

  1. sudo adduser grader
  2. sudo nano /etc/sudoers.d/grader, Add grader ALL=(ALL) NOPASSWD:ALL in /etc/sudoers.d/grader
  3. Create a public key on localhost.
  4. Type following command as root to allow grader login into instance.
  • cd /home/grader
  • sudo mkdir .ssh
  • sudo nano .ssh/authorized_keys
  1. copy public key and paste to .ssh/authorized_keys
  2. Login as grader and change the owner of public key to grader.
  • sudo chown grader:grader .ssh
  • sudo chown grader:grader .ssh/authorized_keys
  • chmod 644 .ssh/authorized_keys
  • chmod 700 .ssh

Configure the local timezone to UTC.

  • sudo timedatectl set-timezone Etc/UTC

Install and configure Apache to serve a Python mod_wsgi application.

  • sudo apt-get install apache2
  • sudo apt-get install libapache2-mod-wsgi

Install python packges

  • sudo apt-get -qqy install python python-pip
  • pip install --upgrade pip
  • sudo pip install flask packaging oauth2client redis passlib flask-httpauth
  • sudo pip install sqlalchemy flask-sqlalchemy psycopg2 bleach requests

Set up catalog web application.

  1. Follow tutorial to set up flaskapp.
  2. Clone catalog app to /var/www/FlaskApp/FlaskApp
  3. sudo a2dissite 000-default.conf
  4. sudo service apache2 restart

deploy-linux-server's People

Contributors

billytseng avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.