Skip to content

Instantly share code, notes, and snippets.

View timam1992's full-sized avatar

Al-Amin Talukdar timam1992

View GitHub Profile
@timam1992
timam1992 / install-redis.sh
Created November 28, 2018 06:40 — forked from clzola/install-redis.sh
Bash script for installing Redis on Ubuntu 16.04
#!/bin/bash
# Install the Build and Test Dependencies
apt-get update
apt-get install -y curl build-essential tcl
# Download and Extract the Source Code
cd /tmp
curl -O http://download.redis.io/redis-stable.tar.gz
tar xzvf redis-stable.tar.gz
@timam1992
timam1992 / foo.log
Created July 27, 2018 16:23 — forked from ibeex/foo.log
Flask logging example
A warning occurred (42 apples)
An error occurred
@timam1992
timam1992 / lambdaAMIBackups.py
Created May 19, 2018 13:11 — forked from bkozora/lambdaAMIBackups.py
AWS Lambda AMI Backups
# Automated AMI Backups
#
# @author Robert Kozora <[email protected]>
#
# This script will search for all instances having a tag with "Backup" or "backup"
# on it. As soon as we have the instances list, we loop through each instance
# and create an AMI of it. Also, it will look for a "Retention" tag key which
# will be used as a retention policy number in days. If there is no tag with
# that name, it will use a 7 days default value for each AMI.
#
@timam1992
timam1992 / README.md
Created May 15, 2018 06:16 — forked from hofmannsven/README.md
My simply Git Cheatsheet

How to shorten bash prompt?

PROMPT_DIRTRIM=3

#!/bin/bash
echo "Which directory you want to traverse?"
read directory
find $directory -type f | while read file; do
echo $file ;
done
FROM python:3.5-alpine
# Copy in your requirements file
ADD requirements.txt /requirements.txt
# OR, if you’re using a directory for your requirements, copy everything (comment out the above and uncomment this if so):
# ADD requirements /requirements
# Install build deps, then run `pip install`, then remove unneeded build deps all in a single step. Correct the path to your production requirements file, if needed.
RUN set -ex \
@timam1992
timam1992 / README.md
Last active March 24, 2018 00:25
Docker PostgreSQL Up

Run a Postgres Database in Docker Container

How to use?

docker-compose up