Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into point-in-time-recovery
Browse files Browse the repository at this point in the history
  • Loading branch information
mattlord committed Jul 12, 2024
2 parents 2f7768a + 65518cb commit 34b93ad
Show file tree
Hide file tree
Showing 42 changed files with 3,419 additions and 313 deletions.
40 changes: 31 additions & 9 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
agents:
queue: "public"

env:
GO_VERSION_FILE: "go1.22.5.linux-amd64.tar.gz"

# Mount the docker.sock as to the docker container, so that we are able to
# run docker build command and kind is spawned as a sibling container.
steps:
- name: "Upgrade Test"
command:
- apk add g++ make bash gcompat curl mysql mysql-client libc6-compat
- wget https://golang.org/dl/go1.22.2.linux-amd64.tar.gz
- tar -C /usr/local -xzf go1.22.2.linux-amd64.tar.gz
- wget https://golang.org/dl/$GO_VERSION_FILE
- tar -C /usr/local -xzf $GO_VERSION_FILE
- export PATH=$PATH:/usr/local/go/bin
- rm go1.22.2.linux-amd64.tar.gz
- rm $GO_VERSION_FILE
- ln -s /lib/libc.so.6 /usr/lib/libresolv.so.2
- make upgrade-test
concurrency: 1
Expand All @@ -26,10 +29,10 @@ steps:
- name: "Backup Restore Test"
command:
- apk add g++ make bash gcompat curl mysql mysql-client libc6-compat
- wget https://golang.org/dl/go1.22.2.linux-amd64.tar.gz
- tar -C /usr/local -xzf go1.22.2.linux-amd64.tar.gz
- wget https://golang.org/dl/$GO_VERSION_FILE
- tar -C /usr/local -xzf $GO_VERSION_FILE
- export PATH=$PATH:/usr/local/go/bin
- rm go1.22.2.linux-amd64.tar.gz
- rm $GO_VERSION_FILE
- ln -s /lib/libc.so.6 /usr/lib/libresolv.so.2
- make backup-restore-test
concurrency: 1
Expand All @@ -42,13 +45,32 @@ steps:
volumes:
- "/var/run/docker.sock:/var/run/docker.sock"

- name: "Backup Schedule Test"
command:
- apk add g++ make bash gcompat curl mysql mysql-client libc6-compat
- wget https://golang.org/dl/$GO_VERSION_FILE
- tar -C /usr/local -xzf $GO_VERSION_FILE
- export PATH=$PATH:/usr/local/go/bin
- rm $GO_VERSION_FILE
- ln -s /lib/libc.so.6 /usr/lib/libresolv.so.2
- make backup-schedule-test
concurrency: 1
concurrency_group: 'vtop/backup-schedule-test'
timeout_in_minutes: 60
plugins:
- docker#v3.12.0:
image: "docker:latest"
propagate-environment: true
volumes:
- "/var/run/docker.sock:/var/run/docker.sock"

- name: "VTOrc and VTAdmin Test"
command:
- apk add g++ make bash gcompat curl mysql mysql-client libc6-compat chromium
- wget https://golang.org/dl/go1.22.2.linux-amd64.tar.gz
- tar -C /usr/local -xzf go1.22.2.linux-amd64.tar.gz
- wget https://golang.org/dl/$GO_VERSION_FILE
- tar -C /usr/local -xzf $GO_VERSION_FILE
- export PATH=$PATH:/usr/local/go/bin
- rm go1.22.2.linux-amd64.tar.gz
- rm $GO_VERSION_FILE
- ln -s /lib/libc.so.6 /usr/lib/libresolv.so.2
- make vtorc-vtadmin-test
concurrency: 1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/integration-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.22.2
go-version: 1.22.5
id: go

- name: Check out code into the Go module directory
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/make-generate-and-diff.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.22.2
go-version: 1.22.5
id: go

- name: Check out code into the Go module directory
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.22.2
go-version: 1.22.5
id: go

- name: Check out code into the Go module directory
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/upgrade-vitess-dependency.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.22.2
go-version: 1.22.5

- name: Check out code into the Go module directory
uses: actions/checkout@v2
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -80,3 +80,5 @@ tags
### Intellij IDEs ###
.idea/*
# End of https://www.gitignore.io/api/go,vim,emacs,visualstudiocode

**/vtdataroot
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ backup-restore-test: build e2e-test-setup
echo "Running Backup-Restore test"
test/endtoend/backup_restore_test.sh

backup-schedule-test: build e2e-test-setup
echo "Running Backup-Schedule test"
test/endtoend/backup_schedule_test.sh

vtorc-vtadmin-test: build e2e-test-setup
echo "Running VTOrc and VtAdmin test"
test/endtoend/vtorc_vtadmin_test.sh
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ compatible with certain Vitess and Kubernetes versions, as shown in this table:
| `v2.10.*` | `v17.0.*` | `v1.22.*`, `v1.23.*`, `v1.24.*`, or `v1.25.*` |
| `v2.11.*` | `v18.0.*` | `v1.22.*`, `v1.23.*`, `v1.24.*`, or `v1.25.*` |
| `v2.12.*` | `v19.0.*` | `v1.25.*`, `v1.26.*`, `v1.27.*`, or `v1.28.*` |
| `v2.13.*` | `v20.0.*` | `v1.25.*`, `v1.26.*`, `v1.27.*`, or `v1.28.*` |
| `latest` | `latest` | `v1.25.*`, `v1.26.*`, `v1.27.*`, or `v1.28.*` |

If for some reason you must attempt to use versions outside the recommend
Expand Down
2 changes: 1 addition & 1 deletion build/Dockerfile.release
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# without messing up file permissions, since the Docker container doesn't run as
# your actual user.

FROM golang:1.22.2 AS build
FROM golang:1.22.5 AS build

ENV GO111MODULE=on
WORKDIR /go/src/planetscale.dev/vitess-operator
Expand Down
171 changes: 171 additions & 0 deletions deploy/crds/planetscale.com_vitessbackupschedules.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,171 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.11.3
creationTimestamp: null
name: vitessbackupschedules.planetscale.com
spec:
group: planetscale.com
names:
kind: VitessBackupSchedule
listKind: VitessBackupScheduleList
plural: vitessbackupschedules
singular: vitessbackupschedule
scope: Namespaced
versions:
- name: v2
schema:
openAPIV3Schema:
properties:
apiVersion:
type: string
kind:
type: string
metadata:
type: object
spec:
properties:
affinity:
x-kubernetes-preserve-unknown-fields: true
allowedMissedRun:
minimum: 0
type: integer
annotations:
additionalProperties:
type: string
type: object
cluster:
type: string
concurrencyPolicy:
enum:
- Allow
- Forbid
example: Forbid
type: string
failedJobsHistoryLimit:
format: int32
minimum: 0
type: integer
image:
type: string
imagePullPolicy:
type: string
jobTimeoutMinute:
default: 10
format: int32
minimum: 0
type: integer
name:
example: every-day
minLength: 1
pattern: ^[A-Za-z0-9]([A-Za-z0-9-]*[A-Za-z0-9])?$
type: string
resources:
properties:
claims:
items:
properties:
name:
type: string
required:
- name
type: object
type: array
x-kubernetes-list-map-keys:
- name
x-kubernetes-list-type: map
limits:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
type: object
requests:
additionalProperties:
anyOf:
- type: integer
- type: string
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
x-kubernetes-int-or-string: true
type: object
type: object
schedule:
example: 0 0 * * *
minLength: 0
type: string
startingDeadlineSeconds:
format: int64
minimum: 0
type: integer
strategies:
items:
properties:
extraFlags:
additionalProperties:
type: string
type: object
keyspace:
example: commerce
type: string
name:
enum:
- BackupShard
type: string
shard:
example: '-'
type: string
required:
- keyspace
- name
- shard
type: object
minItems: 1
type: array
successfulJobsHistoryLimit:
format: int32
minimum: 0
type: integer
suspend:
type: boolean
required:
- cluster
- name
- resources
- schedule
- strategies
type: object
status:
properties:
active:
items:
properties:
apiVersion:
type: string
fieldPath:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
resourceVersion:
type: string
uid:
type: string
type: object
x-kubernetes-map-type: atomic
type: array
lastScheduledTime:
format: date-time
type: string
type: object
type: object
served: true
storage: true
subresources:
status: {}
Loading

0 comments on commit 34b93ad

Please sign in to comment.