Skip to content

Instantly share code, notes, and snippets.

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

Deepak Thapa dtsuper3

🏠
Working from home
View GitHub Profile
@dtsuper3
dtsuper3 / docker-help.md
Created February 11, 2019 12:05 — forked from bradtraversy/docker-help.md
Docker Commands, Help & Tips

Docker Commands, Help & Tips

Show commands & management commands

$ docker

Docker version info

1.download arduino from arduino
2.install.sh file
3.accessing permision via sudo chmod a+rw /dev/ttyACM0
@dtsuper3
dtsuper3 / node_redis_cache.js
Created July 12, 2020 17:42 — forked from bradtraversy/node_redis_cache.js
Node.js & Redis Caching
const express = require('express');
const fetch = require('node-fetch');
const redis = require('redis');
const PORT = process.env.PORT || 5000;
const REDIS_PORT = process.env.PORT || 6379;
const client = redis.createClient(REDIS_PORT);
const app = express();
@dtsuper3
dtsuper3 / node_nginx_ssl.md
Created July 12, 2020 17:44 — forked from bradtraversy/node_nginx_ssl.md
Node app deploy with nginx & SSL

Node.js Deployment

Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt

1. Sign up for Digital Ocean

If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a

2. Create a droplet and log in via ssh

I will be using the root user, but would suggest creating a new user

MongoDB Cheat Sheet

Show All Databases

show dbs

Show Current Database

@dtsuper3
dtsuper3 / rethinkdb_cheat_sheet.MD
Created July 12, 2020 17:47 — forked from bradtraversy/rethinkdb_cheat_sheet.MD
RethinkDB Query Cheat Sheet

RethinkDB Cheat Sheet

Create database

r.dbCreate('mydb')

List databases

MySQL Cheat Sheet

Help with SQL commands to interact with a MySQL database

MySQL Locations

  • Mac /usr/local/mysql/bin
  • Windows /Program Files/MySQL/MySQL version/bin
  • Xampp /xampp/mysql/bin

Add mysql to your PATH

@dtsuper3
dtsuper3 / docker_wordpress.md
Created July 12, 2020 17:47 — forked from bradtraversy/docker_wordpress.md
Docker Compose FIle For Wordpress, MySQL & phpmyadmin

Wordpress & Docker

This file will setup Wordpress, MySQL & PHPMyAdmin with a single command. Add the code below to a file called "docker-compose.yaml" and run the command

$ docker-compose up -d

# To Tear Down
$ docker-compose down --volumes
@dtsuper3
dtsuper3 / ssh.md
Created July 12, 2020 17:48 — forked from bradtraversy/ssh.md
SSH & DevOps Crash Course Snippets

SSH Cheat Sheet

This sheet goes along with this SSH YouTube tutorial

Login via SSH with password (LOCAL SERVER)

$ ssh brad@192.168.1.29

Create folder, file, install Apache (Just messing around)

$ mkdir test

$ cd test

match start and end index as same:- regex = /^(a|e|i|o|u).*\1$/