Skip to content

Commit

Permalink
chore: Add License
Browse files Browse the repository at this point in the history
Signed-off-by: Anurag Rajawat <[email protected]>
  • Loading branch information
anurag-rajawat committed Sep 19, 2024
1 parent 6d8278b commit 881e613
Show file tree
Hide file tree
Showing 17 changed files with 66 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .licenserc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ header:

paths-ignore:
- "protobuf/*"
# Explicitly mention generated go files otherwise the check won't pass.
- "protobuf/**/*.go"

comment: on-failure

Expand Down
3 changes: 3 additions & 0 deletions protobuf/Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# SPDX-License-Identifier: Apache-2.0
# Copyright 2024 Authors of SentryFlow

PROTOS:="sentryflow.proto sentryflow_metrics.proto"

.PHONY: help
Expand Down
20 changes: 20 additions & 0 deletions scripts/add-license-header
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/usr/bin/env bash
# SPDX-License-Identifier: Apache-2.0
# Copyright 2024 Authors of SentryFlow

if ! command -v addlicense >/dev/null; then
echo "Installing addlicense..."
go install github.com/google/addlicense@latest
fi

GIT_ROOT=$(git rev-parse --show-toplevel)
LICENSE_HEADER=${GIT_ROOT}/scripts/license.header

if [ -z "$1" ]; then
echo "No Argument Supplied, Checking and Fixing all files from project root"
find "${GIT_ROOT}" -name "*.sh" -or -name "*.go" | xargs -I {} addlicense -f "${LICENSE_HEADER}" -v {}
echo "Done"
else
addlicense -f "${LICENSE_HEADER}" -v "$1"
echo "Done"
fi
2 changes: 2 additions & 0 deletions scripts/license.header
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
SPDX-License-Identifier: Apache-2.0
Copyright 2024 Authors of SentryFlow
3 changes: 3 additions & 0 deletions sentryflow/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# SPDX-License-Identifier: Apache-2.0
# Copyright 2024 Authors of SentryFlow

FROM golang:1.23 AS builder

ARG TARGETOS
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# SPDX-License-Identifier: Apache-2.0
# Copyright 2024 Authors of SentryFlow

BINARY_NAME ?= sentryflow
REGISTRY ?= docker.io/5gsec
VERSION ?= $(shell git rev-parse HEAD)
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/cmd/root.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package cmd

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/cmd/version.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package cmd

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/main.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package main

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/config/config.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package config

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/core/sentryflow.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package core

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/core/server.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package core

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/exporter/exporter.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package exporter

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/k8s/client.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package k8s

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/receiver/receiver.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package receiver

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/receiver/svcmesh/istio/sidecar/sidecar.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package sidecar

import (
Expand Down
3 changes: 3 additions & 0 deletions sentryflow/pkg/util/util.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// SPDX-License-Identifier: Apache-2.0
// Copyright 2024 Authors of SentryFlow

package util

import (
Expand Down

0 comments on commit 881e613

Please sign in to comment.