Skip to content

Commit bd9d214

Browse files
authored
Created a License header Checker (opensearch-project#2666)
* License Header Checker Signed-off-by: Divya Madala <[email protected]> * License Header checker. Signed-off-by: Divya Madala <[email protected]> * License Header checker. Signed-off-by: Divya Madala <[email protected]> * License Header checker Signed-off-by: Divya Madala <[email protected]> * License Header checker Signed-off-by: Divya Madala <[email protected]> * License Header checker Signed-off-by: Divya Madala <[email protected]> * License Header checker Signed-off-by: Divya Madala <[email protected]> * License Header checker Signed-off-by: Divya Madala <[email protected]> * License Header checker Signed-off-by: Divya Madala <[email protected]> * License Header checker Signed-off-by: Divya Madala <[email protected]> Signed-off-by: Divya Madala <[email protected]>
1 parent 970646d commit bd9d214

File tree

511 files changed

+812
-22
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

511 files changed

+812
-22
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
name: License Header Checker
3+
4+
on: [push, pull_request]
5+
6+
jobs:
7+
license-header-checker:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@master
11+
- name: Add License Header
12+
uses: kt3k/[email protected]

.licenserc.json

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"**/*.{py,groovy,sh,js,ts}":[
3+
" Copyright OpenSearch Contributors",
4+
" SPDX-License-Identifier: Apache-2.0"
5+
]
6+
}

assemble.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

build.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

checkout.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

ci.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

deployment/.eslintrc.js

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
module.exports = {
211
env: {
312
browser: false,

deployment/bin/build-artifact-stack.ts

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
#!/usr/bin/env node
211
import 'source-map-support/register';
312
import * as cdk from '@aws-cdk/core';

deployment/jest.config.js

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
module.exports = {
211
testEnvironment: 'node',
312
roots: ['<rootDir>/test'],

deployment/lambdas/cf-url-rewriter/cf-url-rewriter.ts

+10-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import { CloudFrontRequest, CloudFrontRequestCallback, CloudFrontRequestEvent, Context } from 'aws-lambda';
211
import { httpsGet } from './https-get';
312

@@ -57,4 +66,4 @@ function errorResponse() {
5766
status: '404',
5867
statusDescription: 'Not found',
5968
};
60-
}
69+
}

deployment/lambdas/cf-url-rewriter/https-get.ts

+10-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import * as https from 'https';
211

312
export async function httpsGet(url: string) {
@@ -32,4 +41,4 @@ export async function httpsGet(url: string) {
3241
});
3342
});
3443
});
35-
}
44+
}

deployment/lib/artifacts-public-access.ts

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import {
211
CloudFrontAllowedMethods, CloudFrontWebDistribution, LambdaEdgeEventType, OriginAccessIdentity
312
} from '@aws-cdk/aws-cloudfront';

deployment/lib/buckets.ts

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import { AnyPrincipal, Role } from '@aws-cdk/aws-iam';
211
import { Bucket, IBucket } from '@aws-cdk/aws-s3';
312

deployment/lib/build-artifact-stack.ts

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import { ArnPrincipal } from '@aws-cdk/aws-iam';
211
import {
312
CfnParameter, Construct, Stack, StackProps,

deployment/lib/identities.ts

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import { ArnPrincipal, IRole, Role } from '@aws-cdk/aws-iam';
211
import { IBucket } from '@aws-cdk/aws-s3';
312
import { Arn, Stack } from '@aws-cdk/core';

deployment/test/build-artifact-stack.test.ts

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import { countResources, expect, haveOutput, haveResourceLike, not } from '@aws-cdk/assert';
211
import { App } from '@aws-cdk/core';
312
import { BuildArtifactStack } from '../lib/build-artifact-stack';

deployment/test/lambdas/cf-url-rewriter/cf-url-rewriter.test.ts

+10-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import { CloudFrontEvent, CloudFrontHeaders, CloudFrontRequest, CloudFrontRequestCallback, CloudFrontRequestEvent, Context } from 'aws-lambda';
211
import { handler } from '../../../lambdas/cf-url-rewriter/cf-url-rewriter';
312
import { httpsGet } from '../../../lambdas/cf-url-rewriter/https-get';
@@ -192,4 +201,4 @@ function createTestEvent(uri: string): CloudFrontRequestEvent {
192201
event.Records = [{ cf: cf }];
193202

194203
return event;
195-
}
204+
}

deployment/test/lambdas/cf-url-rewriter/https-get.test.ts

+10-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
/*
2+
* Copyright OpenSearch Contributors
3+
* SPDX-License-Identifier: Apache-2.0
4+
*
5+
* The OpenSearch Contributors require contributions made to
6+
* this file be licensed under the Apache-2.0 license or a
7+
* compatible open source license.
8+
*/
9+
110
import { ClientRequest } from 'http';
211
import * as https from 'https';
312
import { Stream } from 'stream';
@@ -78,4 +87,4 @@ test('httpGet request error', async () => {
7887
} catch (e) {
7988
expect(e).toBe(error);
8089
}
81-
});
90+
});

docker/ci/build-image-multi-arch.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

docker/ci/build-image-single-arch.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

docker/ci/config/build-opensearch-dashboards-entrypoint.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

docker/ci/config/cypress-setup.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

docker/ci/config/jdk-setup.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

docker/ci/config/yq-setup.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

docker/release/build-image-multi-arch.sh

+8
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
4+
# SPDX-License-Identifier: Apache-2.0
5+
#
6+
# The OpenSearch Contributors require contributions made to
7+
# this file be licensed under the Apache-2.0 license or a
8+
# compatible open source license.
9+
10+
311
set -e
412

513
# Import libs

docker/release/build-image-single-arch.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

lib/shell/file_management.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

lib/shell/process_control.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

manifests.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

publish/publish-snapshot.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
###### Information ############################################################################
45
# SPDX-License-Identifier: Apache-2.0
56
#

publish/stage-maven-release.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
###### Information ############################################################################
45
# SPDX-License-Identifier: Apache-2.0
56
#

release_notes.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

run.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

scripts/components/OpenSearch-Dashboards/install.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

scripts/components/OpenSearch/build.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

scripts/components/OpenSearch/bwctest.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

scripts/components/OpenSearch/install.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

scripts/components/OpenSearch/integtest.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

scripts/components/alerting/integtest.sh

+8
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
4+
# SPDX-License-Identifier: Apache-2.0
5+
#
6+
# The OpenSearch Contributors require contributions made to
7+
# this file be licensed under the Apache-2.0 license or a
8+
# compatible open source license.
9+
10+
311
set -e
412

513
function usage() {

scripts/components/customImportMapDashboards/build.sh

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/bin/bash
22

3+
# Copyright OpenSearch Contributors
34
# SPDX-License-Identifier: Apache-2.0
45
#
56
# The OpenSearch Contributors require contributions made to

0 commit comments

Comments
 (0)