Skip to content

Instantly share code, notes, and snippets.

View lnrsoft's full-sized avatar
🎯
Focusing

lnrsoft lnrsoft

🎯
Focusing
View GitHub Profile
@lnrsoft
lnrsoft / Enabling HTTP2 in Apache on Ubuntu 18.04
Created December 21, 2018 07:56
Enabling HTTP2 in Apache on Ubuntu 18.04
$ sudo apt-get install php7.2-fpm
$ sudo a2enmod proxy_fcgi
$ sudo a2enconf php7.2-fpm
$ sudo a2dismod php7.2
$ sudo a2dismod mpm_prefork
$ sudo a2enmod mpm_event
$ sudo service apache2 restart
#nstalling and Enabling HTTP/2 in Apache
#Enable the module mod_http2:
@lnrsoft
lnrsoft / Set qmake home on ubuntu
Last active December 9, 2018 15:17
Set qmake home on ubuntu
#On Ubuntu simply export the qmake path using the following command:
$ export PATH=/opt/qt511/bin:$PATH
#Check qmake location and version:
$ which qmake && qmake -query
@lnrsoft
lnrsoft / install_opencv-4.0.0_on_ubuntu.sh
Created December 8, 2018 14:32
Install OpenCV 4.0.0 on Ubuntu 18.04, 18.10
######################################
# INSTALL OPENCV ON UBUNTU OR DEBIAN #
######################################
# | THIS SCRIPT IS TESTED CORRECTLY ON |
# |----------------------------------------------------|
# | OS | OpenCV | Test | Last test |
# |----------------|--------------|------|-------------|
# | Ubuntu 18.10 | OpenCV 4.0.0 | OK | 18 Nov 2018 |
# | Ubuntu 18.04 | OpenCV 4.0.0 | OK | 18 Nov 2018 |
@lnrsoft
lnrsoft / enable http2 on ubuntu server
Created November 19, 2018 14:51
enable http2 on ubuntu server
sudo add-apt-repository ppa:ondrej/php
sudo apt-get install -y language-pack-en-base
sudo LC_ALL=en_US.UTF-8 add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install php7.2
sudo apachectl stop
sudo apt-get install php7.2-fpm
sudo a2enmod proxy_fcgi setenvif
@lnrsoft
lnrsoft / enable http2 on ubuntu server
Created November 19, 2018 14:51
enable http2 on ubuntu server
sudo add-apt-repository ppa:ondrej/php
sudo apt-get install -y language-pack-en-base
sudo LC_ALL=en_US.UTF-8 add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install php7.2
sudo apachectl stop
sudo apt-get install php7.2-fpm
sudo a2enmod proxy_fcgi setenvif
@lnrsoft
lnrsoft / Install or Upgrade to PHP 7.X on Ubuntu
Created November 18, 2018 22:20
Install or Upgrade to PHP 7.X on Ubuntu
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install php7.2
sudo apt-get install php7.2-mysql
sudo apt-get install php7.2-cli php7.2-common libapache2-mod-php7.2 php7.2 php7.2-mysql php7.2-fpm
sudo apt-get install php7.2-mbstring
@lnrsoft
lnrsoft / quick generate ssh key on osx terminal
Created November 15, 2018 22:42
quick generate ssh key on osx terminal
ssh-keygen -t rsa -b 4096 -C "your@domain.com"
ssh-add -k ~/.ssh/new_osx_id_rsa
// copy to osx clipboard
pbcopy < ~/.ssh/new_osx_id_rsa
@lnrsoft
lnrsoft / quick generate pgp key on osx terminal
Created November 15, 2018 22:39
quick generate pgp key on osx terminal
gpg --full-generate-key
gpg --list-secret-keys --keyid-format LONG
//gpg --armor --export [insert the sec id after rsa4096/9872634985729442]
gpg --armor --export 9872634985729442
@lnrsoft
lnrsoft / qt511
Created October 15, 2018 09:30
Install Qt5.11.1 apt repo on Ubuntu 1804 bionic
#source: https://launchpad.net/~beineri/+archive/ubuntu/opt-qt-5.11.1-bionic
sudo add-apt-repository ppa:beineri/opt-qt-5.11.1-bionic
sudo apt-get update
sudo apt install qt511-meta-full qt511creator qt511meta-dbg-full qt511-meta-minimal
@lnrsoft
lnrsoft / install_macport_MacOS_mojave
Created September 27, 2018 06:36
Install MacPort on MacOS Mojave
$ sudo xcode-select –install
$ cd ~/Desktop
$ mkdir macports
$ cd macports
$ curl -O https://distfiles.macports.org/MacPorts/MacPorts-2.5.3.tar.gz
$ tar -xzvf MacPorts-2.5.3.tar.gz
$ cd MacPorts-2.5.3
$ ./configure
$ make
$ sudo make install