Skip to content

Instantly share code, notes, and snippets.

View zjx-immersion's full-sized avatar

钟健鑫(Jason) zjx-immersion

  • ThoughtWorks
  • Chengdu,China
View GitHub Profile
@wookiecooking
wookiecooking / hosx.sh
Last active January 21, 2020 23:44
Simple Installation of the latest Brew, Cask, Git, Node.js, and atom editor.
#!/bin/bash
<<COMMENT
# Simple Installation of the latest Brew, Cask, Git, Node.js, and atom editor. #
@Author: Austin Turnage
@License: MIT
# Example Usage #
Download Method::
Download this file, and from the directory, run in terminal
node {
// https://registry.hub.docker.com/_/maven/
def maven32 = docker.image('maven:3.2-jdk-7-onbuild');
stage 'Mirror'
// First make sure the slave has this image.
// (If you could set your registry below to mirror Docker Hub,
// this would be unnecessary as maven32.inside would pull the image.)
maven32.pull()
// We are pushing to a private secure docker registry in this demo.
@IndianGuru
IndianGuru / mongohqconnect.go
Created September 25, 2015 07:30
mongohqconnect.go
package main
import (
"fmt"
"gopkg.in/mgo.v2"
"gopkg.in/mgo.v2/bson"
"log"
"os"
)
@MrNice
MrNice / blogpost.md
Last active February 17, 2023 09:46
Explain how to think about ansible and how to use it

Ansible

Understanding Ansible

Ansible is a powerful, simple, and easy to use tool for managing computers. It is most often used to update programs and configuration on dozens of servers at once, but the abstractions are the same whether you're managing one computer or a hundred. Ansible can even do "fun" things like change the desktop photo or backup personal files to the cloud. It can take a while to learn how to use Ansible because it has an extensive terminology, but once you understand the why and the how of Ansible, its power is readily apparent.

Ansible's power comes from its simplicity. Under the hood, Ansible is just a domain specific language (DSL) for a task runner for a secure shell (ssh). You write ansible yaml (.yml) files which describe the tasks which must run to turn plain old / virtualized / cloud computers into production ready server-beasts. These tasks, in turn, have easy to understand names like "copy", "file", "command", "ping", or "lineinfile". Each of these turns into shell comma

@jgsqware
jgsqware / kubeadm-install-offline.md
Last active June 3, 2024 07:38
Offline Kubeadm install

On master and nodes

Pull images form internet access laptop

docker pull gcr.io/google_containers/kube-apiserver-amd64:v1.5.0
docker pull gcr.io/google_containers/kube-controller-manager-amd64:v1.5.0
docker pull gcr.io/google_containers/kube-proxy-amd64:v1.5.0
docker pull gcr.io/google_containers/kube-scheduler-amd64:v1.5.0
docker pull weaveworks/weave-npc:1.8.2
docker pull weaveworks/weave-kube:1.8.2
@madhur
madhur / clone.py
Created February 12, 2017 15:39
Bulk clone github repositories (including private)
import requests
import json
import subprocess
GITHUB_ORGANIZATION = "madhur"
ACCESS_TOKEN=""
CLONE_DIR="./"
r = requests.get("https://api.github.com/orgs/" + GITHUB_ORGANIZATION + "/repos?per_page=200&access_token=" + ACCESS_TOKEN)
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active July 24, 2024 08:58
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@chriscarlsondev
chriscarlsondev / MuchToDo-UserStories.md
Last active January 13, 2022 17:06
User Stories for the MuchToDo Todo List App
Role Task Importance
As a new user I want to sign up for an account High
As a returning user I want to add a new to do list item High
As a returning user I want to delete an existing to do list item High
As a returning user I want to update an existing to do list item High
As a returning user I want to check off a completed to do list item High
As a returning user I want to create categories for my to do list items Medium
As a returning user I want to assign a category to my to do list item Medium
As a returning user I want to assign a due date for my to do list item Medium