Skip to content

Instantly share code, notes, and snippets.

View shivampip's full-sized avatar
🏡
In Quarantine

Shivam Agrawal shivampip

🏡
In Quarantine
View GitHub Profile
@shivampip
shivampip / fabric_demo.md
Last active November 13, 2019 06:59
Python SSH Client (Fabric built on top of Paramiko & Invoke)

Fabric is a high level Python (2.7, 3.4+) library designed to execute shell commands remotely over SSH, yielding useful Python objects in return

Installation

pip install fabric

Connect to VPS and Execute commands

from fabric import Connection
@shivampip
shivampip / pipenv_cheat_sheet.md
Last active November 11, 2019 18:26 — forked from bradtraversy/pipenv_cheat_sheet.md
Pipenv cheat sheet for common commands

Pipenv Cheat Sheet

Install pipenv

pip3 install pipenv

Activate

pipenv shell
import asyncio
import inspect
import json
import logging
import uuid
from asyncio import Queue, CancelledError
from sanic import Sanic, Blueprint, response
from sanic.request import Request
from typing import Text, List, Dict, Any, Optional, Callable, Iterable, Awaitable
import logging
import uuid
from sanic import Blueprint, response
from sanic.request import Request
from socketio import AsyncServer
from typing import Optional, Text, Any, List, Dict, Iterable
from rasa.core.channels.channel import InputChannel
from rasa.core.channels.channel import UserMessage, OutputChannel
import logging
import json
from copy import deepcopy
from sanic import Blueprint, response
from sanic.request import Request
from telegram import (
Bot,
InlineKeyboardButton,
Update,
InlineKeyboardMarkup,
@shivampip
shivampip / mongodb_pass_reset.md
Created November 6, 2019 16:31
MongoDB shell admin password reset
  • open mongod.conf
cd /etc/mongod.conf
  • Comment security
#security:
#  authroization: "enabled"
@shivampip
shivampip / telegram.py
Created October 11, 2019 13:35
Telegram Connnector for Rasa Modified
import logging
import json
from copy import deepcopy
from sanic import Blueprint, response
from sanic.request import Request
from telegram import (
Bot,
InlineKeyboardButton,
Update,
InlineKeyboardMarkup,
@shivampip
shivampip / Contribute.md
Last active October 11, 2019 07:52
Contribute to Open Source
  • Fork the repo by clicking Fork button
  • Clone the forked repo to local machine
git clone https://www.github.com/shivampip/tenpy
  • Create the branch
git checkout -b my_new_branch
@shivampip
shivampip / MongoDB_ubuntu_nginx_ssh.md
Last active October 18, 2022 01:30
MongoDB on Ubuntu 18.04 (nginx) SSH

Just follow these steps and teke ref of Refernce

  • Uninstall previous installation
sudo service mongod stop

sudo apt-get purge mongodb-org*

sudo rm -r /var/log/mongodb
@shivampip
shivampip / RASA_Deployment_on_VPS.md
Last active March 3, 2020 12:21
RASA Bot Deployment on Ubuntu VPS with Telegram (where ssl required)

Configuring Nginx

  • Open /etc/nginx/nginx.conf
  • Add this code block
server{
        listen 80;
        listen [::]:80;

        server_name  www.shivampip.com shivampip.com;
        location / {