jq is useful to slice, filter, map and transform structured json data.
brew install jq
OpenLDAP | |
基本的には書籍p.476-の手順に従っている。 | |
パッケージインストール | |
sudo yum install openldap-servers openldap-clients libtool-ltdl | |
サービス自動起動 | |
sudo systemctl enable slapd.service |
Step by step how to pull a private DockerHub hosted image in a Kubernetes YML. | |
export DOCKER_REGISTRY_SERVER=https://index.docker.io/v1/ | |
export DOCKER_USER=Type your dockerhub username, same as when you `docker login` | |
export DOCKER_EMAIL=Type your dockerhub email, same as when you `docker login` | |
export DOCKER_PASSWORD=Type your dockerhub pw, same as when you `docker login` | |
kubectl create secret docker-registry myregistrykey \ | |
--docker-server=$DOCKER_REGISTRY_SERVER \ | |
--docker-username=$DOCKER_USER \ |
docker run \ | |
--name {{printf "%q" .Name}} \ | |
{{- with .HostConfig}} | |
{{- if .Privileged}} | |
--privileged \ | |
{{- end}} | |
{{- if .AutoRemove}} | |
--rm \ | |
{{- end}} | |
{{- if .Runtime}} |
# import config. | |
# You can change the default config with `make cnf="config_special.env" build` | |
cnf ?= config.env | |
include $(cnf) | |
export $(shell sed 's/=.*//' $(cnf)) | |
# import deploy config | |
# You can change the default deploy config with `make cnf="deploy_special.env" release` | |
dpl ?= deploy.env | |
include $(dpl) |
#!/bin/sh | |
## Fonction pour générer un password. | |
## "randpw" pour générer un mot de passe aléatoire de 32 caractères | |
## "randpw <n>" pour générer un mot de passe aléatoire de <n> caractères | |
randpw(){ < /dev/urandom tr -dc _A-Z-a-z-0-9 | head -c${1:-32};echo;} | |
## Définir les mots de passe et les exporter pour qu'ils soient visibles des scripts. | |
cat > passwords << EOF | |
DATA_CONFIG_PASSWORD=`randpw` | |
DATA_ADMIN_PASSWORD=`randpw` | |
DATA_SERVICE_PASSWORD=`randpw` |
The repository for the assignment is public and Github does not allow the creation of private forks for public repositories.
The correct way of creating a private frok by duplicating the repo is documented here.
For this assignment the commands are:
git clone --bare [email protected]:usi-systems/easytrace.git
#!groovy | |
import groovy.json.JsonOutput | |
import groovy.json.JsonSlurper | |
def label = "mypod-${UUID.randomUUID().toString()}" | |
podTemplate(label: label, yaml: """ | |
spec: | |
containers: | |
- name: mvn | |
image: maven:3.3.9-jdk-8 |
#!/bin/bash | |
USER=${1:-sebble} | |
STARS=$(curl -sI https://api.github.com/users/$USER/starred?per_page=1|egrep '^Link'|egrep -o 'page=[0-9]+'|tail -1|cut -c6-) | |
PAGES=$((658/100+1)) | |
echo You have $STARS starred repositories. | |
echo |
pipeline { | |
agent any | |
parameters { | |
string(defaultValue: '', description: 'The name of the organization working on this repository.', name: 'orgName') | |
} | |
stages{ | |
stage("Create Repo Piplines") { | |
steps { |