Skip to content

Instantly share code, notes, and snippets.

Mohamed EL Habib mohamed-el-habib

Block or report user

Report or block mohamed-el-habib

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@mohamed-el-habib
mohamed-el-habib / clean.docker.registry.sh
Created Mar 11, 2017
bash script to delete images from docker registry using search keyword
View clean.docker.registry.sh
#!/bin/bash
#
# usage ./clean.docker.registry.sh registryUrl login filterString
#
# read the password
echo -n Password:
read -s password
user="$2:${password}"
@mohamed-el-habib
mohamed-el-habib / add-local-admin-user.sh
Last active Feb 13, 2017
swarm in rancher using 3 docker-machine
View add-local-admin-user.sh
#!/bin/bash
set -x
set -e errexit
set -o pipefail
username="admin-$(echo $RANDOM % 1000 + 1 | bc)"
password="$(uuidgen)" # change it
rancherServerId=$(docker-machine ip host1)
rancherServerPort="8080"
@mohamed-el-habib
mohamed-el-habib / 00_ReadMe.md
Last active Feb 4, 2019
drupal fpm with nginx and mysql
View 00_ReadMe.md

Usage

git clone git://github.com/fd57d8aa59b1574ee7728edf128814d3.git docker-drupal-fpm
cd docker-drupal-fpm
mkdir -p /usr/local/share/dockervolumes/drupal # if you change this folder please update the run.sh
chmod +x run.sh && ./run.sh up
@mohamed-el-habib
mohamed-el-habib / gist:00deef599e8ba1cdbece
Last active Sep 6, 2016 — forked from abs/gist:c0d598996870dda719b3
Downloads and installs the startssl CA certs into the global Java keystore
View gist:00deef599e8ba1cdbece
#!/bin/bash
# Downloads and installs the startssl CA certs into the global Java keystore
# https://sipb.mit.edu/doc/safe-shell/
set -euf -o pipefail
# Check if JAVA_HOME is set
if [ "$JAVA_HOME" = "" ]
then
echo "ERROR: JAVA_HOME must be set."
exit 1
You can’t perform that action at this time.