Skip to content

Commit

Permalink
updated due to some received suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
Philippe Stemberger committed Apr 20, 2020
1 parent d9c51a8 commit 58e255f
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 15 deletions.
4 changes: 2 additions & 2 deletions kubernetes/README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
# Super quick Snyk k8s monitor install.

## Pre-requisities:
- Having the `snyk-monitoring` namespace
- Having the `snyk-monitor` namespace
- Having an application/deploymebt to scan
- Having `helm` and `tilt` installed


This script is taking care of all of this, and will install the missing elements

## Installation
- Add your integration token into the `snyk-monitor-secret.yaml` file
- Add your Snyk Kubernetes integration token (generated in Snyk) into the `snyk-monitor-secret.yaml` file. *You need to base64 encode it first (google ‘base64 encoder’)*
- Run the `setup.sh` script
- Wait for Tilt to install everything
- Stop tilt
Expand Down
22 changes: 11 additions & 11 deletions kubernetes/Tiltfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ print('Deploying Snyk')
k8s_yaml('snyk-monitor-namespace.yaml')
k8s_yaml('snyk-monitor-secret.yaml')

print('Please run the helm install to load the snyk monitoring')
# print('Please run the helm install to load the snyk monitoring')

# yaml = helm(
# 'deploy/helm/snyk-monitor',
# # The release name, equivalent to helm --name
# name='snyk-monitor',
# # The namespace to install in, equivalent to helm --namespace
# namespace='snyk-monitor',
# # Values to set from the command-line
# set=['clusterName="Production cluster"']
# )
# k8s_yaml(yaml)
yaml = helm(
'deploy/helm/snyk-monitor',
# The release name, equivalent to helm --name
name='snyk-monitor',
# The namespace to install in, equivalent to helm --namespace
namespace='snyk-monitor',
# Values to set from the command-line
set=['clusterName="Production cluster"']
)
k8s_yaml(yaml)
4 changes: 2 additions & 2 deletions kubernetes/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ if exists helm ; then
else
# To install helm
brew install kubernetes-helm
helm init
helm init -wait
fi

helm repo add snyk-charts https://snyk.github.io/kubernetes-monitor/
Expand All @@ -42,6 +42,6 @@ echo http://localhost:8001/api/v1/namespaces/kube-system/services/https:kubernet

# To get snyk up and running
# I couldn't get this to work in Tile because I need a different namespace and couldn't work out how to get it to switch context
echo helm upgrade --install snyk-monitor snyk-charts/snyk-monitor --namespace snyk-monitor --set clusterName="Production cluster"
# echo helm upgrade --install snyk-monitor snyk-charts/snyk-monitor --namespace snyk-monitor --set clusterName="Production cluster"

ktilt up

0 comments on commit 58e255f

Please sign in to comment.