A baseline installation of a Linux distribution on a virtual machine
- Apache HTTP Server with mod_wsgi
- OpenSSH
- PostgreSQL
Docker Compose is required to run this app. Please refer to Install Docker Compose if you don't have one on your system.
Then, clone this repository and generate keys for SSH:
$ git clone https://github.com/wulab/nd004-linux-server-configuration.git
$ cd nd004-linux-server-configuration
$ ssh-keygen -f app/grader
To run the app, issue the following command:
$ docker-compose up
The command will create an app
service, start SSH server on port 2200 and
HTTP server on port 80 and 443.
Using a browser, go to http://localhost
and you'll see an example page. To
log into SSH server under grader
account, run:
$ ssh -i app/grader -p 2200 grader@localhost
Press Ctrl+C
to stop the service. If you want to clean up everything, use:
$ docker-compose down --rmi local --volumes
ip6tables v1.6.0: can't initialize ip6tables table `filter': Table does not exist (do you need to insmod?)
Try issuing a few ufw commands on your host machine to auto-load the module:
$ ufw default deny incoming
$ ufw allow www
$ ufw enable