Git Product home page Git Product logo

se-workshop's Introduction

se-workshop

SE workshop

Code snippets

You might need these snippets during the workshop, so they are provided here so you can Copy & Paste

Demoenv handling commands

alias demoenv-aws="docker run -ti --rm \
	-v ~/.ssh/id_rsa:/config/ssh-key.pem:ro \
	-v ~/.aws:/config/aws \
	-e CLUSTER_NAME=<your-cluster-name>\
	-e BUCKET_PATH=s3://sysdig-partner-demo-env/ \
	-e ZONE=us-east-1a \
	-e NUM_NODES=1 \
	-e VPC_ID=vpc-04bcfe02f0e598f57 \
	-e PRIVATE_SUBNET_ID=subnet-0b47480ea22274a71 \
	-e PUBLIC_SUBNET_ID=subnet-0d7c808f36dfb0f08 \
	845151661675.dkr.ecr.us-east-1.amazonaws.com/demoenv-aws"

Helm command for agent installation

kubectl create ns sysdig-agent

helm install -n sysdig-agent --set sysdig.accessKey=YOUR-KEY-HERE --set sysdig.settings.k8s_cluster_name=foo-bar sysdig-agent stable/sysdig

Deploying Jenkins

#Linux
$ curl -sSfL https://github.com/roboll/helmfile/releases/download/v0.98.3/helmfile_linux_amd64 -o /usr/local/bin/helmfile

#Mac
$ curl -sSfL https://github.com/roboll/helmfile/releases/download/v0.98.3/helmfile_darwin_amd64 -o /usr/local/bin/helmfile

$ chmod +x /usr/local/bin/helmfile

$ helmfile sync --concurrency 1

Get Jenkins password

$ kubectl get secret --namespace jenkins jenkins -o jsonpath="{.data.jenkins-admin-password}" | base64 --decode

Export Jenkins service localhost using port-forward

kubectl -n jenkins port-forward svc/jenkins 8080

Github action workflow

name: Sysdig - Build, scan and push Docker Image

on: [push, repository_dispatch]

jobs:

  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v1

    - name: Build the Docker image
      run: docker build . --file Dockerfile --tag sysdigworkshop/<your-name>:latest

    - name: Scan image
      uses: sysdiglabs/scan-action@v1
      with:
        image-tag: "sysdigworkshop/<your-name>"
        sysdig-secure-token: ${{ secrets.SYSDIG_SECURE_TOKEN }}

se-workshop's People

Contributors

airadier avatar bencer avatar capitangolo avatar tembleking avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.