#Stay Standalone
A short script to prevent internal links to a "webapp" added to iPhone home screen to open in Safari instead of navigating internally.
<!DOCTYPE html> | |
<head> | |
<title>Stay Standalone</title> | |
<meta name="apple-mobile-web-app-capable" content="yes"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"> | |
<script src="stay_standalone.js" type="text/javascript"></script> | |
</head> | |
<body> | |
<ul> | |
<li><a href="http://google.com/">Remote Link (Google)</a></li> |
#Stay Standalone
A short script to prevent internal links to a "webapp" added to iPhone home screen to open in Safari instead of navigating internally.
Let’s say your GitHub username is “alice”. If you create a GitHub repository named alice.github.com, commit a file named index.html into the master branch, and push it to GitHub, then this file will be automatically published to http://alice.github.com/... The same works for organizations.
Read more here: http://pages.github.com/
However... the downside of this is that anyone that forks this repo won't get it as a GitHub Pages repo when they are working on it... because they have a different GitHub "username" (or "organisation name").
So the trick is to not use a master
branch as the documentation tells you... rather, use a gh-pages
branch, as you would for your other "Project Pages".
## Install a necessary packages | |
$ sudo apt-get install kvm cloud-utils genisoimage | |
## URL to most recent cloud image of 12.04 | |
$ img_url="http://cloud-images.ubuntu.com/server/releases/12.04/release" | |
$ img_url="${img_url}/ubuntu-12.04-server-cloudimg-amd64-disk1.img" | |
## download the image | |
$ wget $img_url -O disk.img.dist | |
## Create a file with some user-data in it |
upstream docker_registry { | |
server 127.0.0.1:15000; | |
} | |
server { | |
listen 443; | |
root /dev/null; | |
index index.html index.htm; |
... | |
# Fake a fuse install | |
RUN apt-get install libfuse2 | |
RUN cd /tmp ; apt-get download fuse | |
RUN cd /tmp ; dpkg-deb -x fuse_* . | |
RUN cd /tmp ; dpkg-deb -e fuse_* | |
RUN cd /tmp ; rm fuse_*.deb | |
RUN cd /tmp ; echo -en '#!/bin/bash\nexit 0\n' > DEBIAN/postinst | |
RUN cd /tmp ; dpkg-deb -b . /fuse.deb |
server { | |
listen 443; | |
server_name example.com; | |
client_max_body_size 0; | |
chunkin on; | |
ssl on; | |
ssl_certificate /path/to/crt; | |
ssl_certificate_key /path/to/key; |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Index</title> | |
<!-- Stand-alone settings for iOS. --> | |
<meta name="apple-mobile-web-app-capable" content="yes" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no" /> | |
<meta name="apple-mobile-web-app-status-bar-style" content="black" /> |
package rules; | |
import com.google.common.collect.Lists; | |
import com.google.common.collect.Maps; | |
import com.spotify.docker.client.DefaultDockerClient; | |
import com.spotify.docker.client.DockerClient; | |
import com.spotify.docker.client.DockerException; | |
import com.spotify.docker.client.messages.ContainerConfig; | |
import com.spotify.docker.client.messages.ContainerCreation; | |
import com.spotify.docker.client.messages.HostConfig; |
FROM php:5.6-apache | |
RUN apt-get update && apt-get install -y libpq-dev && docker-php-ext-install pdo pdo_pgsql | |
COPY src/ /var/www/html |