Skip to content

Instantly share code, notes, and snippets.

# ilsap - Intellij License Server Active Proxy
#
# Since Jetbrains started to blacklist license servers by hostname, it's being a pain in the ass
# to find a working one. So this is an active proxy for Intellij license servers, that masks
# a license server into your localhost. Just create a startup script to call ilsap,
# configure your IDE to activate from the localhost and YOLO!
#
require "http/server"
require "http/client"
<#
Create Unix VM's.
PREREQUISITES:
- A VM that has been installed with an OS that supports cloud-init
- cloud-init is installed on the vm
How it works:
- Asks for a bunch of parameters
- Creates a disk from parent vhdx for speed
@sasha2002
sasha2002 / Documentation.md
Created May 22, 2020 05:07 — forked from KartikTalwar/Documentation.md
Rsync over SSH - (40MB/s over 1GB NICs)

The fastest remote directory rsync over ssh archival I can muster (40MB/s over 1gb NICs)

This creates an archive that does the following:

rsync (Everyone seems to like -z, but it is much slower for me)

  • a: archive mode - rescursive, preserves owner, preserves permissions, preserves modification times, preserves group, copies symlinks as symlinks, preserves device files.
  • H: preserves hard-links
  • A: preserves ACLs
@sasha2002
sasha2002 / accounts.list
Created August 11, 2019 14:39 — forked from onlime/accounts.list
imapsync script to migrate multiple IMAP accounts in a row
# <SRCUSER> <SRCPW> <DSTUSER> <DSTPW>
@sasha2002
sasha2002 / gist:ec3be2175e0f471aa9307f2145c6e81a
Created February 25, 2019 12:27 — forked from pitch-gist/gist:2999707
HTML: Simple Maintenance Page
<!doctype html>
<title>Site Maintenance</title>
<style>
body { text-align: center; padding: 150px; }
h1 { font-size: 50px; }
body { font: 20px Helvetica, sans-serif; color: #333; }
article { display: block; text-align: left; width: 650px; margin: 0 auto; }
a { color: #dc8100; text-decoration: none; }
a:hover { color: #333; text-decoration: none; }
</style>
@sasha2002
sasha2002 / UsingSwingClass.java
Created November 2, 2018 23:44 — forked from jintujacob/UsingSwingClass.java
A java code to implement basic gui for input and output
import javax.swing.JOptionPane;
public class UsingSwingClass {
/**
* Implementinng the input dialog box and show message
*+box
* Something to check on the showMessage dialog box
* JOption.PLAIN_MESSAGE is the one without any icon
*/
public static void main(String[] args) {
@sasha2002
sasha2002 / _service.md
Created May 26, 2016 08:58 — forked from naholyr/_service.md
Sample /etc/init.d script

Sample service script for debianoids

Look at LSB init scripts for more information.

Usage

Copy to /etc/init.d:

# replace "$YOUR_SERVICE_NAME" with your service's name (whenever it's not enough obvious)
@sasha2002
sasha2002 / gist:7a17d493d631824be833
Created October 6, 2015 08:56
Script to block MS telemetry using Mikrotik router
/ip firewall address-list add list=MStelemetry address=111.221.29.177
/ip firewall address-list add list=MStelemetry address=111.221.29.253
/ip firewall address-list add list=MStelemetry address=131.253.40.37
/ip firewall address-list add list=MStelemetry address=134.170.30.202
/ip firewall address-list add list=MStelemetry address=134.170.115.60
/ip firewall address-list add list=MStelemetry address=134.170.165.248
/ip firewall address-list add list=MStelemetry address=134.170.165.253
/ip firewall address-list add list=MStelemetry address=134.170.185.70
/ip firewall address-list add list=MStelemetry address=137.116.81.24
/ip firewall address-list add list=MStelemetry address=137.117.235.16