Skip to content

Commit

Permalink
Merge branch 'main' into e2e
Browse files Browse the repository at this point in the history
  • Loading branch information
tisonkun authored Nov 22, 2023
2 parents 858952f + 2cf77ad commit cbf0092
Show file tree
Hide file tree
Showing 20 changed files with 270 additions and 147 deletions.
2 changes: 1 addition & 1 deletion .asf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

# NOTE: All configurations could be found here: https://cwiki.apache.org/confluence/display/INFRA/Git+-+.asf.yaml+features
github:
description: "A Q&A platform software for teams at any scales. Whether it's a community forum, help center, or knowledge management platform, you can always count on Answer."
description: "A Q&A platform software for teams at any scales. Whether it's a community forum, help center, or knowledge management platform, you can always count on Apache Answer."
homepage: https://answer.apache.org
labels:
- react
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/build-image-for-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ jobs:
uses: docker/setup-buildx-action@v2

- name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push
uses: docker/build-push-action@v4
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/build-image-for-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ jobs:
uses: docker/setup-buildx-action@v2

- name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push
uses: docker/build-push-action@v4
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ LABEL maintainer="aichy@sf.com"

ARG GOPROXY
# ENV GOPROXY ${GOPROXY:-direct}
ENV GOPROXY=https://proxy.golang.com.cn,direct
# ENV GOPROXY=https://proxy.golang.com.cn,direct

ENV GOPATH /go
ENV GOROOT /usr/local/go
Expand Down
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,8 @@ install-ui-packages:
ui:
@cd ui && pnpm pre-install && pnpm build && cd -

lint: generate
@bash ./script/check-asf-header.sh
@gofmt -w -l .

all: clean build
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<img alt="logo" src="docs/img/logo.svg" height="99px">
</a>

# Answer - Build Q&A platform
# Apache Answer - Build Q&A platform

A Q&A platform software for teams at any scales. Whether it’s a community forum, help center, or knowledge management platform, you can always count on Answer.

Expand Down Expand Up @@ -36,6 +36,19 @@ We value your feedback and suggestions to improve our documentation. If you have

You can also check out the [plugins here](https://github.com/apache/incubator-answer-plugins).

## Building from Source

### Prerequisites
- Golang >= 1.18
- Node.js >= 16.17
- pnpm >= 8

### Build
```bash
$ make ui
$ make build
```

## Contributing

Contributions are always welcome!
Expand Down
7 changes: 0 additions & 7 deletions SECURITY.md

This file was deleted.

2 changes: 1 addition & 1 deletion charts/templates/hpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# specific language governing permissions and limitations
# under the License.

{{- if .Values.autoscaling.enabled }}
{{ if .Values.autoscaling.enabled -}}
apiVersion: autoscaling/v2beta1
kind: HorizontalPodAutoscaler
metadata:
Expand Down
2 changes: 1 addition & 1 deletion charts/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# specific language governing permissions and limitations
# under the License.

{{- if .Values.ingress.enabled -}}
{{ if .Values.ingress.enabled -}}
{{- $fullName := include "answer.fullname" . -}}
{{- $svcPort := .Values.service.port -}}
{{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }}
Expand Down
2 changes: 1 addition & 1 deletion charts/templates/pvc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# specific language governing permissions and limitations
# under the License.

{{- if .Values.persistence.enabled }}
{{ if .Values.persistence.enabled -}}
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
Expand Down
2 changes: 1 addition & 1 deletion charts/templates/serviceaccount.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# specific language governing permissions and limitations
# under the License.

{{- if .Values.serviceAccount.create -}}
{{ if .Values.serviceAccount.create -}}
apiVersion: v1
kind: ServiceAccount
metadata:
Expand Down
1 change: 0 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ require (
github.com/golang/geo v0.0.0-20190812012225-f41920e961ce // indirect
github.com/golang/snappy v0.0.4 // indirect
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 // indirect
github.com/google/subcommands v1.0.1 // indirect
github.com/gorilla/css v1.0.0 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/imdario/mergo v0.3.16 // indirect
Expand Down
1 change: 0 additions & 1 deletion go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,6 @@ github.com/google/pprof v0.0.0-20221118152302-e6195bd50e26 h1:Xim43kblpZXfIBQsbu
github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 h1:El6M4kTTCOh6aBiKaUGG7oYTSPP8MxqL4YI3kZKwcP4=
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ=
github.com/google/subcommands v1.0.1 h1:/eqq+otEXm5vhfBrbREPCSVQbvofip6kIz+mX5TUH7k=
github.com/google/subcommands v1.0.1/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk=
github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
Expand Down
216 changes: 216 additions & 0 deletions internal/service/mock/siteinfo_repo_mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions licenserc.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,24 @@

headerPath = "Apache-2.0-ASF.txt"

excludes = [
"docs/release/**",
"ui/build/**",
"answer-data/**",
"NOTICE",
"DISCLAIMER",
"Makefile",
"go.mod",
"go.sum",
"ui/.eslintignore",
"ui/.browserslistrc",
"ui/.npmrc",
"ui/.env.*",
"script/plugin_list",
"charts/templates/_helpers.tpl",
"charts/.helmignore",
]

[properties]
inceptionYear = 2023
copyrightOwner = "tison <wander4096@gmail.com>"
Loading

0 comments on commit cbf0092

Please sign in to comment.