Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/qiuming-best/velero into pe…
Browse files Browse the repository at this point in the history
…rf-test
  • Loading branch information
qiuming-best committed Aug 15, 2023
2 parents 3b45830 + 713792d commit 6095198
Show file tree
Hide file tree
Showing 62 changed files with 803 additions and 181 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/pr-ci-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ jobs:
- name: Make ci
run: make ci
- name: Upload test coverage
uses: codecov/codecov-action@v2
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: coverage.out
verbose: true
fail_ci_if_error: true
6 changes: 4 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ COPY . /go/src/github.com/vmware-tanzu/velero
RUN mkdir -p /output/usr/bin && \
export GOARM=$( echo "${GOARM}" | cut -c2-) && \
go build -o /output/${BIN} \
-ldflags "${LDFLAGS}" ${PKG}/cmd/${BIN}
-ldflags "${LDFLAGS}" ${PKG}/cmd/${BIN} && \
go build -o /output/velero-helper \
-ldflags "${LDFLAGS}" ${PKG}/cmd/velero-helper

# Restic binary build section
FROM --platform=$BUILDPLATFORM golang:1.20-bullseye as restic-builder
Expand All @@ -52,7 +54,7 @@ ARG TARGETARCH
ARG TARGETVARIANT
ARG RESTIC_VERSION

env CGO_ENABLED=0 \
ENV CGO_ENABLED=0 \
GO111MODULE=on \
GOPROXY=${GOPROXY} \
GOOS=${TARGETOS} \
Expand Down
1 change: 1 addition & 0 deletions changelogs/unreleased/6558-kaovilai
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Non default s3 credential profiles work on Unified Repository Provider (kopia)
1 change: 1 addition & 0 deletions changelogs/unreleased/6587-Lyndon-Li
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix issue 6575, flush the repo after delete the snapshot, otherwise, the changes(deleting repo snapshot) cannot be committed to the repo.
1 change: 1 addition & 0 deletions changelogs/unreleased/6594-Lyndon-Li
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix issue #6571, fix the problem for restore item operation to set the errors correctly so that they can be recorded by Velero restore and then reflect the correct status for Velero restore.
1 change: 1 addition & 0 deletions changelogs/unreleased/6598-aws_creds
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix how the AWS credentials are obtained from configuration
1 change: 1 addition & 0 deletions changelogs/unreleased/6634-27149chen
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fixes #6498. Get resource client again after restore actions in case resource's gv is changed. This is an improvement of pr #6499, to support group changes. A group change usually happens in a restore plugin which is used for resource conversion: convert a resource from a not supported gv to a supported gv
27 changes: 27 additions & 0 deletions cmd/velero-helper/velero-helper.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
package main

import (
"fmt"
"os"
"time"
)

const (
// workingModePause indicates it is for general purpose to hold the pod under running state
workingModePause = "pause"
)

func main() {
if len(os.Args) < 2 {
fmt.Fprintln(os.Stderr, "ERROR: at least one argument must be provided, the working mode")
os.Exit(1)
}

switch os.Args[1] {
case workingModePause:
time.Sleep(time.Duration(1<<63 - 1))
default:
fmt.Fprintln(os.Stderr, "ERROR: wrong working mode provided")
os.Exit(1)
}
}
4 changes: 2 additions & 2 deletions config/crd/v1/crds/crds.go

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion config/crd/v2alpha1/bases/velero.io_datauploads.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ spec:
nullable: true
properties:
snapshotClass:
description: StorageClass is the name of the snapshot class that
description: SnapshotClass is the name of the snapshot class that
the volume snapshot is created with
type: string
storageClass:
Expand Down
2 changes: 1 addition & 1 deletion config/crd/v2alpha1/crds/crds.go

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

2 changes: 1 addition & 1 deletion design/upload-progress.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ will be deleted and at that point any uploads still in progress should be aborte

### Uploading (new)
The "Uploading" phase signifies that the main part of the backup, including snapshotting has completed successfully
and and uploading is continuing. In the event of an error during uploading, the phase will change to
and uploading is continuing. In the event of an error during uploading, the phase will change to
UploadingPartialFailure. On success, the phase changes to Completed. The backup cannot be
restored from when it is in the Uploading state.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ spec:
of the CSI snapshot.
properties:
snapshotClass:
description: StorageClass is the name of the snapshot class that
description: SnapshotClass is the name of the snapshot class that
the volume snapshot is created with
type: string
storageClass:
Expand Down
4 changes: 2 additions & 2 deletions hack/update-1fmt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ fi

files="$(find . -type f -name '*.go' -not -path './.go/*' -not -path './vendor/*' -not -path './site/*' -not -path '*/generated/*' -not -name 'zz_generated*' -not -path '*/mocks/*')"
echo "${ACTION} gofmt"
output=$(printf '%s\n' "${files}" | xargs gofmt "${MODE}" -s)
output=$(gofmt "${MODE}" -s ${files})
if [[ -n "${output}" ]]; then
VERIFY_FMT_FAILED=1
echo "${output}"
Expand All @@ -47,7 +47,7 @@ else
fi

echo "${ACTION} goimports"
output=$(printf '%s\n' "${files}" | xargs goimports "${MODE}" -local github.com/vmware-tanzu/velero)
output=$(goimports "${MODE}" -local github.com/vmware-tanzu/velero ${files})
if [[ -n "${output}" ]]; then
VERIFY_IMPORTS_FAILED=1
echo "${output}"
Expand Down
Loading

0 comments on commit 6095198

Please sign in to comment.