Skip to content

Instantly share code, notes, and snippets.

View wbsouza's full-sized avatar

Wellington Souza wbsouza

  • Vancouver - BC / Canada
View GitHub Profile
@wbsouza
wbsouza / iptables_geoip_debian.md
Created December 28, 2023 07:46 — forked from netrunn3r/iptables_geoip_debian.md
Install geoip for iptables in Debian 10
  1. change from buster to bullseye
  2. sudo apt install libnet-cidr-lite-perl libtext-csv-xs-perl libgeoip2-perl

for day of writing, there is a problem with building by dkms this package xtables-addons-common so wehave to install this from source

  1. sudo apt install pkg-config libxtables-dev
  2. wget http://inai.de/files/xtables-addons/xtables-addons-3.13.tar.xz
  3. tar xf xtables-addons-3.13.tar.xz
  4. cd xtables-addons-3.13/
  5. ./configure
  6. make
@wbsouza
wbsouza / postgresql.md
Last active September 17, 2021 10:39 — forked from mencargo/postgresql.md
PostgreSQL Queries

Useful PostgreSQL Queries & Commands

All sizes in MB, change /1024/1024 to /1024/1024/1024 for GB.

Databases sizes

Without system databases

select
datname as database,
(pg_database_size(datname)/1024/1024) as size

Installing mailx

yum -y update
yum install -y mailx

We can now start sending e-mails using

@wbsouza
wbsouza / nginx_odoo_multiprocess
Created January 4, 2019 19:59 — forked from funbaker/nginx_odoo_multiprocess
odoo nginx static files
upstream odoo9_xmlrpc {
server <xmlrpc address>;
}
upstream odoo9_longpolling {
server <longpolling address>;
}
server {
listen 80;