Estimated time: 10 minutes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
yum update -y | |
yum install -y httpd | |
echo '<h1>Hello World</h1>' > /var/www/html/index.html | |
systemctl start httpd | |
systemctl enable httpd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
exports.handler = (event, context, callback) => { | |
// Get request and request headers | |
const request = event.Records[0].cf.request; | |
const headers = request.headers; | |
// Configure authentication | |
const authUser = 'user'; | |
const authPass = 'pass'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
## this little Gist is for Copy the Letsencrypt Cert from an Linux machine (e.g. Raspberry PI or Synology NAS) | |
## to the router (Fritzbox). | |
## It is usefull to be able to speak to the Router over DDNS without any Cert issue in the Browser. | |
## thanks to https://gist.github.com/mahowi for the perfect Idea | |
## put it in /etc/letsencrypt/renewal-hooks/post so it gets run after every renewal. | |
## since Fritz OS 7.25 it is needed to select a Username, from a security point of view | |
## it is always a good idea to have a non default user name. And as normaly a Fritz Box | |
## is connected to the Internet, the prefered method should be WITH Username. |
This will create a proxy server in whatever your availability zone your VPC is in. For me, that's us-east-1b
. For you, that may be something different. Steps 10+ should more or less work regardless of your provider since those steps cover the setup and configuration of TinyProxy.
- Click the Launch Instance button.
- Choose Ubuntu Server 14.04 LTS (HVM), SSD Volume Type. This isn't strictly necessary. If you choose another OS, check its documentation for how to install new packages.
- On the Choose an Instance Type screen, select t2.micro. It's Free Tier eligible.
- Click the Next: ... buttons until you reach the Configure Security Group screen.
- You may wish to reduce the amount of storage on the Add Storage screen. This is optional.
- You may wish to add a tag on the Tag Instance screen. This is also optional.
- On the Configure Security Group screen:
- Select Create a new security group.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from area53 import route53 | |
from boto.route53.exception import DNSServerError | |
import requests | |
import sys | |
from datetime import datetime | |
# Modified from https://markcaudill.me/blog/2012/07/dynamic-route53-dns-updating-with-python/ | |
domain = 'domain.tld' | |
subdomain = 'subdomain_name' |