Skip to content

Instantly share code, notes, and snippets.

View tobyapi's full-sized avatar
:octocat:
octocat

tobya tobyapi

:octocat:
octocat
View GitHub Profile
@ipmb
ipmb / settings.py
Last active October 24, 2025 14:36
Django logging example
import logging.config
import os
from django.utils.log import DEFAULT_LOGGING
# Disable Django's logging setup
LOGGING_CONFIG = None
LOGLEVEL = os.environ.get('LOGLEVEL', 'info').upper()
logging.config.dictConfig({
@savelee
savelee / Array.sql
Created February 22, 2017 09:43
BigQuery Array Struct example
#standardSQL
#Top two Hacker News articles by day
WITH TitlesAndScores AS (
SELECT
ARRAY_AGG(STRUCT(title,
score)) AS titles,
EXTRACT(DATE
FROM
time_ts) AS date
FROM
@markjlorenz
markjlorenz / simple-exec-with-docker-remote-api.sh
Created July 23, 2016 16:05
Using the exec command with the docker API, and capturing output
#! /usr/bin/env bash
# Create the container with a long running process. If PID1 exists before
# we send the exec commands, they will fail because the container is not running
#
CONTAINER_NAME="TEST-`uuidgen`"
curl --silent --unix-socket /var/run/docker.sock "http:/containers/create?name=${CONTAINER_NAME}" -XPOST \
-H "Content-Type: application/json" \
-d '{
"Image": "ruby:latest",
@andreicristianpetcu
andreicristianpetcu / ansible-summary.md
Created May 30, 2016 19:25
This is an ANSIBLE Cheat Sheet from Jon Warbrick

An Ansible summary

Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)

Configuration file

intro_configuration.html

First one found from of

@uemuraj
uemuraj / coturn.md
Last active December 27, 2020 00:47
TURNサーバの構築

TURNサーバの構築

WebRTCを使ってみよう! で紹介されている rfc5766-turn-server は既に更新が終わり、別のプロジェクトになっています。

coturn を代わりに使用します。 https://github.com/coturn/coturn/wiki/Downloads から最新バージョンをダウンロードしてビルドします。

※ダウンロードページに turnserver-*-amazon-aws-ec2-x86_64.txt というファイルあり! EC2 ではこの内容にも注意すること

ビルドに必要なパッケージをインストール

@PurpleBooth
PurpleBooth / README-Template.md
Last active December 10, 2025 21:19
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@yudai
yudai / gist:6f8f44ac878c41eaf7dc
Last active November 7, 2023 08:35
Google v. Oracle API著作権裁判

Oracle v. GoogleのAPI著作権裁判の話

OracleとGoogleの判決文を斜め読む」を読んで裁判の経緯は理解できたものの、判決の詳細があまり理解できなかったので判決文を自分で読んだ。法律的な難しさはあまりなく、技術的な論点と関係する条文および過去の判例などが非常にわかりやすく解説されており、判決の根拠もたとえ話を交えて書かれているなど非常に読みやすい印象を受けた。

全体の内容としては比較的単純で「あらゆるプログラムのコードは著作権で保護される。ただしFair Useによる合法的な利用に関しては差し戻し審で審議せよ」という事のようだ。実は「API」という言葉は一切判決文には出てこないため、内容を良く読む必要がある。

17 U.S.C. 102(b)を巡るGoogleの主張

@voluntas
voluntas / mqtt.rst
Last active February 15, 2025 04:35
MQTT とはなんだったのか

MQTT とはなんだったのか

更新:2017-05-09
作者:@voluntas
バージョン:3.14
URL:http://voluntas.github.io/

MQTT をググって調べた人向け

@sile
sile / 0_raft.md
Last active May 27, 2024 07:53
Raft(分散合意アルゴリズム)について
@voluntas
voluntas / new_to_mqtt.rst
Last active October 2, 2023 06:26
初めての MQTT