Browse Source

Merge branch 'master' of https://github.com/seaweedfs/seaweedfs

pull/4868/head
chrislu 1 year ago
parent
commit
c9177c92e5
  1. 4
      .github/workflows/binaries_dev.yml
  2. 2
      .github/workflows/binaries_release0.yml
  3. 2
      .github/workflows/binaries_release1.yml
  4. 2
      .github/workflows/binaries_release2.yml
  5. 2
      .github/workflows/binaries_release3.yml
  6. 2
      .github/workflows/binaries_release4.yml
  7. 2
      .github/workflows/codeql.yml
  8. 2
      .github/workflows/container_dev.yml
  9. 2
      .github/workflows/container_latest.yml
  10. 2
      .github/workflows/container_release1.yml
  11. 2
      .github/workflows/container_release2.yml
  12. 2
      .github/workflows/container_release3.yml
  13. 2
      .github/workflows/container_release4.yml
  14. 2
      .github/workflows/container_release5.yml
  15. 2
      .github/workflows/depsreview.yml
  16. 2
      .github/workflows/e2e.yml
  17. 2
      .github/workflows/go.yml
  18. 2
      .github/workflows/helm_chart_release.yml
  19. 2
      .github/workflows/helm_ci.yml
  20. 12
      docker/Makefile
  21. 4
      docker/compose/tls.env
  22. 5
      weed/replication/sub/notification_aws_sqs.go

4
.github/workflows/binaries_dev.yml

@ -38,7 +38,7 @@ jobs:
steps: steps:
- name: Check out code into the Go module directory - name: Check out code into the Go module directory
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Set BUILD_TIME env - name: Set BUILD_TIME env
run: echo BUILD_TIME=$(date -u +%Y%m%d-%H%M) >> ${GITHUB_ENV} run: echo BUILD_TIME=$(date -u +%Y%m%d-%H%M) >> ${GITHUB_ENV}
@ -87,7 +87,7 @@ jobs:
steps: steps:
- name: Check out code into the Go module directory - name: Check out code into the Go module directory
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Set BUILD_TIME env - name: Set BUILD_TIME env
run: echo BUILD_TIME=$(date -u +%Y%m%d-%H%M) >> ${GITHUB_ENV} run: echo BUILD_TIME=$(date -u +%Y%m%d-%H%M) >> ${GITHUB_ENV}

2
.github/workflows/binaries_release0.yml

@ -28,7 +28,7 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job # Steps represent a sequence of tasks that will be executed as part of the job
steps: steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Go Release Binaries Normal Volume Size - name: Go Release Binaries Normal Volume Size
uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22 uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22
with: with:

2
.github/workflows/binaries_release1.yml

@ -28,7 +28,7 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job # Steps represent a sequence of tasks that will be executed as part of the job
steps: steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Go Release Binaries Normal Volume Size - name: Go Release Binaries Normal Volume Size
uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22 uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22
with: with:

2
.github/workflows/binaries_release2.yml

@ -28,7 +28,7 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job # Steps represent a sequence of tasks that will be executed as part of the job
steps: steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Go Release Binaries Normal Volume Size - name: Go Release Binaries Normal Volume Size
uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22 uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22
with: with:

2
.github/workflows/binaries_release3.yml

@ -28,7 +28,7 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job # Steps represent a sequence of tasks that will be executed as part of the job
steps: steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Go Release Binaries Normal Volume Size - name: Go Release Binaries Normal Volume Size
uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22 uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22
with: with:

2
.github/workflows/binaries_release4.yml

@ -28,7 +28,7 @@ jobs:
# Steps represent a sequence of tasks that will be executed as part of the job # Steps represent a sequence of tasks that will be executed as part of the job
steps: steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Go Release Binaries Normal Volume Size - name: Go Release Binaries Normal Volume Size
uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22 uses: wangyoucao577/go-release-action@2ac3035fa4c4feed6a8272ce278b0577b93cf8e5 # v1.22
with: with:

2
.github/workflows/codeql.yml

@ -18,7 +18,7 @@ jobs:
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
# Initializes the CodeQL tools for scanning. # Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL - name: Initialize CodeQL

2
.github/workflows/container_dev.yml

@ -16,7 +16,7 @@ jobs:
steps: steps:
- -
name: Checkout name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- -
name: Docker meta name: Docker meta
id: docker_meta id: docker_meta

2
.github/workflows/container_latest.yml

@ -17,7 +17,7 @@ jobs:
steps: steps:
- -
name: Checkout name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- -
name: Docker meta name: Docker meta
id: docker_meta id: docker_meta

2
.github/workflows/container_release1.yml

@ -16,7 +16,7 @@ jobs:
steps: steps:
- -
name: Checkout name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- -
name: Docker meta name: Docker meta
id: docker_meta id: docker_meta

2
.github/workflows/container_release2.yml

@ -17,7 +17,7 @@ jobs:
steps: steps:
- -
name: Checkout name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- -
name: Docker meta name: Docker meta
id: docker_meta id: docker_meta

2
.github/workflows/container_release3.yml

@ -17,7 +17,7 @@ jobs:
steps: steps:
- -
name: Checkout name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- -
name: Docker meta name: Docker meta
id: docker_meta id: docker_meta

2
.github/workflows/container_release4.yml

@ -16,7 +16,7 @@ jobs:
steps: steps:
- -
name: Checkout name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- -
name: Docker meta name: Docker meta
id: docker_meta id: docker_meta

2
.github/workflows/container_release5.yml

@ -16,7 +16,7 @@ jobs:
steps: steps:
- -
name: Checkout name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- -
name: Docker meta name: Docker meta
id: docker_meta id: docker_meta

2
.github/workflows/depsreview.yml

@ -9,6 +9,6 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: 'Checkout Repository' - name: 'Checkout Repository'
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- name: 'Dependency Review' - name: 'Dependency Review'
uses: actions/dependency-review-action@6c5ccdad469c9f8a2996bfecaec55a631a347034 uses: actions/dependency-review-action@6c5ccdad469c9f8a2996bfecaec55a631a347034

2
.github/workflows/e2e.yml

@ -30,7 +30,7 @@ jobs:
id: go id: go
- name: Check out code into the Go module directory - name: Check out code into the Go module directory
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Install dependencies - name: Install dependencies
run: | run: |

2
.github/workflows/go.yml

@ -27,7 +27,7 @@ jobs:
id: go id: go
- name: Check out code into the Go module directory - name: Check out code into the Go module directory
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v2
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
- name: Get dependencies - name: Get dependencies
run: | run: |

2
.github/workflows/helm_chart_release.yml

@ -12,7 +12,7 @@ jobs:
release: release:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
- uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
- name: Publish Helm charts - name: Publish Helm charts
uses: stefanprodan/helm-gh-pages@master uses: stefanprodan/helm-gh-pages@master
with: with:

2
.github/workflows/helm_ci.yml

@ -16,7 +16,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608
with: with:
fetch-depth: 0 fetch-depth: 0

12
docker/Makefile

@ -102,12 +102,12 @@ clean:
rm ./weed rm ./weed
certstrap: certstrap:
go get github.com/square/certstrap
certstrap --depot-path compose/tls init --passphrase "" --common-name "SeaweedFS CA" || true
certstrap --depot-path compose/tls request-cert --passphrase "" --common-name volume01.dev || true
certstrap --depot-path compose/tls request-cert --passphrase "" --common-name master01.dev || true
certstrap --depot-path compose/tls request-cert --passphrase "" --common-name filer01.dev || true
certstrap --depot-path compose/tls request-cert --passphrase "" --common-name client01.dev || true
go install -v github.com/square/certstrap@latest
certstrap --depot-path compose/tls init --curve P-256 --passphrase "" --common-name "SeaweedFS CA" || true
certstrap --depot-path compose/tls request-cert --ou "SeaweedFS" --curve P-256 --passphrase "" --domain localhost --common-name volume01.dev || true
certstrap --depot-path compose/tls request-cert --ou "SeaweedFS" --curve P-256 --passphrase "" --common-name master01.dev || true
certstrap --depot-path compose/tls request-cert --ou "SeaweedFS" --curve P-256 --passphrase "" --common-name filer01.dev || true
certstrap --depot-path compose/tls request-cert --ou "SeaweedFS" --curve P-256 --passphrase "" --common-name client01.dev || true
certstrap --depot-path compose/tls sign --CA "SeaweedFS CA" volume01.dev || true certstrap --depot-path compose/tls sign --CA "SeaweedFS CA" volume01.dev || true
certstrap --depot-path compose/tls sign --CA "SeaweedFS CA" master01.dev || true certstrap --depot-path compose/tls sign --CA "SeaweedFS CA" master01.dev || true
certstrap --depot-path compose/tls sign --CA "SeaweedFS CA" filer01.dev || true certstrap --depot-path compose/tls sign --CA "SeaweedFS CA" filer01.dev || true

4
docker/compose/tls.env

@ -12,5 +12,9 @@ WEED_GRPC_MASTER_ALLOWED_COMMONNAMES="volume01.dev,master01.dev,filer01.dev,clie
WEED_GRPC_VOLUME_ALLOWED_COMMONNAMES="volume01.dev,master01.dev,filer01.dev,client01.dev" WEED_GRPC_VOLUME_ALLOWED_COMMONNAMES="volume01.dev,master01.dev,filer01.dev,client01.dev"
WEED_GRPC_FILER_ALLOWED_COMMONNAMES="volume01.dev,master01.dev,filer01.dev,client01.dev" WEED_GRPC_FILER_ALLOWED_COMMONNAMES="volume01.dev,master01.dev,filer01.dev,client01.dev"
WEED_GRPC_CLIENT_ALLOWED_COMMONNAMES="volume01.dev,master01.dev,filer01.dev,client01.dev" WEED_GRPC_CLIENT_ALLOWED_COMMONNAMES="volume01.dev,master01.dev,filer01.dev,client01.dev"
WEED_HTTPS_CLIENT_ENABLE=true
WEED_HTTPS_VOLUME_CERT=/etc/seaweedfs/tls/volume01.dev.crt
WEED_HTTPS_VOLUME_KEY=/etc/seaweedfs/tls/volume01.dev.key
WEED_HTTPS_VOLUME_CA=/etc/seaweedfs/tls/SeaweedFS_CA.crt
#GRPC_GO_LOG_SEVERITY_LEVEL=info #GRPC_GO_LOG_SEVERITY_LEVEL=info
#GRPC_GO_LOG_VERBOSITY_LEVEL=2 #GRPC_GO_LOG_VERBOSITY_LEVEL=2

5
weed/replication/sub/notification_aws_sqs.go

@ -99,7 +99,10 @@ func (k *AwsSqsInput) ReceiveMessage() (key string, message *filer_pb.EventNotif
text := *result.Messages[0].Body text := *result.Messages[0].Body
message = &filer_pb.EventNotification{} message = &filer_pb.EventNotification{}
err = proto.Unmarshal([]byte(text), message) err = proto.Unmarshal([]byte(text), message)
if err != nil {
err = fmt.Errorf("unmarshal message from sqs %s: %w", k.queueUrl, err)
return
}
// delete the message // delete the message
_, err = k.svc.DeleteMessage(&sqs.DeleteMessageInput{ _, err = k.svc.DeleteMessage(&sqs.DeleteMessageInput{
QueueUrl: &k.queueUrl, QueueUrl: &k.queueUrl,

Loading…
Cancel
Save