Skip to content

Instantly share code, notes, and snippets.

View yun14u's full-sized avatar

P T Nguyen yun14u

  • texas
View GitHub Profile
@yun14u
yun14u / pod.yaml
Created October 22, 2019 17:06 — forked from matthewpalmer/pod.yaml
Example Kubernetes pod for the multi-container sidecar design pattern
# Example YAML configuration for the sidecar pattern.
# It defines a main application container which writes
# the current date to a log file every five seconds.
# The sidecar container is nginx serving that log file.
# (In practice, your sidecar is likely to be a log collection
# container that uploads to external storage.)
# To run:
@yun14u
yun14u / SakaiUtil.java
Created December 28, 2016 17:32 — forked from chaitut715/SakaiUtil.java
get calendar events of a user in sakai
package com.chaitu.lmscalendar.sakai.util;
import android.util.Log;
import com.chaitu.lmscalendar.settings.Settings;
import com.fasterxml.jackson.databind.ObjectMapper;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
@yun14u
yun14u / startup_mailer.py
Last active December 20, 2016 17:32 — forked from johnantoni/startup_mailer.py
raspberry pi - send email on startup (will need gmail account to send from)
import httplib2
import os
import subprocess
import datetime
import oauth2client
from oauth2client import client, tools
import base64
from email.mime.multipart import MIMEMultipart
from email.mime.text import MIMEText
from apiclient import errors, discovery