Skip to content

Instantly share code, notes, and snippets.

@vsc1t
vsc1t / terraform_vscale_provider.sh
Created July 7, 2019 06:05
Terraform add vscale provider
#!/usr/bin/env bash
# Automatic install vscale provider for terraform
# GOPATH should be configured before launch
source ~/.profile
sudo apt-get update && sudo apt-get install git -y && \
mkdir -p "$GOPATH"/src/github.com/terraform-providers/terraform-provider-vscale && \
git clone https://github.com/burkostya/terraform-provider-vscale.git \
"$GOPATH"/src/github.com/terraform-providers/terraform-provider-vscale && \
@vsc1t
vsc1t / terraform_install.sh
Created July 7, 2019 06:03
Terraform 12.3 install and configure
#!/usr/bin/env bash
# Install and configure terraform for Linux 64-bit
PLUGINS_CACHE_DIR='$HOME/.terraform.d/plugin-cache'
TERRAFORM_VERSION='terraform_0.12.3_linux_amd64.zip'
TERRAFORMRC="$HOME/.terraformrc"
TERRAFORM_LOCATION="$HOME/.local/bin"
EXPORT_LOCAL_PATH='export PATH=$PATH:'"$LOCAL_PATH"
@vsc1t
vsc1t / Install_go.sh
Created July 7, 2019 06:01
Easiest install and configure GO on Ubuntu
#!/usr/bin/env bash
# Install GO for Ubuntu 18.04
# First argument spcify GOPATH varibale
# By default GOPATH=~/go
if [ "$1" ] ; then
GO_DIR=$1
else
GO_DIR='$HOME/go'
@vsc1t
vsc1t / sshd_config
Created September 19, 2018 19:31
simple sshd config
PermitRootLogin prohibit-password
PubkeyAuthentication yes
ChallengeResponseAuthentication no
PasswordAuthentication no
UsePAM no
X11Forwarding yes
PrintMotd no
Banner none
AcceptEnv LANG LC_*
Subsystem sftp /usr/lib/openssh/sftp-server
@vsc1t
vsc1t / .bashrc
Last active November 15, 2019 20:02 — forked from zachbrowne/The Ultimate Bad Ass .bashrc File
bashrc file
#!/bin/bash
iatest=$(expr index "$-" i)
#######################################################
# SOURCED ALIAS'S AND SCRIPTS BY zachbrowne.me
#######################################################
# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
@vsc1t
vsc1t / tmux-cheatsheet.markdown
Created August 17, 2018 07:01 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@vsc1t
vsc1t / tmux-cheats.md
Created August 17, 2018 07:01 — forked from Starefossen/tmux-cheats.md
My personal tmux cheat sheet for working with sessions, windows, and panes. `NB` I have remapped the command prefix to `ctrl` + `a`.

Sessions

New Session

  • tmux new [-s name] [cmd] (:new) - new session

Switch Session

  • tmux ls (:ls) - list sessions
  • tmux switch [-t name] (:switch) - switches to an existing session