Skip to content

Instantly share code, notes, and snippets.

View bilaschandra's full-sized avatar
🏠
Working from home

Bilas Chandra Sarker bilaschandra

🏠
Working from home
View GitHub Profile
$ touch /usr/share/applications/robomongo.desktop
$ vim /usr/share/applications/robomongo.desktop
Content
[Desktop Entry]
Encoding=UTF-8
Type=Application
Name=Robomongo
Icon=/opt/robomongo-{robomongo-version}/bin/robomongo.png
@bilaschandra
bilaschandra / phpmyadmin.conf
Created August 27, 2017 10:19
Nginix config for phpmyadmin in hosting
# PhpMyAdmin configuration for nginx
location /phpmyadmin {
root /usr/share/;
index index.php index.html index.htm;
location ~ ^/phpmyadmin/(.+\.php)$ {
#try_files $uri =404;
root /usr/share/;
#fastcgi_pass 127.0.0.1:9000;
fastcgi_pass unix:/tmp/php5-fpm.sock;
server {
listen 80;
server_name demo.example.com;
return 301 https://demo.example.com$request_uri;
}
server {
listen 443 ssl spdy;
server_name demo.example.com;
ssl on;
@bilaschandra
bilaschandra / doc.txt
Last active August 1, 2017 09:26
FN-DOC
1) docker-compose exec db bash
Access db container by this command
2) mongo
Type the above and enter
4) use database
3) db.coverage.find({}).count()
IN mongo DB command line get total records
@bilaschandra
bilaschandra / centos7-selinux-permissions.sh
Created June 10, 2017 11:14
SELinux base common permissions set to web application in CentOs 7
#!/usr/bin/env bash
set -o errexit
set -o pipefail
set -o nounset
# set -o xtrace
echo "0.- Reestablecer el contexto"
sudo restorecon -Rv /var/www/html
echo "1.- Cambiar propietario del webroot de Apache"