Skip to content

Instantly share code, notes, and snippets.

@chenhan1218
chenhan1218 / WebRTC-on-LAN.md
Last active September 23, 2022 07:43
WebRTC on LAN

WebRTC on LAN

剛嘗試了怎麼樣在區域網路中使用 WebRTC 來進行 VOIP,意外發現其實滿簡單的。分享一下我的步驟

P.S 這是提供給外部網路不通的環境下,如果外部網路通暢,那麼可以直接用現有服務,如 https://talky.io/ 即可

架起 WebRTC Signal Server

git clone https://github.com/andyet/signalmaster
@smoser
smoser / lxc-clone-readme.sh
Last active December 20, 2015 21:48
Demonstrate lxc clone via overlayfs and ubuntu-cloud clone hook supporting user-data.
###
### Fast cloning with overlayfs, and specifying user-data on clone
### blog post:
### http://ubuntu-smoser.blogspot.com/2013/08/lxc-with-fast-cloning-via-overlayfs-and.html
###
### Eventually, this should make it into 13.10 and the stable lxc ppa
### https://launchpad.net/~ubuntu-lxc/+archive/stable
### But right now you'll have to use the daily ppa.
@mems
mems / gist:5301297
Last active February 23, 2022 13:12
How to convert a (simple) SWF to PDF

Convert (simple) SWF to PDF

In SWFTools a programs called gfx2gfx is available to do this task, but it's not officially available precompiled.

It can convert SWF, PDF or image to SWF, PDF, ebook or image.

For discard downscaling for rasterized image (default: 72dpi) we use the provided by @m-p-y: add -r attribute to increase maxdpi

Requirements

@orita
orita / virt-install_ubuntu12
Created June 27, 2012 02:01
virt-install ubuntu 12.04 with virtio
mkdir -p /data/kvm/images/ubuntu12/
qemu-img create -f qcow2 /data/kvm/images/ubuntu12/boot.img 10G
virt-install --connect qemu:///system \
--arch=x86_64 \
--accelerate \
--name ubuntu12 \
--ram=1024 \
--vcpus=2 \
--hvm \
@rstacruz
rstacruz / index.md
Last active November 3, 2023 09:56
Rails models cheatsheet

Rails Models

Generating models

$ rails g model User

Associations

belongs_to

has_one