quick create root CA and self signed for chrome 58+

create RootCA first cat createRootCa.sh #!/usr/bin/env bash mkdir /root/ca/ openssl genrsa -des3 -out /root/ca/rootCA.key 2048 openssl req -x509 -new -nodes -key /root/ca/rootCA.key -sha256 -days 7300 -out /root/ca/rootCA.pem Create server.csr.cnf [req] default_bits = 2048 prompt = no default_md = sha256 distinguished_name = req_distinguished_name [ req_distinguished_name ] # See <https://en.wikipedia.org/wiki/Certificate_signing_request>. countryName = MX stateOrProvinceName = MX localityNameSeguir leyendo

php7 util extensions

apt-get install php7.0-gd php7.0-mysql php7.0-cli php7.0-cgi php-pear php7.0-mcrypt mcrypt imagemagick php7.0-curl php7.0-intl php7.0-pspell php7.0-recode php7.0-sqlite3 php7.0-tidy php7.0-xmlrpc php7.0-xsl memcached php-memcache php-imagick php-gettext php7.0-zip php7.0-mbstring memcached php7.0-soap

file permissions wordpress

For those who have their wordpress root folder under their home folder: ** Ubuntu/apache Add your user to www-data group: CREDIT Granting write permissions to www-data group You want to call usermod on your user. So that would be: sudo usermod -aG www-data yourUserName ** Assuming www-data group exists Check your user is in www-dataSeguir leyendo

crear un sitio django – gunicorn – nginx – supervisord – centos 7 – selinux

1. crear virtualenv virtualenv misitio 2. activar virtualenv source /opt/virtualenvs/misitio/bin/activate 3. Instalar paquetes: pip install django==1.10 pip install psycopg2== pip install django-suit==0.2.25 pip install django_select2 pip install gunicorn pip install django_select2 4. Crear base inicial: python manage.py makemigrations python manage.py migrate 5. Crear usuario python manage.py createsuperuser SELINUX setenforce 1 semanage fcontext -a -t httpd_sys_content_tSeguir leyendo

Using lsof utility

lsof is one of the little known but very powerfull utility in Linux. Man pages basically says that lsof: list open files. But you can use it for managing and tracking network connections, you can list open ports, identify connections currently being made to your system, and determine what resources a process is using. NotSeguir leyendo

FIO Perf Tool Nutshell

FIO is an I/O tool meant to be used both for benchmark and stress/hardware verification. It has support for 13 different types of I/O engines (sync, mmap, libaio, posixaio, SG v3, splice, null, network, syslet, guasi, solarisaio, and more), I/O priorities (for newer Linux kernels), rate I/O, forked or threaded jobs, and much more. ItSeguir leyendo