Skip to content

Instantly share code, notes, and snippets.

View mehdiMj-ir's full-sized avatar
🐧

mehdiMj mehdiMj-ir

🐧
View GitHub Profile
@dmancloud
dmancloud / How to Install SonarQube in Ubuntu Linux.md
Last active November 12, 2024 05:14
How to Install SonarQube in Linux

How to Install Sonarqube in Ubuntu Linux

Prerequsites

Virtual Machine running Ubuntu 22.04 or newer

Install Postgresql 15

sudo apt update
sudo apt upgrade

sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
@isaacarnault
isaacarnault / .gitignore
Last active October 31, 2020 14:10
PostgreSQL integration & setting up: an effective way
________ ________ ___ __ ___
|\_____ \|\ __ \|\ \|\ \ |\ \
\|___/ /\ \ \|\ \ \ \/ /|\ \ \
/ / /\ \ __ \ \ ___ \ \ \
/ /_/__\ \ \ \ \ \ \\ \ \ \ \
|\________\ \__\ \__\ \__\\ \__\ \__\
\|_______|\|__|\|__|\|__| \|__|\|__|
Ignore Azure and GCP. This gist was implemented on AWS.
@GAS85
GAS85 / nextcloud_fail2ban.md
Last active September 29, 2024 10:00
Harden Nextcloud 17+ with Fail2Ban, GUI and WebDAV - Ubuntu 20.04

Fail2ban and Nextcloud

Prerequsits

  • Ubuntu 20.04
  • nextcloud, fail2ban and e.g. iptables are installed

Note

@achesco
achesco / generate-pg-ssl.md
Last active August 16, 2024 22:09
Generate self-signed SSL certificates for PostgreSQL server and client

CNs are important!!! -days 3650

Create a Certificate Signing Request (CN=localhost)

umask u=rw,go= && openssl req -days 3650 -new -text -nodes -subj '/C=US/ST=Massachusetts/L=Bedford/O=Personal/OU=Personal/[email protected]/CN=localhost' -keyout server.key -out server.csr

Generate self-signed certificate

umask u=rw,go= && openssl req -days 3650 -x509 -text -in server.csr -key server.key -out server.crt
@nicolasramy
nicolasramy / bad-joke.sh
Last active August 19, 2020 11:55
This is why you should always lock your session -- https://twitter.com/tuxplanet/status/687702022905270272?s=09
#
#
fake-cd() {
echo "bash: cd: $1: No such file or directory"
}
#
#
fake-ls() {
echo "ls: cannot access $1: No such file or directory"
@plentz
plentz / nginx.conf
Last active November 16, 2024 14:10
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048