Skip to content

Instantly share code, notes, and snippets.

View cse031sust02's full-sized avatar

Talha Ibne Imam cse031sust02

View GitHub Profile
@cse031sust02
cse031sust02 / Dockerfile
Last active October 9, 2023 12:57
Basic Dockerfile for Django using Pipenv
# My Django Project
# Version: 1.0
# FROM - Image to start building on.
FROM python:3
# PROJECT SETUP
# ----------------
@cse031sust02
cse031sust02 / docker-commands.md
Last active August 21, 2019 09:09
Docker commands
  • download images to our computer
$ docker pull <image-name>
  • builds an image from a Dockerfile
$ docker build <path>
@cse031sust02
cse031sust02 / install-lemp-on-ubuntu-16.sh
Created March 12, 2018 04:27
Bash Script to install LEMP stack on Ubuntu 16.04
#!/bin/sh
#############################################################
# Bash script to install LEMP Stack (+ some other tools)
# Target Machine : Ubuntu 16.04 @ AWS EC2
# Written by Talha Ibne Imam (@cse031sust02)
#############################################################
HC='\033[0;32m' # Heading Color
WC='\033[0;33m' # Warning Color
@cse031sust02
cse031sust02 / install-laravel-project.sh
Created March 12, 2018 04:26
Bash Script to install Laravel project from Git on LEMP stack
#!/bin/sh
########################################################
# Bash script to install HeavyGari Laravel App
# Written by Talha Ibne Imam
########################################################
HC='\033[0;32m' # Heading Color
WC='\033[0;33m' # Warning Color
NC='\033[0m' # No Color
@cse031sust02
cse031sust02 / push.php
Created January 24, 2018 11:23
Send push notification using Firebase
<?php
use GuzzleHttp;
$access_token = 'FIREBASE CLOUD MESSAGING SERVER KEY';
$reg_id = 'DEVICE REGISTRATION ID';
$message = [
'notification' => [
☐ Start
- sudo apt-get update
☐ Install nginx
- sudo apt-get install nginx
☐ Install PHP (PHP7)
- sudo add-apt-repository ppa:ondrej/php
- sudo apt-get update
server {
server_name domain.tld;
root /var/www/codeignitor;
index index.html index.php;
# set expiration of assets to MAX for caching
location ~* \.(ico|css|js|gif|jpe?g|png)(\?[0-9]+)?$ {
expires max;
log_not_found off;
@cse031sust02
cse031sust02 / nginx-CI
Created June 16, 2015 10:55
Nginx Server for CodeIgniter
server {
server_name domain.tld;
root /var/www/codeignitor;
index index.html index.php;
# set expiration of assets to MAX for caching
location ~* \.(ico|css|js|gif|jpe?g|png)(\?[0-9]+)?$ {
expires max;
log_not_found off;