Skip to content

Commit

Permalink
Merge pull request #464 from sighupio/fix/velero-eks-on-newer-version…
Browse files Browse the repository at this point in the history
…s-template-patch

Fix: velero eks on newer versions template patch
  • Loading branch information
nutellinoit committed Jan 16, 2024
2 parents 8fe5807 + eaac707 commit 8a5be35
Show file tree
Hide file tree
Showing 7 changed files with 184 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<!-- FIXME: UPDATE THE BUILD BADGE WITH THE RIGHT BRANCH -->

[![Build Status](https://ci.sighup.io/api/badges/sighupio/furyctl/status.svg)](https://ci.sighup.io/sighupio/furyctl)
![Release](https://img.shields.io/badge/furyctl-v0.27.0-blue)
![Release](https://img.shields.io/badge/furyctl-v0.27.1-blue)
![Slack](https://img.shields.io/badge/slack-@kubernetes/fury-yellow.svg?logo=slack)
![License](https://img.shields.io/github/license/sighupio/furyctl)
[![Go Report Card](https://goreportcard.com/badge/github.com/sighupio/furyctl)](https://goreportcard.com/report/github.com/sighupio/furyctl)
Expand Down Expand Up @@ -76,7 +76,7 @@ $ furyctl version
...
goVersion: go1.21
osArch: amd64
version: 0.27.0
version: 0.27.1
```

### Installing from source
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Copyright (c) 2017-present SIGHUP s.r.l All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.

# THIS FILE HAS BEEN PATCHED BY FURYCTL TO ENSURE BACKWARDS COMPATIBILITY.
# IT IS NOT THE ORIGINAL FILE FOUND IN THE DISTRIBUTION REPOSITORY.

{{- if eq .spec.distribution.common.provider.type "eks" }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
annotations:
eks.amazonaws.com/role-arn: {{ .spec.distribution.modules.dr.velero.eks.iamRoleArn }}
name: velero
namespace: kube-system
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: velero
namespace: kube-system
spec:
template:
spec:
containers:
- name: velero
volumeMounts:
- name: cloud-credentials
mountPath: /credentials
$patch: delete
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /credentials/cloud
$patch: delete
- name: AWS_SHARED_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
- name: AZURE_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
volumes:
- name: cloud-credentials
$patch: delete
{{- end }}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Copyright (c) 2017-present SIGHUP s.r.l All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.

# THIS FILE HAS BEEN PATCHED BY FURYCTL TO ENSURE BACKWARDS COMPATIBILITY.
# IT IS NOT THE ORIGINAL FILE FOUND IN THE DISTRIBUTION REPOSITORY.

{{- if eq .spec.distribution.common.provider.type "eks" }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
annotations:
eks.amazonaws.com/role-arn: {{ .spec.distribution.modules.dr.velero.eks.iamRoleArn }}
name: velero
namespace: kube-system
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: velero
namespace: kube-system
spec:
template:
spec:
containers:
- name: velero
volumeMounts:
- name: cloud-credentials
mountPath: /credentials
$patch: delete
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /credentials/cloud
$patch: delete
- name: AWS_SHARED_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
- name: AZURE_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
volumes:
- name: cloud-credentials
$patch: delete
{{- end }}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Copyright (c) 2017-present SIGHUP s.r.l All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.

# THIS FILE HAS BEEN PATCHED BY FURYCTL TO ENSURE BACKWARDS COMPATIBILITY.
# IT IS NOT THE ORIGINAL FILE FOUND IN THE DISTRIBUTION REPOSITORY.

{{- if eq .spec.distribution.common.provider.type "eks" }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
annotations:
eks.amazonaws.com/role-arn: {{ .spec.distribution.modules.dr.velero.eks.iamRoleArn }}
name: velero
namespace: kube-system
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: velero
namespace: kube-system
spec:
template:
spec:
containers:
- name: velero
volumeMounts:
- name: cloud-credentials
mountPath: /credentials
$patch: delete
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /credentials/cloud
$patch: delete
- name: AWS_SHARED_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
- name: AZURE_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
volumes:
- name: cloud-credentials
$patch: delete
{{- end }}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Copyright (c) 2017-present SIGHUP s.r.l All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.

# THIS FILE HAS BEEN PATCHED BY FURYCTL TO ENSURE BACKWARDS COMPATIBILITY.
# IT IS NOT THE ORIGINAL FILE FOUND IN THE DISTRIBUTION REPOSITORY.

{{- if eq .spec.distribution.common.provider.type "eks" }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
annotations:
eks.amazonaws.com/role-arn: {{ .spec.distribution.modules.dr.velero.eks.iamRoleArn }}
name: velero
namespace: kube-system
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: velero
namespace: kube-system
spec:
template:
spec:
containers:
- name: velero
volumeMounts:
- name: cloud-credentials
mountPath: /credentials
$patch: delete
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /credentials/cloud
$patch: delete
- name: AWS_SHARED_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
- name: AZURE_CREDENTIALS_FILE
value: /credentials/cloud
$patch: delete
volumes:
- name: cloud-credentials
$patch: delete
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ func (d *Distribution) prepare() (template.Config, error) {
if getStorageClassesOutput == "No resources found" {
logrus.Warn(
"No storage classes found in the cluster. " +
"logging module (if enabled), dr module (if enabled) " +
"logging module (if enabled), tracing module (if enabled), dr module (if enabled) " +
"and prometheus-operated package installation will be skipped. " +
"You need to install a StorageClass and re-run furyctl to install the missing components.",
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ func (d *Distribution) prepare() (template.Config, error) {
if getStorageClassesOutput == "No resources found" {
logrus.Warn(
"No storage classes found in the cluster. " +
"logging module (if enabled), dr module (if enabled) " +
"logging module (if enabled), tracing module (if enabled), dr module (if enabled) " +
"and prometheus-operated package installation will be skipped. " +
"You need to install a StorageClass and re-run furyctl to install the missing components.",
)
Expand Down

0 comments on commit 8a5be35

Please sign in to comment.