Skip to content

Instantly share code, notes, and snippets.

View eohtake's full-sized avatar

Eric Ohtake eohtake

View GitHub Profile
# This file is loaded from /etc/systemd/system/kubelet.service.d/10-kubeadm.conf if file /etc/default/kubelet is present.
KUBELET_EXTRA_ARGS='--cloud-provider=vsphere --cloud-config=/etc/kubernetes/vsphere.conf'
# EXAMPLE:
# Note: This dropin only works with kubeadm and kubelet v1.11+
[Service]
Environment="KUBELET_KUBECONFIG_ARGS=--bootstrap-kubeconfig=/etc/kubernetes/bootstrap-kubelet.conf --kubeconfig=/etc/kubernetes/kubelet.conf"
Environment="KUBELET_CONFIG_ARGS=--config=/var/lib/kubelet/config.yaml"
# This is a file that "kubeadm init" and "kubeadm join" generates at runtime, populating the KUBELET_KUBEADM_ARGS variable dynamically
@eohtake
eohtake / docker-k8s.sh
Created August 21, 2019 06:38
Docker configuration for Kubernetes - Ubuntu
#!/bin/bash
# Install Docker CE
## Set up the repository:
### Install packages to allow apt to use a repository over HTTPS
apt-get update && apt-get install apt-transport-https ca-certificates curl software-properties-common
### Add Docker’s official GPG key
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -
#!/usr/bin/ruby
#
#
# author: Eric Ohtake
#
# The custom fact fetches the Java Plugin 64 bits version currently installed on the system.
#
## Key for the version v8u65 HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Products\4EA42A62D9304AC4784BF2681408560F
## Key for the version v8u66 HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Products\4EA42A62D9304AC4784BF2681408660F
��Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Products\4EA42A62D9304AC4784BF2681408560F]
"ProductName"="Java 8 Update 65 (64-bit)"
"PackageCode"="58120268773BBA643A5B6C50FD355630"
"Language"=dword:00000409
"Version"=dword:0800028a
"Assignment"=dword:00000001
"AdvertiseFlags"=dword:00000184
"ProductIcon"="C:\\Program Files\\Java\\jre1.8.0_65\\\\bin\\javaws.exe"
#!/usr/bin/ruby
#
#
# author: Eric Ohtake
#
# The custom fact fetches the Java Plugin 64 bits version currently installed on the system.
#
## Key for the version v8u65 HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Products\4EA42A62D9304AC4784BF2681408560F
## Key for the version v8u66 HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Installer\Products\4EA42A62D9304AC4784BF2681408660F
#!/usr/bin/ruby
#
#
#
# This custom fact fetches the Java Plugin 32 bits version currently installed on the system.
#
Facter.add("javaplugin32") do
confine :kernel => :windows
javaplugin32 = "unknown"
class javaplugin32 {
package { 'Java 8 Update 66' :
ensure => installed,
source => '\\FILE-SERVER\Software\Java\Plugins\jre-8u66-windows-i586.exe',
install_options => ['/s'],
notify => Exec['Uninstall Previous Version']
}
exec { 'Uninstall Previous Version' :
command => 'MsiExec.exe /qn /X{26A24AE4-039D-4CA4-87B4-2F83218060F0} /norestart',
path => 'C:\windows\system32',