Skip to content

This repo contains code for New Relic’s K8s operator.

License

Notifications You must be signed in to change notification settings

rahul188/newrelic-k8s-operator

 
 

Repository files navigation

New Relic Open Source community project banner.

New Relic K8s Operator

This repository contains the source code for New Relic's K8s operator. The K8s operator helps users deploy and manage their deployment of New Relic's K8s solution.

The K8s operator is built using Operator Framework's Hybrid Helm Operator.

Table of contents

Installation

For installation instructions, refer to our docs.

Helm chart

You can install this chart using directly from this repository or by adding the Helm repository:

helm repo add nr-operator https://newrelic.github.io/newrelic-k8s-operator && helm repo update
helm upgrade --install nr-operator nr-operator/newrelic-k8s-operator -f your-custom-values.yaml

For further information of the configuration needed for the chart, you can follow the configuration specified in the nri-bundle chart. Please make sure global.licenseKey is specified.

Development flow

This project uses a Makefile for the most common use cases.

When updating the NewRelic CRD, you should add or modify fields and types to api/v1alpha1/newrelic_types.go. After editing the file, make sure to run the following to update the CRD YAML and generated API files:

make manifests
make generate

To update the Helm charts templates, run:

make helm IMG=<registry>/newrelic-operator:<version>

Running locally

The easiest way to get started is using the commands in the Makefile and Minikube.

Follow these steps to run this project:

  • Ensure Minikube is running
$ minikube status
host: Running
kubelet: Running
apiserver: Running
kubectl: Correctly Configured: pointing to minikube-vm at 192.168.x.x
docker build -t <registry>/newrelic-operator:0.0.1 .
docker push <registry>/newrelic-operator:0.0.1
make deploy <registry>/newrelic-operator:0.0.1

This will deploy the necessary service accounts, RBAC policies, and deployment necessary for the operator to run. The operator will be running in the newrelic-operator-system namespace. You can then deploy the sample CRDs. Before doing so, make sure to update the licenseKey with your own in config/samples/minimal_nribundle.yaml:

kubectl apply -f config/samples/newrelic_v1alpha1_newrelic.yaml
kubectl apply -f config/samples/minimal_nribundle.yaml

To clean up:

make undeploy

Support

Should you need assistance with New Relic products, you are in good hands with several support diagnostic tools and support channels.

If the issue has been confirmed as a bug or is a feature request, file a GitHub issue.

Support Channels

Contribute

We encourage your contributions to improve newrelic-k8s-operator! Keep in mind that when you submit your pull request, you'll need to sign the CLA via the click-through using CLA-Assistant. You only have to sign the CLA one time per project.

If you have any questions, or to execute our corporate CLA (which is required if your contribution is on behalf of a company), drop us an email at [email protected].

A note about vulnerabilities

As noted in our security policy, New Relic is committed to the privacy and security of our customers and their data. We believe that providing coordinated disclosure by security researchers and engaging with the security community are important means to achieve our security goals.

If you believe you have found a security vulnerability in this project or any of New Relic's products or websites, we welcome and greatly appreciate you reporting it to New Relic through HackerOne.

If you would like to contribute to this project, review these guidelines.

To all contributors, we thank you! Without your contribution, this project would not be what it is today.

License

newrelic-k8s-operator is licensed under the Apache 2.0 License. newrelic-k8s-operator also eses source code from third-party libraries. You can find full details on which libraries are used and the terms under which they are licensed in the third-party notices document.

About

This repo contains code for New Relic’s K8s operator.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 69.1%
  • Makefile 26.5%
  • Dockerfile 4.4%