- Updated on May 29 to accommodate etcd container not having
/bin/shavailable anymore.
curl -sL https://get.rke2.io | sh
systemctl daemon-reload
systemctl start rke2-server
| #!/bin/bash | |
| set -eu -o pipefail | |
| export CERT_URL='https://dl.dod.cyber.mil/wp-content/uploads/pki-pke/zip/unclass-certificates_pkcs7_DoD.zip' | |
| # Download & Extract DoD root certificates | |
| cd ~/Downloads/ || exit 1 | |
| /usr/bin/curl -LOJ "${CERT_URL}" |
TCL-Expect scripts are an amazingly easy way to script out laborious tasks in the shell when you need to be interactive with the console. Think of them as a "macro" or way to programmaticly step through a process you would run by hand. They are similar to shell scripts but utilize the .tcl extension and a different #! call.
The first step, similar to writing a bash script, is to tell the script what it's executing under. For expect we use the following:
#!/usr/bin/expect
| $webclient = New-Object System.Net.WebClient | |
| $url = "https://github.com/darkoperator/Posh-SSH/archive/master.zip" | |
| Write-Host "Downloading latest version of Posh-SSH from $url" -ForegroundColor Cyan | |
| $file = "$($env:TEMP)\Posh-SSH.zip" | |
| $webclient.DownloadFile($url,$file) | |
| Write-Host "File saved to $file" -ForegroundColor Green | |
| $targetondisk = "$($env:USERPROFILE)\Documents\WindowsPowerShell\Modules" | |
| New-Item -ItemType Directory -Force -Path $targetondisk | out-null | |
| $shell_app=new-object -com shell.application | |
| $zip_file = $shell_app.namespace($file) |
| /* -- Media Queries ----------------------------------------------------- */ | |
| /* ---------------------------------------------------------------------- */ | |
| /* Large screens ----------- */ | |
| @media only screen | |
| and (min-width : 1824px) { | |
| /* Styles */ | |
| } | |
| /* Desktops and laptops ----------- */ |
| Select all and delete (actually move to buffer) | |
| :%d | |
| Select all and copy to buffer | |
| :%y | |
| Use p to paste the buffer. |