sudo apt-get install -y xfsprogs
sudo apt install software-properties-common sudo add-apt-repository ppa:gluster/glusterfs-7 sudo apt update sudo apt install -y glusterfs-server
sudo mkdir /mnt/disks
FROM jenkins/jenkins:2.263.1 | |
USER root | |
RUN apt-get update && apt-get install -y sudo | |
RUN echo "jenkins ALL=NOPASSWD: ALL" >> /etc/sudoers | |
RUN apt-get install -y rsync && apt-get install -y curl | |
RUN curl -sSL https://get.docker.com/ | sh | |
RUN usermod -a -G staff jenkins |
Docker is an open platform for developing, shipping, and running applications. Docker enables you to separate your applications from your infrastructure so you can deliver software quickly.
Docker provides the ability to package and run an application in a loosely isolated environment called a container. The isolation and security allow you to run many containers simultaneously on a given host. Containers are lightweight because they don’t need the extra load of a hypervisor, but run directly within the host machine’s kernel.
Docker provides tooling and a platform to manage the lifecycle of your containers:
https://coderwall.com/p/tk_pwa/ssh-into-a-secured-host-through-a-jump-server-and-forward-ports
ssh -v -t -L 10443:localhost:20443 <jump_server> ssh -t -L 20443:localhost:443 user@<target_server>
ssh -v -t -L 9292:localhost:9292 [email protected] ssh -t -L 9292:localhost:9292 [email protected]
for ROLEIN in $(cat remaining-roles-2 | jq -r ".Roles[] | .RoleName"); do | |
## filter role on pattern | |
ROLE=$(echo $ROLEIN | grep -E "\-SR|\-MR|M-CP-X|M-CP-Y") | |
if [ -z "$ROLE" ] | |
then | |
echo "" | |
else | |
echo role ${ROLE} |
package main | |
import ( | |
"fmt" | |
"github.com/anaskhan96/soup" | |
"github.com/dustin/go-humanize" | |
"io" | |
"io/ioutil" | |
"net/http" | |
"os" |
for ROLEIN in $(cat remaining-roles-2 | jq -r ".Roles[] | .RoleName"); do | |
## filter role on pattern | |
ROLE=$(echo $ROLEIN | grep -E "\-SR|\-MR|M-CP-X|M-CP-Y") | |
if [ -z "$ROLE" ] | |
then | |
echo "" | |
else | |
echo role ${ROLE} |
install dlv debugger inside build image
RUN go get github.com/go-delve/delve/cmd/dlv
copy dlv to final docker image
COPY --from=build-env /go/bin/dlv /app/dlv
build go binary with these flags
#!/bin/bash | |
#name=${1:-docundotapvpc1} | |
#region=${2:-us-east-1} | |
#id=${1:-vpc-08343443447ef34b} | |
#aws ec2 describe-vpcs --region ${region} | jq -r ".Vpcs[] | select(.VpcId | contains(\"${id}\")) | .VpcId" 2>/dev/null | | |
name=testingnetwork | |
region=ap-southeast-1 | |
aws ec2 describe-vpcs --region ${region} | jq -r ".Vpcs[] | select(.Tags[].Value | contains(\"${name}\")) | .VpcId" 2>/dev/null | |