Skip to content

Instantly share code, notes, and snippets.

View jermdw's full-sized avatar
😺

jermdw jermdw

😺
View GitHub Profile
@jermdw
jermdw / docker-compose.yml
Created October 31, 2018 01:50
Nextcloud Docker Compose manifest
version: '2'
volumes:
nextcloud:
db:
services:
db:
image: mariadb
restart: always
@jermdw
jermdw / checker.json
Created October 30, 2018 03:23
Checker JSON Configuration
{
"checkers": [{
"type": "http",
"endpoint_name": "Website",
"endpoint_url": "http://www.example.com",
"attempts": 5
}],
"storage": {
"provider": "s3",
"access_key_id": "<yours>",
@jermdw
jermdw / install_docker.ps1
Last active September 4, 2018 00:43
Install Docker on Windows
Invoke-WebRequest
-UseBasicParsing
-Method GET
-Uri "https://master.dockerproject.org/windows/x86_64/docker.zip"
-OutFile "$env:TEMP\docker.zip"
Expand-Archive -Path "$env:TEMP\docker.zip"
-DestinationPath $env:ProgramFiles
$env:path += ";c:\program files\docker"
[Environment]::SetEnvironmentVariable("Path", $env:Path + ";
C:\Program Files\Docker", [EnvironmentVariableTarget]::Machine)
@jermdw
jermdw / join_domain.ps1
Created August 28, 2018 14:45
Join AD Domain
# Join AD Domain Powershell Script
# j3rmbadger
Add-computer –domainname lab.local -Credential LAB1\netsecadmin -restart –force
@jermdw
jermdw / 10-static-en.network
Last active August 26, 2018 17:01
Photon-OS Static IP Configuration
cat > /etc/systemd/network/10-static-en.network << "EOF"
[Match]
Name=eth0
[Network]
Address=192.168.1.12/24
Gateway=192.168.1.1
DNS=192.168.1.5
EOF
@jermdw
jermdw / docker-compose.yml
Created August 14, 2018 22:36
Graylog docker-compose configuration
version: '2'
services:
mongodb:
image: mongo:3
volumes:
- mongo_data:/data/db
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:5.6.9
volumes:
- es_data:/usr/share/elasticsearch/data
@jermdw
jermdw / A_Profile_Sigma.ps1
Created August 8, 2018 03:01 — forked from i-e-b/A_Profile_BJSS.ps1
My sample Powershell profile script
# Sigma profile
Import-Module W:\Gits\posh-git\posh-git.psm1
set-executionpolicy Unrestricted process
$baseDir = Split-Path -parent $MyInvocation.MyCommand.Definition
. "$baseDir\hand.ps1"
# General actions
function edit ($file) { & "${env:ProgramFiles(x86)}\Notepad++\notepad++.exe" $file }
@jermdw
jermdw / red_root_prompt.md
Created August 7, 2018 04:57
Bash - Red Root Prompt

Prompt is green for standard user and turns red when elevated to root

PS1='${debian_chroot:+($debian_chroot)}\[\033[01;31m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '

PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '

Reference

Byobu is a suite of enhancements to tmux, as a command line
tool providing live system status, dynamic window management,
and some convenient keybindings:
F1 * Used by X11 *
Shift-F1 Display this help
F2 Create a new window
Shift-F2 Create a horizontal split
Ctrl-F2 Create a vertical split
Ctrl-Shift-F2 Create a new session
@jermdw
jermdw / 01-netcfg.yaml
Created June 24, 2018 02:01
Netplan Configuration File
network:
version: 2
renderer: networkd
ethernets:
ens160:
addresses:
- 192.168.1.93/24
gateway4: 192.168.1.1