Skip to content

Instantly share code, notes, and snippets.

View afreisinger's full-sized avatar
🏠
Working from home

Adrián Freisinger afreisinger

🏠
Working from home
View GitHub Profile
@afreisinger
afreisinger / vpnc-script
Created December 10, 2024 22:21 — forked from kevinduterne/vpnc-script
OpenConnect vpnc-script for for MacOS High Sierra. Resolves problem with split DNS.
#!/bin/sh
#
# Originally part of vpnc source code:
# © 2005-2012 Maurice Massar, Jörg Mayer, Antonio Borneo et al.
# © 2009-2012 David Woodhouse <[email protected]>
#
# 2018-05-15 - Minor scutil updates for MacOS Split DNS added by Jeremy Melanson ( https://github.com/zish ).
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@afreisinger
afreisinger / pihole-macvlan-synology-docker.txt
Created April 13, 2024 17:10 — forked from xirixiz/pihole-macvlan-synology-docker.txt
Add a PiHole instance on a macvlan enabled Docker network (Synology eth0 example)
#!/bin/bash
# NAS IP: 192.168.1.10 in this example
# DHCP scope reservation for macvlan: 192.168.1.210/28 (Details below)
## Network: 192.168.1.210/28
## HostMin: 192.168.1.211
## HostMax: 192.168.1.224
## Hosts/Net: 14
# Create a Synology macvlan0 bridge network attached to the physical eth0, and add the ip range scope (sudo)
@afreisinger
afreisinger / zsh_tmux_minimalist_themes_config.md
Created June 7, 2023 01:26 — forked from matej-g/zsh_tmux_minimalist_themes_config.md
My simple, clean and minimalist Oh My ZSH + tmux setup
@afreisinger
afreisinger / gitlab-ci.yml
Created March 21, 2023 00:54 — forked from jugatsu/gitlab-ci.yml
gitlab-post-ci
image: alpine:latest
stages:
- build
- test
- review
- release
- deploy
- cleanup
@afreisinger
afreisinger / README.md
Created March 15, 2022 01:54 — forked from marcoieni/README.md
Localize json resume in different languages

JSON Resume internationalization

A simple way to add internationalization feature to the JSON Resume project.

Create a different entry for each field that you want to localize, named with the language and the name of the field separated by an underscore. For example if you want to create an italian version and an english version of your summary do the following:

"basics": {
  "name": "Richard",
 "label": "Programmer",
#### General PFCTL Commands ####
$ pfctl -d disable # packet-filtering
$ pfctl -e enable # packet-filtering
$ pfctl -q # run quiet
$ pfctl -v -v # run even more verbose
#### Loading PF Rules ####
$ pfctl -f /etc/pf.conf # load /etc/pf.conf
$ pfctl -n -f /etc/pf.conf # parse /etc/pf.conf, but dont load it
$ pfctl -R -f /etc/pf.conf # load only the FILTER rules
$ pfctl -N -f /etc/pf.conf # load only the NAT rules
@afreisinger
afreisinger / .zshrc
Created September 27, 2021 04:10 — forked from ktrysmt/.zshrc
using zplug in zsh
if [[ ! -d ~/.zplug ]];then
git clone https://github.com/zplug/zplug ~/.zplug
fi
source ~/.zplug/init.zsh
zplug "plugins/git", from:oh-my-zsh
zplug "plugins/git", from:oh-my-zsh
zplug "plugins/sudo", from:oh-my-zsh
zplug "plugins/command-not-found", from:oh-my-zsh
zplug "zsh-users/zsh-syntax-highlighting"
zplug "zsh-users/zsh-history-substring-search"
#!/bin/bash
IP="192.168.1.22"
SUBJECT_CA="/C=SE/ST=Stockholm/L=Stockholm/O=himinds/OU=CA/CN=$IP"
SUBJECT_SERVER="/C=SE/ST=Stockholm/L=Stockholm/O=himinds/OU=Server/CN=$IP"
SUBJECT_CLIENT="/C=SE/ST=Stockholm/L=Stockholm/O=himinds/OU=Client/CN=$IP"
function generate_CA () {
echo "$SUBJECT_CA"
openssl req -x509 -nodes -sha256 -newkey rsa:2048 -subj "$SUBJECT_CA" -days 365 -keyout ca.key -out ca.crt