Skip to content

Instantly share code, notes, and snippets.



  • Amman, Jordan
View GitHub Profile
dasgoll / gist:2cef3f6cf73507b65f550abc67ee55f0
Last active Apr 14, 2022
Using ssh-copy-id to copy public key to server
View gist:2cef3f6cf73507b65f550abc67ee55f0
ssh auser@ sh -c "'cat >> .ssh/authorized_keys'" < /tmp/
dasgoll /
Created Mar 11, 2022
Rsync from one server to another
dasgoll / gist:38b529faf3d8c6368378838a2d76c415
Created Feb 6, 2022
ssmtp configuration for sending email
View gist:38b529faf3d8c6368378838a2d76c415
dasgoll /
Created Jan 26, 2022 — forked from rmalchow/
how to generate password hash and salt for basic auth in solr

solr has a basic authentication module. the description of how to generate the necessary hash + salt string is very hazy. there is this:

project with java code extracted from the solr source .... and then there is this:

View gist:ffb60e707309913b34da2a1c103c0fc2
yum -y install
yum install -y tmux2u
dasgoll / smtp-gmail-send.go
Created Oct 8, 2020 — forked from jpillora/smtp-gmail-send.go
Send email using Go (Golang) via GMail with net/smtp
View smtp-gmail-send.go
package main
import (
func main() {
send("hello there")
View gist:55f873752a560bb9da887927f4aa0083
Host *
StrictHostKeyChecking no
Host public1
IdentityFile /Users/jameel/.ssh/DevOps-eu-west-2.pem
User ec2-user
Host private1
dasgoll /
Created Sep 30, 2020 — forked from bradtraversy/
Python & MySQL crash course for beginners
import mysql.connector
from mysql.connector import errorcode
config = {
'user': 'root',
'password': '',
'host': 'localhost',
'database': 'acme'
dasgoll / alias
Created Aug 8, 2020 — forked from jamesls/alias
AWS CLI v2 upgrade aliases.
View alias
# Put this in ~/.aws/cli/alias
# and you'll have an "aws upgrade"
# and an "aws check-upgrade" command.
# Only works on macOS and installs using
# the .pkg installer.
upgrade = !f() {
curl -s "" -o "/tmp/AWSCLIV2.pkg"
dasgoll / gist:e88f3f0e15b749c170883414efe415f3
Created Jun 23, 2020
How to find out which Go version built your binary
View gist:e88f3f0e15b749c170883414efe415f3
% dlv exec $HOME/bin/godoc
Type 'help' for list of commands.
(dlv) b main.main
Breakpoint 1 set at 0x15596eb for main.main() ./
(dlv) c
> main.main() ./ (hits goroutine(1):1 total:1) (PC: 0x15596eb)
151: }
152: }
153: log.Fatalf("too many redirects")
154: }