Skip to content

Instantly share code, notes, and snippets.

View Dauliac's full-sized avatar
🦊

Dauliac Dauliac

🦊
  • Sellsy
  • Bordeaux
View GitHub Profile
@r-k-b
r-k-b / _use nixpkgs cypress binary before npms broken copy.md
Last active February 4, 2023 17:11
how to use NixOS's Cypress instead of npm's Cypress

Should help with avoiding errors like:

No version of Cypress is installed in: /home/rkb/.cache/Cypress/6.2.1/Cypress

Please reinstall Cypress by running: cypress install

----------

Cypress executable not found at: /home/rkb/.cache/Cypress/6.2.1/Cypress/Cypress
@JonTheNiceGuy
JonTheNiceGuy / create_cert.yml
Last active January 9, 2022 18:31
A simple ansible playbook to create a new self-signed certificate
---
- hosts: localhost
vars:
- dnsname: your.dns.name
- tmppath: "./tmp/"
- crtpath: "{{ tmppath }}{{ dnsname }}.crt"
- pempath: "{{ tmppath }}{{ dnsname }}.pem"
- csrpath: "{{ tmppath }}{{ dnsname }}.csr"
- pfxpath: "{{ tmppath }}{{ dnsname }}.pfx"
- private_key_password: "password"
@danmikita
danmikita / init.vim
Created November 16, 2018 19:16
File preview with FZF, RG, Bat, and Devicons
nnoremap <silent> <leader>e :call Fzf_dev()<CR>
" ripgrep
if executable('rg')
let $FZF_DEFAULT_COMMAND = 'rg --files --hidden --follow --glob "!.git/*"'
set grepprg=rg\ --vimgrep
command! -bang -nargs=* Find call fzf#vim#grep('rg --column --line-number --no-heading --fixed-strings --ignore-case --hidden --follow --glob "!.git/*" --color "always" '.shellescape(<q-args>).'| tr -d "\017"', 1, <bang>0)
endif
" Files + devicons
@eby
eby / ansible-fact.sh
Last active April 26, 2024 17:58
Get OS version for an inventory with ad-hoc ansible
# The setup command allows filtering facts
# More info: https://docs.ansible.com/ansible/latest/modules/setup_module.html
# inventory_file = path to inventory file (if not normal role layout)
# host_group = group to query. use all for all hosts
ansible -i inventory_file host_group -m setup -a 'filter=ansible_distribution_version'
# For a Ubuntu Bionic Host the distribution facts look like this:
# "ansible_distribution": "Ubuntu",
# "ansible_distribution_file_parsed": true,
# "ansible_distribution_file_path": "/etc/os-release",
@prochor666
prochor666 / install.md
Last active September 7, 2023 16:44
Mount Google drive under Debian Linux (Jessie and later)
@hofmannsven
hofmannsven / README.md
Last active February 6, 2023 03:18 — forked from sergejmueller/index.html
Nginx proxy configuration for Google Analytics

Google Analytics Nginx Proxy

Google PageSpeed Insights flags browser caching of Google Analytics:

Leverage browser caching

Set up a proxy in your Nginx configuration file to address this issue.

Source

@hapylestat
hapylestat / __manual_openvpn_with_external_dhcpd.md
Last active October 25, 2022 15:12
Configure OpenVPN to work using external DHCP server

Configuration steps:

  • create bridge vpn-bridge and tap device connected to this bridge vpn-server:
nmcli con add ifname vpn-bridge type bridge con-name vpn-bridge-server
nmcli con modify vpn-bridge-server bridge.stp no
nmcli con add type tun ifname vpn-server con-name vpn-server-slave mode tap master vpn-bridge
@dapperfu
dapperfu / Makefile
Created December 2, 2017 22:52
venv makefile
.DEFAULT: null
.PHONY: null
null:
@echo No Default Target
VENV = .venv
.PHONY: venv
venv: ${VENV}
${VENV}:
@brandonsoto
brandonsoto / Vagrantfile
Created August 4, 2017 05:53
vagrantfile with serial port and private network
# -*- mode: ruby -*-
# vi: set ft=ruby :
# All Vagrant configuration is done below. The "2" in Vagrant.configure
# configures the configuration version (we support older styles for
# backwards compatibility). Please don't change it unless you know what
# you're doing.
Vagrant.configure("2") do |config|
# The most common configuration options are documented and commented below.
# For a complete reference, please see the online documentation at