Skip to content

Instantly share code, notes, and snippets.

View aburaihan-dev's full-sized avatar
🏠
Working from home

Md. Abu Raihan Srabon aburaihan-dev

🏠
Working from home
View GitHub Profile
@aburaihan-dev
aburaihan-dev / LinuxMint Docker Installation
Last active January 15, 2020 11:09
Steps to follow when installing docker on linux mint 19.3
Links for lookup:
1. https://linuxhint.com/install_docker_linux_mint/
2. https://www.unixtutorial.org/install-docker-in-linux-mint-19-1
3. https://forums.linuxmint.com/viewtopic.php?t=300469
Steps to Follow:
1. remove old docker if any: sudo apt remove docker docker-engine docker.io containerd runc
2. update repo: sudo apt update
3. install basic dependencies: sudo apt-get -y install apt-transport-https ca-certificates curl software-properties-common
-server
-Xms2g
-Xmx2g
-XX:NewRatio=3
-Xss16m
-XX:+UseConcMarkSweepGC
-XX:+CMSParallelRemarkEnabled
-XX:ConcGCThreads=4
-XX:ReservedCodeCacheSize=240m
-XX:+AlwaysPreTouch
echo -n "AR2019Srabon" | openssl sha512 -hmac "TrollHunters"
36e8d232898fff2d7dfccab5b8945d8dd93e5459430784811d0096d44a22944031f4c5a9cecd11ca7a14da1a1de1dce0c1390dab22936355697d93c19c02dcf2
dd if=/dev/random bs=20 count=1 status=none | base64
68XClBM6qR7bd7smQKTLA+5JhkI=
https://www.binarytides.com/linux-commands-monitor-network/
1. Overall bandwidth - nload, bmon, slurm, bwm-ng, cbm, speedometer, netload
2. Overall bandwidth (batch style output) - vnstat, ifstat, dstat, collectl
2. Bandwidth per socket connection - iftop, iptraf, tcptrack, pktstat, netwatch, trafshow
3. Bandwidth per process - nethogs
## Spring DATASOURCE (DataSourceAutoConfiguration & DataSourceProperties)
spring.datasource.url=jdbc:postgresql://localhost:5432/:DB_NAME:
spring.datasource.username= :username:
spring.datasource.password= :password:
# The SQL dialect makes Hibernate generate better SQL for the chosen database
spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.PostgreSQLDialect
# Hibernate ddl auto (create, create-drop, validate, update)
spring.jpa.hibernate.ddl-auto = create-drop
@aburaihan-dev
aburaihan-dev / download-file.js
Created December 20, 2018 06:07 — forked from javilobo8/download-file.js
Download files with AJAX (axios)
axios({
url: 'http://localhost:5000/static/example.pdf',
method: 'GET',
responseType: 'blob', // important
}).then((response) => {
const url = window.URL.createObjectURL(new Blob([response.data]));
const link = document.createElement('a');
link.href = url;
link.setAttribute('download', 'file.pdf');
document.body.appendChild(link);
@aburaihan-dev
aburaihan-dev / default.conf
Created September 30, 2018 14:22
NGiNX Configuration for Vue-Router in HTML5 Mode
server {
listen 80 default_server;
listen [::]:80 default_server;
root /your/root/path;
index index.html;
server_name you.server.com;
:: Disable SELinux ‼️ 🔴🔴🔴
1. check selinux status → sestatus
2. RUN → vi /etc/sysconfig/selinux
3. SELINUX=disabled
4. reboot the server → reboot now
5. Check status again → sestatus 👓
😐 Now Install Asterisk →
:: wget https://downloads.asterisk.org/pub/telephony/asterisk/asterisk-14-current.tar.gz
@aburaihan-dev
aburaihan-dev / LICENCE SUBLIME TEXT
Created July 30, 2018 10:39
Sublime Text 3 Serial key build is 3176
## Sublime Text 3 Serial key build is 3176
> * Added these lines into /etc/hosts
127.0.0.1 www.sublimetext.com
127.0.0.1 license.sublimehq.com
> * Used the license key
----- BEGIN LICENSE -----
@aburaihan-dev
aburaihan-dev / LICENCE SUBLIME TEXT
Created July 30, 2018 10:39 — forked from ityouknow/LICENCE SUBLIME TEXT
Sublime Text 3 Serial key build is 3176
## Sublime Text 3 Serial key build is 3176
> * Added these lines into /etc/hosts
127.0.0.1 www.sublimetext.com
127.0.0.1 license.sublimehq.com
> * Used the license key
----- BEGIN LICENSE -----