Quick guide to setup and make a server "secure"
From: https://support.rackspace.com/how-to/configuring-basic-security/
Once you get your root access to the server, that's cool but not very safe.
Change password
### If the server is accessed throught the dev URL example.dev | |
### User will need to authenticate. | |
SetEnvIf Host ^example\.dev$ require_auth=true | |
AuthUserFile /Path/To/.htpasswd | |
AuthName "Password Protected" | |
AuthType Basic | |
# Setup a deny/allow | |
Order Deny,Allow |
# This creates a mp3 folder and will put mp3 files in it after conversion; Requires ffmpeg and libmp3lame codec | |
# Found in the comments here: http://www.boback.com/2013/how-to-convert-flac-to-mp3-ubuntu-command-line/ | |
# Change the quality using the qscale parameter or change it to -b:a 320k to convert to 320kbps bitrate (see https://trac.ffmpeg.org/wiki/Encode/MP3) | |
mkdir mp3 && for f in *.flac; do ffmpeg -i "$f" -codec:a libmp3lame -qscale:a 2 -map_metadata 0 "mp3/${f%.*}".mp3; done |
FROM php:7.0-apache | |
MAINTAINER louwii@louwii.fr | |
# Install PHP extensions and PECL modules. | |
RUN buildDeps=" \ | |
libbz2-dev \ | |
libmysqlclient-dev \ | |
libcurl4-gnutls-dev \ | |
" \ | |
runtimeDeps=" \ |
# Edit your crontab file using crontab -e command | |
# | |
# Example of job definition: | |
# .---------------- minute (0 - 59) | |
# | .------------- hour (0 - 23) | |
# | | .---------- day of month (1 - 31) | |
# | | | .------- month (1 - 12) OR jan,feb,mar,apr ... | |
# | | | | .---- day of week (0 - 6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri,sat | |
# | | | | | | |
# * * * * * user-name command to be executed |
Quick guide to setup and make a server "secure"
From: https://support.rackspace.com/how-to/configuring-basic-security/
Once you get your root access to the server, that's cool but not very safe.
Change password
#!/bin/sh | |
# Empty all rules | |
sudo iptables -t filter -F | |
sudo iptables -t filter -X | |
# Bloc everything by default | |
sudo iptables -t filter -P INPUT DROP | |
sudo iptables -t filter -P FORWARD DROP | |
sudo iptables -t filter -P OUTPUT DROP |