Skip to content

Instantly share code, notes, and snippets.

Getting any Docker image running in your own OpenShift cluster
FEBRUARY 22, 2016 BY CHRIS MILSTED
This post was written by Chris Milsted, Senior Solution Architect at Red Hat.
For those who have been using stand-alone development environments, leveraging containers using pre-existing docker format images (either internal images or images from an external registry such as the Red Hat registry or docker hub) but have outgrown your single machine and want to leverage the power of OpenShift using Kubernetes, this blog post is for you!
My assumption is that readers are familiar with how to install OpenShift and how to setup projects with quotas.
Recently I have been working with some organizations who are looking to quickly create and tear down projects to deliver small, quick and agile proof of concepts which are looking to be self-contained and might last a few days or weeks at most.
In a stand-alone environment, there are some prepackaged images such as GitLab-CE which can be utilized to great effect. In fa
[DEFAULT]
# Ban hosts for one hour:
bantime = 3600
# Override /etc/fail2ban/jail.d/00-firewalld.conf:
banaction = iptables-multiport
[sshd]
enabled = true
#!/bin/bash
yum update -y && yum install -y wget curl screen vim nano epel-release git
yum update -y && yum install -y fail2ban
wget -O /root/.vimrc https://gist.githubusercontent.com/samjaninf/96cd28fae4d4576931c901f731e9e331/raw/c335f1f5a0d08438fad01f9098315d85d90e7f6e/vimrc
wget -O /root/.screenrc https://gist.githubusercontent.com/samjaninf/40e22f11bc804e3151e76195c38bda95/raw/77a323debd724ade9a8032219a65da25ab014854/screenrc
yum install -y zsh
yum upgrade -y
# This page can be found at: https://highon.coffee/blog/security-harden-centos-7/
echo "install usb-storage /bin/false" > /etc/modprobe.d/usb-storage.conf
authconfig --passalgo=sha512 --update
vim /etc/security/pwquality.conf
# Configuration for systemwide password quality limits
# Defaults:
yum install -y http://resources.ovirt.org/pub/yum-repo/ovirt-release40.rpm
yum install -y ovirt-hosted-engine-setup screen glusterfs-server vdsm-gluster system-storage-manager
ssm add -p gluster /dev/sdb
ssm create -p gluster --fstype xfs -n bricks
mkdir /gluster
echo "/dev/mapper/gluster-bricks /gluster xfs defaults 0 0" >> /etc/fstab
@samjaninf
samjaninf / Deploying on Amazon AWS (Free-Tier) with EC2, RDS & S3.md
Created November 2, 2016 20:29 — forked from pcm211/Deploying on Amazon AWS (Free-Tier) with EC2, RDS & S3.md
This Is a step by step way to deploy Sharetribe to Amazon AWS Free Tier in Development Mode (Not Production)

Prerequisites

  1. Have an AWS Account
  2. Spin up an EC2 Instance of Ubuntu Server and Make sure that your instance's security groups allow incoming connections on TCP ports 22 and 3000
  3. Use an Elastic IP to bind your Instance to it --- You would not be paying for this -- Till the time the EC2 Instance is running
  4. Add the IP Allocated to your A Record --- with your registrar
  5. Have a SSH Connection to your EC2 Instance with the Key Pairs
  6. Connect to the EC2 Instance

STEP 1 -- Setting up the Playground

https://files.zimbra.com/downloads/8.7.6_GA/zcs-8.7.6_GA_1776.RHEL7_64.20170326144124.tgz
oc delete daemonsets.extensions docker-registry
delete serviceaccount registry
delete clusterrolebinding registry-registry-role
delete all -l docker-registry=default
oadm registry --config=/etc/origin/master/admin.kubeconfig --service-account=registry
@samjaninf
samjaninf / back-res.sh
Created June 3, 2017 19:18 — forked from zekus/back-res.sh
a backup script for ispconfig-3
#!/bin/bash
version="0.9.6 from 2014-02-04"
# Always download the latest version here: http://www.eurosistems.ro/back-res
# Thanks or questions: http://www.howtoforge.com/forums/showthread.php?t=41609
#
# CHANGELOG:
# -----------------------------------------------------------------------------
# version 0.9.6 - 2014-02-04 (by Yavuz Aydin - Vrij Media)
# --------------------------
# - Changed mysql import routine to create database if it doesn't exist
#!/bin/sh
set -e
dir="$1"
if [ -z "$dir" ]; then
{
echo 'This script is for destroying old /var/lib/docker directories more safely than'
echo ' "rm -rf", which can cause data loss or other serious issues.'
echo