Chromium OS is cool. Chromium OS with crouton is cooler. Chromium OS with Docker is even cooler. This is specifically a guide for the Chromebook Pixel 2 (2015), but I can't think of any reason it wouldn't work with other devices.
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
# | |
# fair-queue based settings for EdgeRouter Lite traffic shaping | |
# | |
# download is typically 30 and change. everything can burst to 100% | |
# of bandwidth, priority rules keep the garbage in check | |
set traffic-policy shaper download | |
set traffic-policy shaper download bandwidth 30Mbit |
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
# goes in /etc/nginx/sites-available & link in ../sites-enabled | |
upstream graphite { | |
server unix:///tmp/uwsgi.sock; | |
} | |
server { | |
listen 9002; | |
server_name localhost; |
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
# This is the main configuration file for Spigot. | |
# As you can see, there's tons to configure. Some options may impact gameplay, so use | |
# with caution, and make sure you know what each option does before configuring. | |
# For a reference for any variable inside this file, check out the Spigot wiki at | |
# http://www.spigotmc.org/wiki/spigot-configuration/ | |
# | |
# If you need help with the configuration or have any questions related to Spigot, | |
# join us at the IRC or drop by our forums and leave a post. | |
# | |
# IRC: #spigot @ irc.esper.net ( http://webchat.esper.net/?channel=spigot ) |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<configuration> | |
<properties> | |
<property name="name">app</property> | |
<property name="pattern">%d{yyyy-MM-dd HH:mm:ss.SSS} | %-5.5p | %-10.10t | %-20.20C:%-5.5L | %msg%n</property> | |
<!-- | |
It will look like that: | |
2013-04-03 07:37:51.993 | WARN | main | lnetgateway.Server:56 | My app is logging stuff | |
--> | |
</properties> |
A lot of times you are developing a web application on your own laptop or home computer and would like to demo it to the public. Most of those times you are behind a router/firewall and you don't have a public IP address. Instead of configuring routers (often not possible), this solution gives you a public URL that's reverse tunnelled via ssh to your laptop.
Because of the relaxation of the sshd setup, it's best used on a dedicated virtual machine just for this (an Amazon micro instance for example).
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 | |
# bash generate random alphanumeric string | |
# | |
# bash generate random 32 character alphanumeric string (upper and lowercase) and | |
NEW_UUID=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) | |
# bash generate random 32 character alphanumeric string (lowercase only) | |
cat /dev/urandom | tr -dc 'a-z0-9' | fold -w 32 | head -n 1 |
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
<?php | |
if(isset($_POST['zipcode']) && is_numeric($_POST['zipcode'])){ | |
$zipcode = $_POST['zipcode']; | |
}else{ | |
$zipcode = '50644'; | |
} | |
$result = file_get_contents('http://weather.yahooapis.com/forecastrss?p=' . $zipcode . '&u=f'); | |
$xml = simplexml_load_string($result); | |
//echo htmlspecialchars($result, ENT_QUOTES, 'UTF-8'); |
NewerOlder