Commit Graph

2179 Commits

Author SHA1 Message Date
Nolan Brubaker
5b28d70e49 Switch event to use pull_request_target (#2807)
The pull_request_target event is like pull_request, but runs in the
context of the target repo (Velero, in this case), instead of the fork.
This allows us to use the GitHub token secret as expected.

Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-08-11 10:57:16 -07:00
Ashish Amarnath
a68e5fc330 🏃‍♂️ Setup crd validation github action on k8s versions (#2805)
Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-08-11 10:45:12 -07:00
Ashish Amarnath
5d6da6517b Implement restore hooks injecting init containers into pod spec (#2787)
*  Implement restore hooks injecting init containers into pod spec

Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-08-11 10:38:44 -07:00
Ashish Amarnath
9b9bb62968 🐛 Make init and exec restore hooks as omitempty in restore hookSpec (#2793)
Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-08-11 10:13:41 -07:00
Abigail McCarthy
4364a813c1 update docs to include cpu/memory defaults for restic (#2772)
* update docs to include cpu/memory defaults

Signed-off-by: Abigail McCarthy <mabigail@vmware.com>

* fixes from review

Signed-off-by: Abigail McCarthy <mabigail@vmware.com>

* updates from review

Signed-off-by: Abigail McCarthy <mabigail@vmware.com>

* update to use kubectl patch command

Signed-off-by: Abigail McCarthy <mabigail@vmware.com>

* update typos and add changes to 1.4 docs

Signed-off-by: Abigail McCarthy <mabigail@vmware.com>
2020-08-10 09:38:35 -07:00
Nolan Brubaker
6edf279bd8 Merge pull request #2803 from vmware-tanzu/dependabot/bundler/site/kramdown-2.3.0
Bump kramdown from 2.2.1 to 2.3.0 in /site
2020-08-10 12:21:40 -04:00
dependabot[bot]
1386a85657 Bump kramdown from 2.2.1 to 2.3.0 in /site
Bumps [kramdown](https://github.com/gettalong/kramdown) from 2.2.1 to 2.3.0.
- [Release notes](https://github.com/gettalong/kramdown/releases)
- [Changelog](https://github.com/gettalong/kramdown/blob/master/doc/news.page)
- [Commits](https://github.com/gettalong/kramdown/commits)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-08 01:14:58 +00:00
Alex Punnen
0b87fbbde8 Update minio.md (#2799)
Added  option for --snapshot-location-config region as else it will give an error during backup - https://github.com/vmware-tanzu/velero-plugin-for-aws/issues/12

Signed-off-by: Alex Punnen <alexcpn@gmail.com>
2020-08-07 14:35:17 -07:00
Mike Tritabaugh
4e2f4bb6af Add resource filtering page (#2771)
* added resource filtering page

Signed-off-by: mtritabaugh <mtritabaugh@vmware.com>

* added resource filtering page to v1.4

Signed-off-by: mtritabaugh <mtritabaugh@vmware.com>

* change  to  per style guide

Signed-off-by: mtritabaugh <mtritabaugh@vmware.com>
2020-08-06 15:09:59 -07:00
Benoit Gagnon
0e8a7a23cb always use groupResource.String() when logging (fixes #2795) (#2796)
Signed-off-by: Benoit Gagnon <benoit.gagnon@ubisoft.com>
2020-08-06 10:10:59 -07:00
Piper Dougherty
19e65689ef Add the ability to set the allowPrivilegeEscalation property on the Restic restore helper via plugin ConfigMap (#2792)
* Add the ability to set the `allowPrivilegeEscalation` security context attribute on the Restic restore helper init container.

Signed-off-by: Piper Dougherty <doughertypiper@gmail.com>

* Add changelog.

Signed-off-by: Piper Dougherty <doughertypiper@gmail.com>

* Fix old tests and add tests for new allowPrivilegeEscalation config option.

Signed-off-by: Piper Dougherty <doughertypiper@gmail.com>

* Correct spelling in changelog.

Signed-off-by: Piper Dougherty <doughertypiper@gmail.com>

* Switch to boolptr type.

Signed-off-by: Piper Dougherty <doughertypiper@gmail.com>

* Reorder imports for sanity.

Signed-off-by: Piper Dougherty <doughertypiper@gmail.com>
2020-08-06 13:08:36 -04:00
Rob Reus
6ac0398c7b Reverting change on 1.4 docs and re-applying to main docs (#2791)
Signed-off-by: Rob Reus <rob@devrobs.nl>
2020-08-04 14:11:52 -07:00
Rob Reus
db139cf07c Refactor image builds to use buildx for multi arch image building (#2754)
* Refactor image builds to use buildx for multi arch image building

Signed-off-by: Rob Reus <rob@devrobs.nl>

* Adding image build sanity checks to Makefile

Signed-off-by: Rob Reus <rob@devrobs.nl>

* Making locally building of docker images possible

Signed-off-by: Rob Reus <rob@devrobs.nl>

* Adding docs on building container images using buildx

Signed-off-by: Rob Reus <rob@devrobs.nl>

* Adding changelog and implementing feedback from PR

Signed-off-by: Rob Reus <rob@devrobs.nl>

* Making GOPROXY used in the build containers configurable

Signed-off-by: Rob Reus <rob@devrobs.nl>
2020-08-04 11:40:05 -07:00
Nolan Brubaker
4e05e81ca2 Merge pull request #2786 from skriss/upd-build-badge
update CI badge on README
2020-08-04 13:55:26 -04:00
Steve Kriss
c5a2137538 update CI badge on README
Signed-off-by: Steve Kriss <krisss@vmware.com>
2020-08-03 12:53:49 -06:00
JenTing Hsiao
1fdb647c7f Add cacert flag for velero backup-location create (#2778)
Signed-off-by: JenTing Hsiao <jenting.hsiao@suse.com>
2020-07-30 11:33:45 -07:00
Ashish Amarnath
9de644f1a4 Add types to implement restore hooks (#2761)
* Add types to implement restore hooks

Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-29 13:29:40 -07:00
Carlisia Campos
5bafa9b317 Add JenTing Hsiao (#2768)
Signed-off-by: Carlisia <carlisia@vmware.com>
2020-07-29 12:41:28 -07:00
Carlisia Campos
fcf7f27967 Moved FAQ (#2769)
* Moved FAQ

Signed-off-by: Carlisia <carlisia@vmware.com>

* Better entry point

Signed-off-by: Carlisia <carlisia@vmware.com>
2020-07-29 10:16:32 -07:00
Ashish Amarnath
028818a053 exclude vols mounting secrets and configmaps from defaultVolumesToRestic (#2762)
Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-27 20:27:49 -07:00
Nolan Brubaker
94872ea2fc Add github token so action can actually auth (#2766)
Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-27 14:35:26 -07:00
Ashish Amarnath
8e672408a2 📖 update VSC DeletionPolicy docs to be inline with code (#2765)
Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-27 13:42:38 -07:00
Nolan Brubaker
7005879f3f Fix YAML in auto-assign GitHub Action (#2759)
Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-24 14:08:09 -07:00
Ashish Amarnath
bc25e789e0 Add constants for restore hook annotation keys (#2750)
* add annotation key constants for restore hooks

Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-24 13:05:27 -07:00
Nolan Brubaker
cffb639380 Auto-assign github PR reviewers and assignee (#2758)
Use a GitHub Action to automatically assign GitHub PRs to the author, as
well as add reviewers.

Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-24 12:58:44 -07:00
Andrew Reed
9011b192e9 Add hooks fields to restore context (#2755)
* Add hooks fields to restore context

Signed-off-by: Andrew Reed <andrew@replicated.com>

* Changelog

Signed-off-by: Andrew Reed <andrew@replicated.com>
2020-07-24 11:43:44 -07:00
Nolan Brubaker
bbcbde084d Create hook package (#2734)
* Move pkg/backup/item_hook_handler to internal/hoo

Signed-off-by: Nolan Brubaker <brubakern@vmware.com>

* Add internal packages to test target

Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-22 14:26:14 -07:00
Nolan Brubaker
e83ec79df3 Merge pull request #2751 from ashish-amarnath/fix-boilerplate
Use correct year for copyright
2020-07-22 15:32:24 -04:00
Ashish Amarnath
2636730ef2 fix copyright year
Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-22 12:11:59 -07:00
Martin Odstrčilík
86efd1577e add support for setting SecurityContext (user, group) for restic restore (#2621)
* add support for setting SecurityContext (user, group) for restic restore

Signed-off-by: Martin Odstrcilik <martin.odstrcilik@gmail.com>
2020-07-22 12:10:25 -07:00
Ashish Amarnath
91ccc4adb2 Add metrics for restic back up operation (#2719)
* add metrics for restic back up operation

Signed-off-by: Ashish Amarnath <ashisham@vmware.com>

* changelog

Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-22 15:07:52 -04:00
Ashish Amarnath
a63a82fcb0 📖 update csi docs to document volumesnapshotclass label (#2741)
Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-22 11:49:47 -07:00
Thejas Babu
d0d143e119 Add StartTimestamp and CompletionTimestamp in Restore Status (#2748)
Signed-off-by: thejas <thejasb99@gmail.com>
2020-07-22 11:40:39 -07:00
Carlisia Campos
c27c3cd56a Fix path + add helpful message (#2740)
Signed-off-by: Carlisia <carlisia@vmware.com>
2020-07-22 11:13:02 -07:00
Nolan Brubaker
84dbd13313 Move style guide to main (#2735)
Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-21 11:30:05 -07:00
Nolan Brubaker
caeb4ae404 Update changelogs for v1.4.2 (#2705)
Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-21 11:14:41 -07:00
Carlisia Campos
e60d9f2821 Remove unneeded auto-generated files (#2732)
Signed-off-by: Carlisia <carlisia@vmware.com>
2020-07-20 15:37:27 -07:00
fvsqr
01e2dcb364 StorageGrid compatibility (#2712)
* remove explicit Accept-Encoding header

For StorageGrid compatibility the Accept-Encoding header should not be set, otherwise StorageGrid compresses the already compressed log files which are only decompressed by the client once

Signed-off-by: fvsqr <48791253+fvsqr@users.noreply.github.com>

* Removed explicit gzip Accept-Encoding header

For StorageGrid compatibility the Accept-Encoding header should not be set, otherwise StorageGrid compresses the already compressed log files which are only decompressed by the client once.
Unclear, how this affects Backup endpoints from Azure or GCP

Signed-off-by: fvsqr <48791253+fvsqr@users.noreply.github.com>

* Create 2712-fvsqr

Signed-off-by: fvsqr <48791253+fvsqr@users.noreply.github.com>
2020-07-20 13:11:26 -04:00
Marc Campbell
9189cffb1c Design proposal for Restore hooks (#2465)
* Add design proposal for restore hooks

Signed-off-by: Marc Campbell <marc.e.campbell@gmail.com>

* Add details to restore hooks design

Signed-off-by: Marc Campbell <marc.e.campbell@gmail.com>

* Restore initContainers and requested changes

Change post-restore exec hooks to wait for container running status
instead of pod ready status.
Add separate exec timeout and wait timeouts for post-restore exec hooks.

Signed-off-by: Marc Campbell <marc.e.campbell@gmail.com>

Co-authored-by: Andrew Reed <andrew@replicated.com>
2020-07-20 08:34:16 -07:00
Nolan Brubaker
f42c63af1b Address insensitive language (#2677)
* Change master to main in most uses

Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-17 14:59:51 -07:00
Nolan Brubaker
2376b697af Fix brew-update script, their commands changed (#2711)
Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-16 15:49:06 -07:00
Ashish Amarnath
eff358e27e replace -q with -f for docker rmi in build-image make target (#2716)
Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-16 13:53:49 -07:00
kathpeony
243ac62e3f Add backupValidationFailureTotal to metrics (#2714)
* Add backValidationFailureTotal to metrics

Signed-off-by: Kathrin Mao <kathrin.mao@sap.com>
2020-07-16 10:13:17 -07:00
Andrew Lavery
a368370bef k8s 1.18 import (#2651)
* k8s 1.18 import wip

backup, cmd, controller, generated, restic, restore, serverstatusrequest, test and util

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* go mod tidy

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* add changelog file

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* go fmt

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* update code-generator and controller-gen in CI

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* checkout proper code-generator version, regen

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* fix remaining calls

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* regenerate CRDs with ./hack/update-generated-crd-code.sh

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* use existing context in restic and server

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* fix test cases by resetting resource version

also use main library go context, not golang.org/x/net/context, in pkg/restore/restore.go

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* clarify changelog message

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* use github.com/kubernetes-csi/external-snapshotter/v2@v2.2.0-rc1

Signed-off-by: Andrew Lavery <laverya@umich.edu>

* run 'go mod tidy' to remove old external-snapshotter version

Signed-off-by: Andrew Lavery <laverya@umich.edu>
2020-07-16 12:21:37 -04:00
Nolan Brubaker
9366fab980 Don't check non-code labeled PRs for changelogs (#2710)
The labels 'Documentation', 'Website', and 'Design' are all for PRs
exclusively related to those things, not code, so they don't need to be
checked for changelogs or have the extra label applied.

Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-14 15:13:47 -07:00
Carlisia Campos
13e1eeabfe Return early from a BSL controller (#2709)
Signed-off-by: Carlisia <carlisia@vmware.com>
2020-07-14 15:09:11 -07:00
Phuong N. Hoang
3239b3e9d5 Design: Backup Resources of Specific Type by Specified Order (#2627)
* azure: support aad-pod-identity auth when using restic (#2602)

Signed-off-by: Steve Kriss <krisss@vmware.com>
Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Add design for BackupOrders.

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Fix format.

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Add changelogs

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Use OrderedResources instead of BackupOrders.

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Add the changelog

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Remove changelogs

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Fix merge accidental change

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Fix wrong line changes

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

* Call out limitation of this design when pods belong to DaemonSet or Deployment get restarted.

Signed-off-by: Phuong Hoang <phuong.n.hoang@dell.com>

Co-authored-by: Steve Kriss <krisss@vmware.com>
Co-authored-by: Phuong Hoang <phuong.n.hoang@dell.com>
2020-07-14 14:52:19 -07:00
Carlisia Campos
dbd0aa4915 Add a BSL controller to handle validation + update BSL status phase (#2674)
* Add BSL controller

Signed-off-by: Carlisia <carlisia@vmware.com>

* Add changelog

Signed-off-by: Carlisia <carlisia@vmware.com>

* Make update

Signed-off-by: Carlisia <carlisia@vmware.com>

* Update docs

Signed-off-by: Carlisia <carlisia@vmware.com>

* Add kubebuilder dependency

Signed-off-by: Carlisia <carlisia@vmware.com>

* Add export

Signed-off-by: Carlisia <carlisia@vmware.com>

* add kubebuilder binaries into velero builder image

Signed-off-by: Ashish Amarnath <ashisham@vmware.com>

* Reset velero dockerfile

Signed-off-by: Carlisia <carlisia@vmware.com>

* Consolidate all logic

Signed-off-by: Carlisia <carlisia@vmware.com>

* Add copyright header

Signed-off-by: Carlisia <carlisia@vmware.com>

* Clean up + add "last validated" column

Signed-off-by: Carlisia <carlisia@vmware.com>

* Better tests

Signed-off-by: Carlisia <carlisia@vmware.com>

* Add more tests

Signed-off-by: Carlisia <carlisia@vmware.com>

* Better logging

Signed-off-by: Carlisia <carlisia@vmware.com>

* Format

Signed-off-by: Carlisia <carlisia@vmware.com>

* Code reviews

Signed-off-by: Carlisia <carlisia@vmware.com>

* Address code review

Signed-off-by: Carlisia <carlisia@vmware.com>

* Remove redundant logic

Signed-off-by: Carlisia <carlisia@vmware.com>

Co-authored-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-14 17:47:00 -04:00
Ashish Amarnath
3d3b9e312a Revert "🐛 fix file perissions on the manifest JSON in backup archive (#2685)" (#2700)
dae5230aae

Signed-off-by: Ashish Amarnath <ashisham@vmware.com>
2020-07-10 14:07:05 -07:00
Nolan Brubaker
a0d2fc2f0e Clarify migration between cloud providers (#2666)
Signed-off-by: Nolan Brubaker <brubakern@vmware.com>
2020-07-09 11:05:09 -07:00