Compare commits

..

No commits in common. "1aa9d9efb51f08f70272e38143c2555711d24804" and "89b91f66da98fdfb8b28b9c68a68cee215f89ff4" have entirely different histories.

3 changed files with 16 additions and 2 deletions

View File

@ -1,5 +1,5 @@
# Build a small image # Build a small image
FROM --platform=${BUILDPLATFORM} golang:alpine3.17 AS builder FROM --platform=${BUILDPLATFORM} golang:alpine3 AS builder
ARG TARGETOS ARG TARGETOS
ARG TARGETARCH ARG TARGETARCH
ARG TARGETPLATFORM ARG TARGETPLATFORM

View File

@ -20,11 +20,15 @@ vet:
.PHONY: docker-build-multiarch .PHONY: docker-build-multiarch
docker-build-multiarch: docker-build-multiarch:
buildah bud --manifest $(MANIFEST) --platform=$(PLATFORMS) --layers . buildah bud --manifest $(MANIFEST) --platform=$(PLATFORMS) .
.PHONY: docker-push .PHONY: docker-push
docker-push: docker-push:
buildah manifest push --all --rm $(MANIFEST) "docker://$(IMG)" buildah manifest push --all --rm $(MANIFEST) "docker://$(IMG)"
.PHONY: docker-build-multiarch
docker-build-multiarch:
buildah bud --manifest $(MANIFEST) --platform linux/amd64,linux/arm64/v8 .
.PHONY: all .PHONY: all
all: formolcli docker-build all: formolcli docker-build

View File

@ -8,6 +8,7 @@ import (
corev1 "k8s.io/api/core/v1" corev1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/types"
utilruntime "k8s.io/apimachinery/pkg/util/runtime" utilruntime "k8s.io/apimachinery/pkg/util/runtime"
clientgoscheme "k8s.io/client-go/kubernetes/scheme" clientgoscheme "k8s.io/client-go/kubernetes/scheme"
"k8s.io/client-go/rest" "k8s.io/client-go/rest"
@ -182,6 +183,15 @@ func StartRestore(
func CreateBackupSession(ref corev1.ObjectReference) { func CreateBackupSession(ref corev1.ObjectReference) {
log := session.Log.WithName("CreateBackupSession") log := session.Log.WithName("CreateBackupSession")
log.V(0).Info("CreateBackupSession called") log.V(0).Info("CreateBackupSession called")
backupConf := formolv1alpha1.BackupConfiguration{}
if err := session.Get(session.Context, types.NamespacedName{
Namespace: ref.Namespace,
Name: ref.Name,
}, &backupConf); err != nil {
log.Error(err, "unable to get backupconf")
os.Exit(1)
}
log.V(0).Info("got backupConf", "backupConf", backupConf)
backupSession := &formolv1alpha1.BackupSession{ backupSession := &formolv1alpha1.BackupSession{
ObjectMeta: metav1.ObjectMeta{ ObjectMeta: metav1.ObjectMeta{