Skip to content

Commit

Permalink
license: add ASF header. (apache#743)
Browse files Browse the repository at this point in the history
  • Loading branch information
moonming authored Oct 31, 2019
1 parent b3b0924 commit 12a2b01
Show file tree
Hide file tree
Showing 227 changed files with 3,879 additions and 56 deletions.
99 changes: 99 additions & 0 deletions .travis/ASF-Release.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
# Licensed to the Apache Software Foundation (ASF) under one or more contributor
# license agreements; and to You under the Apache License, Version 2.0.

# scanCode.py configuration file

# List of filenames containing the text of valid license (headers)
# These files SHOULD be in the same directory path where scanCode.py
# resides.
[Licenses]
ASFLicenseHeader.txt
ASFLicenseHeaderBash.txt
ASFLicenseHeaderMarkdown.txt
ASFLicenseHeaderLua.txt

# Filters (path/filename) with wildcards and associated scan checks
# that are to be run against them. The checks are actual valid
# function names found in scanCode.py.
[Includes]
*=is_not_symlink, regex_check
*.conf=has_block_license, eol_at_eof, regex_check
*.go=has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.gradle=has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.groovy=has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.html=has_block_license, regex_check
*.java=no_tabs, has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.js=has_block_license, regex_check
*.lua=has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.md=no_tabs, has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.properties=no_tabs, has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.py=no_tabs, has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.scala=has_block_license, no_tabs, no_trailing_spaces, eol_at_eof, regex_check
*.sh=has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.swift=no_tabs, has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.yaml=has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.yml=has_block_license, no_trailing_spaces, eol_at_eof, regex_check
*.css=has_block_license, regex_check
*Dockerfile*=has_block_license, no_trailing_spaces

# for test case files of test::nginx
*.t=has_block_license, eol_at_eof, regex_check
*.pm=has_block_license, no_trailing_spaces, eol_at_eof, regex_check

# for APISIX CLI
*/bin/apisix=has_block_license, no_trailing_spaces, eol_at_eof, regex_check

# for luarocks spec files
*.rockspec=has_block_license, no_trailing_spaces, eol_at_eof, regex_check

# Sanity check files not required to have ASF headers because either they
# are excluded or are not packaged with the Apache source release.
*.cfg=regex_check
*.ini=regex_check
*.j2=regex_check
*.json=regex_check
*.txt=regex_check
*.xml=regex_check

# List of paths (inclusive of subdirectories) to exclude from code scanning
[Excludes]

# General tooling & binary file exclusions
.bin
.dockerignore
.eslintrc.*
.git
.gitattributes
.github
.gitignore
.gradle
.idea
.jshintrc
.pydevproject
.rat-excludes
.tox

# Exclude Apache standard legal files
CREDITS.txt
DISCLAIMER.txt
LICENSE*.txt
NOTICE.txt

# Exclude travis CI files
build-cache
deps
test-nginx
.travis.yml

conf
.travis/openwhisk-utilities

[Options]
# Not all code files allow licenses to appear starting at the first character
# of the file. This option tells the scan to allow licenses to appear starting
# within the first 'x' characters of each code file (as provided by this option's
# value).
LICENSE_SLACK_LENGTH=500

# List of regular expressions for forbidden strings, e.g. \[email protected]
[Regex]
18 changes: 18 additions & 0 deletions .travis/ASFLicenseHeaderMarkdown.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->
27 changes: 18 additions & 9 deletions .travis/linux_runner.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
#!/usr/bin/env bash

### BEGIN ###
# Author: idevz
# Since: 08:52:47 2019/07/08
# Description: travis_runnerz_linux.sh
# travis_runner_linux ./travis_runner_linux.sh
#
# Environment variables that control this script:
# OPENRESTY_PREFIX
### END ###
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#

set -ex

Expand Down Expand Up @@ -62,6 +68,9 @@ do_install() {
wget -P utils https://raw.githubusercontent.com/iresty/openresty-devel-utils/iresty/lj-releng
chmod a+x utils/lj-releng

git clone https://github.com/apache/openwhisk-utilities.git .travis/openwhisk-utilities
cp .travis/ASF* .travis/openwhisk-utilities/scancode/

ls -l ./
if [ ! -f "build-cache/grpc_server_example" ]; then
sudo apt-get install golang
Expand Down
25 changes: 17 additions & 8 deletions .travis/osx_runner.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
#!/usr/bin/env bash

### BEGIN ###
# Author: idevz
# Since: 08:52:47 2019/07/08
# Description: travis_runner_osx.sh
# travis_runner_osx ./travis_runner_osx.sh
#
# Environment variables that control this script:
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
### END ###

set -ex

Expand Down Expand Up @@ -40,6 +46,9 @@ do_install() {
wget -P utils https://raw.githubusercontent.com/openresty/openresty-devel-utils/master/lj-releng
chmod a+x utils/lj-releng

git clone https://github.com/apache/openwhisk-utilities.git .travis/openwhisk-utilities
cp .travis/ASF* .travis/openwhisk-utilities/scancode/

cd grpc_server_example/
go build -o grpc_server_example main.go
cd ..
Expand Down
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->

# Table of Contents

- [0.8.0](#080)
Expand Down
19 changes: 19 additions & 0 deletions CHANGELOG_CN.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->

# Table of Contents

- [0.8.0](#080)
Expand Down
19 changes: 19 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->

# Contributor Covenant Code of Conduct

## Our Pledge
Expand Down
19 changes: 19 additions & 0 deletions CODE_STYLE.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->

# OpenResty Lua Coding Style Guide

## indentation
Expand Down
19 changes: 19 additions & 0 deletions Contributing.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->

# Contributing to APISIX

Firstly, thanks for your interest in contributing! I hope that this will be a
Expand Down
19 changes: 19 additions & 0 deletions FAQ.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->

# FAQ

## Why a new API gateway?
Expand Down
19 changes: 19 additions & 0 deletions FAQ_CN.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
<!--
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#
-->

# 常见问题

## 为什么要做 API 网关?不是已经有其他的开源网关了吗?
Expand Down
18 changes: 18 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,20 @@
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You 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.
#

INST_PREFIX ?= /usr
INST_LIBDIR ?= $(INST_PREFIX)/lib64/lua/5.1
INST_LUADIR ?= $(INST_PREFIX)/share/lua/5.1
Expand Down Expand Up @@ -41,6 +58,7 @@ endif
### check: Check Lua source code
.PHONY: check
check:
.travis/openwhisk-utilities/scancode/scanCode.py --config .travis/ASF-Release.cfg ./
luacheck -q lua
./utils/lj-releng lua/*.lua lua/apisix/*.lua \
lua/apisix/admin/*.lua \
Expand Down
Loading

0 comments on commit 12a2b01

Please sign in to comment.