treewide: add license header and enable haslicense linter

Change-Id: I873a8d4082d75e8f813d8a726a41187eea7a065e
Reviewed-on: https://review.monogon.dev/c/monogon/+/3825
Tested-by: Jenkins CI
Reviewed-by: Leopold Schabel <leo@monogon.tech>
diff --git a/osbase/logtree/doc.go b/osbase/logtree/doc.go
index 1fe6d46..a532f26 100644
--- a/osbase/logtree/doc.go
+++ b/osbase/logtree/doc.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 /*
 Package logtree implements a tree-shaped logger for debug events. It provides log publishers (ie. Go code) with a
diff --git a/osbase/logtree/grpc.go b/osbase/logtree/grpc.go
index 7e17c56..277cd36 100644
--- a/osbase/logtree/grpc.go
+++ b/osbase/logtree/grpc.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 package logtree
 
 import (
diff --git a/osbase/logtree/journal.go b/osbase/logtree/journal.go
index d0e8663..c6cc503 100644
--- a/osbase/logtree/journal.go
+++ b/osbase/logtree/journal.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/journal_entry.go b/osbase/logtree/journal_entry.go
index 547a711..1f10c0f 100644
--- a/osbase/logtree/journal_entry.go
+++ b/osbase/logtree/journal_entry.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/journal_subscriber.go b/osbase/logtree/journal_subscriber.go
index dc9750f..3c27272 100644
--- a/osbase/logtree/journal_subscriber.go
+++ b/osbase/logtree/journal_subscriber.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/journal_test.go b/osbase/logtree/journal_test.go
index d295732..23aaeae 100644
--- a/osbase/logtree/journal_test.go
+++ b/osbase/logtree/journal_test.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/klog.go b/osbase/logtree/klog.go
index dca5a82..54e7f68 100644
--- a/osbase/logtree/klog.go
+++ b/osbase/logtree/klog.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/klog_test.go b/osbase/logtree/klog_test.go
index 788a7eb..3c25d8a 100644
--- a/osbase/logtree/klog_test.go
+++ b/osbase/logtree/klog_test.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/kmsg.go b/osbase/logtree/kmsg.go
index 11e140a..91a4cf3 100644
--- a/osbase/logtree/kmsg.go
+++ b/osbase/logtree/kmsg.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 //go:build linux
 // +build linux
 
diff --git a/osbase/logtree/kmsg_test.go b/osbase/logtree/kmsg_test.go
index 24f2acf..ff97a6d 100644
--- a/osbase/logtree/kmsg_test.go
+++ b/osbase/logtree/kmsg_test.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 //go:build linux
 // +build linux
 
diff --git a/osbase/logtree/leveled.go b/osbase/logtree/leveled.go
index 0ca6e48..d4be193 100644
--- a/osbase/logtree/leveled.go
+++ b/osbase/logtree/leveled.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/leveled_payload.go b/osbase/logtree/leveled_payload.go
index b038848..524c81b 100644
--- a/osbase/logtree/leveled_payload.go
+++ b/osbase/logtree/leveled_payload.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/logtree.go b/osbase/logtree/logtree.go
index b6f8a06..9fcaa4c 100644
--- a/osbase/logtree/logtree.go
+++ b/osbase/logtree/logtree.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/logtree_access.go b/osbase/logtree/logtree_access.go
index 30ceccf..dd3bf4e 100644
--- a/osbase/logtree/logtree_access.go
+++ b/osbase/logtree/logtree_access.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/logtree_entry.go b/osbase/logtree/logtree_entry.go
index 5fcb392..833081f 100644
--- a/osbase/logtree/logtree_entry.go
+++ b/osbase/logtree/logtree_entry.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/logtree_publisher.go b/osbase/logtree/logtree_publisher.go
index 2df7037..9d196bc 100644
--- a/osbase/logtree/logtree_publisher.go
+++ b/osbase/logtree/logtree_publisher.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/logtree_test.go b/osbase/logtree/logtree_test.go
index 8ddd3d0..ecc3253 100644
--- a/osbase/logtree/logtree_test.go
+++ b/osbase/logtree/logtree_test.go
@@ -1,18 +1,5 @@
-// Copyright 2020 The Monogon Project Authors.
-//
+// Copyright The Monogon Project Authors.
 // SPDX-License-Identifier: Apache-2.0
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
 
 package logtree
 
diff --git a/osbase/logtree/proto/gomod-generated-placeholder.go b/osbase/logtree/proto/gomod-generated-placeholder.go
index 92256db..5805fe0 100644
--- a/osbase/logtree/proto/gomod-generated-placeholder.go
+++ b/osbase/logtree/proto/gomod-generated-placeholder.go
@@ -1 +1,4 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 package proto
diff --git a/osbase/logtree/testhelpers.go b/osbase/logtree/testhelpers.go
index 45bcaf2..f67cc84 100644
--- a/osbase/logtree/testhelpers.go
+++ b/osbase/logtree/testhelpers.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 package logtree
 
 import (
diff --git a/osbase/logtree/unraw/unraw.go b/osbase/logtree/unraw/unraw.go
index 88ab9d1..6f84e5a 100644
--- a/osbase/logtree/unraw/unraw.go
+++ b/osbase/logtree/unraw/unraw.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 // Package unraw implements a facility to convert raw logs from external sources
 // into leveled logs.
 //
diff --git a/osbase/logtree/unraw/unraw_test.go b/osbase/logtree/unraw/unraw_test.go
index 994e55e..63a8d60 100644
--- a/osbase/logtree/unraw/unraw_test.go
+++ b/osbase/logtree/unraw/unraw_test.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 package unraw
 
 import (
diff --git a/osbase/logtree/zap.go b/osbase/logtree/zap.go
index e00109b..f38a092 100644
--- a/osbase/logtree/zap.go
+++ b/osbase/logtree/zap.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 package logtree
 
 import (
diff --git a/osbase/logtree/zap_test.go b/osbase/logtree/zap_test.go
index b03b8cf..b8c617a 100644
--- a/osbase/logtree/zap_test.go
+++ b/osbase/logtree/zap_test.go
@@ -1,3 +1,6 @@
+// Copyright The Monogon Project Authors.
+// SPDX-License-Identifier: Apache-2.0
+
 package logtree
 
 import (