Skip to content

Instantly share code, notes, and snippets.

View groundnuty's full-sized avatar

groundnuty groundnuty

  • ACC Cyfronet AGH
  • Kraków
View GitHub Profile
#! /bin/bash
#
#
# Installing doker on ubuntu.
# edit sudo vim /etc/systemd/system/multi-user.target.wants/docker.service
# and change -d with daemon
# then sudo service docker restart && sudo service docker status
#
#
set -eo pipefail
@groundnuty
groundnuty / redirect.json
Last active April 10, 2017 02:50
AGH redirect articles BG
{
"createdBy": "Redirector v3.1.0",
"createdAt": "2016-09-13T20:04:09.442Z",
"redirects": [
{
"description": "springer",
"exampleUrl": "https://link.springer.com/a",
"exampleResult": "http://wbg2.bg.agh.edu.pl/han/springer/https/link.springer.com/a",
"error": null,
"includePattern": "https://link.springer.com/*",
@groundnuty
groundnuty / test.sh
Last active September 21, 2016 23:41
git-annex rsync ssh synology
# server
if [[ $(hostname) == 'OrzechStation' ]]; then
rm -rf ~/a
mkdir ~/a
cd ~/a
git init
git annex init 'server'
dd if=/dev/zero of=test bs=1024 count=0 seek=$[1024*10]
git annex add test
git commit -am 'first!'
# It's not possible to declare a pod with path to a file, a content would have to be: cat file | base64
# ssh-keyscan github.com >> /home/ubuntu/yamls/known_hosts
# kubectl create secret generic github-test-repo-deploy-key --from-file=id_rsa=/root/.ssh/id_rsa --from-file=id_rsa.pub=/root/.ssh/id_rsa.pub --from-file=known_hosts=/home/ubuntu/yamls/known_hosts
#
# kubectl create secret docker-registry docker-onedata-org-morzech --docker-username=xxx --docker-password=xxx --docker-email=xxx --docker-server=docker.onedata.org
#
# NAME="docker.onedata.org/morzech/data-container:$(date +'%Y-%m-%d-%H-%M-%S')-r$RANDOM" ; docker build /dcv -q -t "$NAME" ; docker push "$NAME"
#apiVersion: v1
#kind: Secret
@groundnuty
groundnuty / serviceaccount_fix.yaml
Created April 4, 2017 07:20
helm 2.2.3 fix for kubernetes 1.6 rbac
---
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1beta1
metadata:
name: default-readonly-role
rules:
- verbs: ["get"]
nonResourceURLs: ["*"]
---
apiVersion: rbac.authorization.k8s.io/v1beta1
@groundnuty
groundnuty / wave1_6.yaml
Last active August 11, 2017 09:27
cyfronet-1 wave for k8s 1.6
apiVersion: v1
kind: List
items:
- apiVersion: v1
kind: ServiceAccount
metadata:
name: weave-net
annotations:
cloud.weave.works/launcher-info: |-
{
@groundnuty
groundnuty / prov.yaml
Created July 14, 2017 18:14
local volumes test
---
apiVersion: apps/v1beta1
kind: StatefulSet
metadata:
name: local-test
spec:
serviceName: "local-service"
replicas: 1
template:
metadata:
@groundnuty
groundnuty / iperf_tcpprobe.yml
Created August 15, 2017 21:43
tcpprobe for debuging kubernetes networking
# tcpprobe https://wiki.linuxfoundation.org/networking/tcpprobe
# use: apt install module-init-tools
# to install modprobe
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
annotations:
deployment.kubernetes.io/revision: "1"
generation: 1
labels:
@groundnuty
groundnuty / calico.yaml
Last active December 11, 2018 07:30
canal network with subnets changed
# This ConfigMap is used to configure a self-hosted Calico installation.
kind: ConfigMap
apiVersion: v1
metadata:
name: calico-config
namespace: kube-system
data:
# The location of your etcd cluster. This uses the Service clusterIP
# defined below.
etcd_endpoints: "http://10.96.232.136:6666"
@groundnuty
groundnuty / onedata_replication_cheatsheet.md
Last active February 27, 2018 10:33
Onedata replications cheatsheet

Envs we will need

OZ_HOST="90.147.170.26"

TOKEN='MDAxNWxvY2F00aW9uIG9uZXpvbmUKMDAzYmlkZW500aWZpZXIga3c00QXExOTJQUXd4SHRyalBxcXlFS1NWWldSeVM3bHFaSWVDTHVQQVZaNAowMDFhY2lkIHRpbWUgPCAxNTM3NDUwNjkzCjAwMmZzaWduYXR1cmUgIh2n5CILKKXUbtEZC01tmQzQEgcq27gnTWV0102J6WMzegK'

SPACEID="S-HHji1RCFgGlGsTJ4kZ23Jiu6vhvVI74PRaGLuJSVg"

HOST="oneprovider.cesnet.cz"