This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## | |
docker pull jseguillon/openbox || docker pull jseguillon/openbox:alpine | |
git clone https://gist.github.com/2c2b2220a4b9e294733e6ff09966f591.git dops-ren && cd dops-ren | |
## | |
ssh-keygen -f ./openstack -b 4096 | |
#ovh 4096 key | |
docker run -d -it --name dops-ren --mount type=bind,source="$(pwd)",target=/usr/share/source jseguillon/openbox:alpine | |
#Or non alpine |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#https://www.osboxes.org/ubuntu/ | |
#https://www.techrepublic.com/article/how-to-quickly-install-kubernetes-on-ubuntu/ | |
sudo apt-get update && apt-get install -y apt-transport-https && \ | |
sudo apt-get update && apt-get install -y apt-transport-https && \ | |
sudo apt install docker.io && \ | |
sudo systemctl start docker && \ | |
sudo systemctl enable docker && \ | |
sudo curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add && \ | |
deb http://apt.kubernetes.io/ kubernetes-xenial main && \ | |
sudo apt-get update && \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Use quick create like https://gist.github.com/jseguillon/a462aef872b2416b8042c07773626310 | |
# if you want Ubuntu 19 : follow this gist | |
# Remember modify VM before launching and NOT activate automatic login when installing if wanna use enhanced session mode ! | |
# Install shh server so it will be easy to copy-paste commands via Putty, until we have enhanced session installed | |
sudo apt install openssh-server | |
# Now we can connect through putty | |
# Do updates first |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# add second itf with staic ip for robust k8s | |
machine.trigger.after :up do |trigger| | |
trigger.run = {privileged: "true", powershell_elevated_interactive: "true", | |
path: "./addItfIfNotExists.ps1", args: ["-vmName", name, "-macAddrCtrlPlane", secondMac]} | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$countItf=(Get-VMNetworkAdapter -VMName $vmName | Where-Object {$_.MacAddress -match $macAddrCtrlPlane}).count | |
If ($countItf -ne 1) { | |
echo "Adding itf to vm" | |
Stop-VM -VMName $vmName | |
Add-VMNetworkAdapter -VMName $vmName -SwitchName "Default Switch" -StaticMacAddress $macAddrCtrlPlane |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PS C:\temp\2> New-Winspray-Cluster .\test.yml -Force | |
# Winspray - check env | |
Vagrant 2.2.6 | |
Client: Docker Engine - Community | |
Version: 19.03.8 | |
API version: 1.40 | |
Go version: go1.12.17 | |
Git commit: afacb8b | |
Built: Wed Mar 11 01:23:10 2020 | |
OS/Arch: windows/amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PS C:\temp\2> New-Winspray-Cluster .\test.yml -Force | |
# Winspray - check env | |
Vagrant 2.2.6 | |
Client: Docker Engine - Community | |
Version: 19.03.8 | |
API version: 1.40 | |
Go version: go1.12.17 | |
Git commit: afacb8b | |
Built: Wed Mar 11 01:23:10 2020 | |
OS/Arch: windows/amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PLAY [localhost] ************************************************************************************************************************* | |
Friday 30 October 2020 15:47:26 +0000 (0:00:00.468) 0:00:00.468 ******** | |
TASK [Check ansible version >=2.8.0] ***************************************************************************************************** | |
ok: [localhost] => { | |
"changed": false, | |
"msg": "All assertions passed" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: kubevirt.io/v1alpha3 | |
kind: VirtualMachine | |
metadata: | |
labels: | |
kubevirt.io/os: linux | |
name: centos7-master-x | |
spec: | |
running: true | |
template: | |
spec: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -L https://cloud.centos.org/centos/7/images/CentOS-7-x86_64-GenericCloud-2009.qcow2 -o CentOS-7-x86_64-GenericCloud-2009.qcow2 | |
cat <<EOF > Dockerfile | |
FROM kubevirt/registry-disk-v1alpha | |
COPY CentOS-7-x86_64-GenericCloud-2009.qcow2 /disk | |
EOF | |
docker build . -t kubevirt:centos-2009 |
OlderNewer