Skip to content

Instantly share code, notes, and snippets.

View rizerzero's full-sized avatar
🎯
Focusing

Juba B rizerzero

🎯
Focusing
View GitHub Profile
@rizerzero
rizerzero / 1a-steps.md
Created December 2, 2019 16:41 — forked from kacole2/1a-steps.md
Kubernetes 1.14.1 Installation using kubeadm on vSphere with CentOS7

Steps to Install Kubernetes on CentOS7 with Kubeadm and vSphere

  1. On the master node: Edit the vsphere.conf file within the kubeadm-master.sh to match your environment. Copy kubeadm-master.sh to the master node:
sudo chmod u+x kubeadm-master.sh
sudo ./kubeadm-master.sh
  1. On each worker node copy kubeadm-worker.sh:
@rizerzero
rizerzero / .zshrc
Created August 28, 2019 10:35 — forked from zserge/.zshrc
autoload -U compinit colors vcs_info
colors
compinit
REPORTTIME=3
HISTFILE=~/.zhistory
HISTSIZE=5000
SAVEHIST=5000
setopt INC_APPEND_HISTORY
setopt EXTENDED_HISTORY
@rizerzero
rizerzero / Alias command
Last active July 11, 2019 08:37 — forked from bclinkinbeard/release.sh
Bash script to automate the Git Flow tag/release process and maintain release number file.
release(){
#!/bin/bash
# current Git branch
branch=$(git symbolic-ref HEAD | sed -e 's,.*/\(.*\),\1,')
# v1.0.0, v1.5.2, etc.
versionLabel=v$1
# establish branch and tag name variables
gfinit(){
git config gitflow.branch.master master
git config gitflow.branch.develop develop
git symbolic-ref HEAD refs/heads/master
git commit --allow-empty --quiet -m "Initial commit"
git branch --no-track develop master
git checkout -B develop
git config gitflow.prefix.feature feature-
git config gitflow.prefix.bugfix bugfix-
@rizerzero
rizerzero / gitflow-breakdown.md
Created July 10, 2019 14:54 — forked from JamesMGreene/gitflow-breakdown.md
A comparison of using `git flow` commands versus raw `git` commands.

Initialize

gitflow git
git flow init git init
  git commit --allow-empty -m "Initial commit"
  git checkout -b develop master

Connect to the remote repository

@rizerzero
rizerzero / .gitignore
Created May 12, 2019 12:57 — forked from gquemener/.gitignore
SuperMemo 2 PHP Implementation
composer.lock
/vendor
@rizerzero
rizerzero / ec2tools
Created March 20, 2019 09:54
Some useful bash scrips for AWS EC2. See how to use them at https://mexapi.macpress.com.br/2015/05/mail-calendar-server-p1.html
Hello,human. This is just for the gist title.

Zero to Database with Laravel

Part 1: Seeding and Viewing

[Laravel][] is a PHP framework that's really a joy to work with -- though I did find the initial learning curve a bit steep.

This tutorial describes a minimum set of steps necessary to pull content from a database and dump it to a url using Laravel's Eloquent ORM. For me, that was the breakthrough moment.

Assuming you've got [Laravel installed][install] and the [database configured][configure], here are the steps needed to get your data from the database into a web browser:

  1. Create a migration
@rizerzero
rizerzero / .bash_prompt.sh
Created February 20, 2019 11:39 — forked from miki725/.bash_prompt.sh
Custom bash prompt which displays: (virtualenv) user:/path (git-branch)
#!/bin/bash
#
# DESCRIPTION:
#
# Set the bash prompt according to:
# * the active virtualenv
# * the branch of the current git/mercurial repository
# * the return value of the previous command
# * the fact you just came from Windows and are used to having newlines in
# your prompts.
APP_DEV=static.intermail.dev.$1.jp7.com.br
echo "Creating S3 development bucket " $APP_DEV"...\n"
aws s3api create-bucket --bucket $APP_DEV --region us-east-1
echo "Setting Static Web Hosting...\n"
aws s3api put-bucket-website --bucket $APP_DEV --website-configuration file://website-config.json
echo "Bucket" $APP_DEV "created, visit AWS Console to create IAM user for said bucket.\n"
APP_QA=static.intermail.qa.$1.jp7.com.br