Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding a configurable env for EFS backup vault name #1090

Merged
merged 7 commits into from
Sep 23, 2021
Merged

Conversation

bathina2
Copy link
Contributor

Change Overview

This lets the EFS backup vault name be configurable via an environment variable.

Pull request type

Please check the type of change your PR introduces:

  • 🚧 Work in Progress
  • 🌈 Refactoring (no functional changes, no api changes)
  • 🐹 Trivial/Minor
  • 🐛 Bugfix
  • 🌻 Feature
  • 🗺️ Documentation
  • 🤖 Test

Test Plan

  • 💪 Manual
  • ⚡ Unit test
  • 💚 E2E

)

var (
efsBackupVaultName = getEnvAsStringOrDefault(efsBackupVaultNameEnv, defaultK10BackupVaultName)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bathina2 - can we add this to the config map - see NewEFSProvider instead of environment variables?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vkamra This will be set in the config map and referred to as an environment variable. See https://github.com/kastenhq/k10/pull/13188

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh you mean as an input to create the Provider.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh you mean as an input to create the Provider.

Yep 👍

pkg/aws/aws.go Outdated
ConfigEFSVaultName = "efsVaultName"
// EfsBackupVaultNameEnv describes the environment variable used to set the
// backup vault name.
EfsBackupVaultNameEnv = "EFS_BACKUP_VAULT_NAME"
Copy link

@vkamra vkamra Sep 22, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove this one please

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why? That's how it will be referenced through K10?

testMarker = ""
efsType = "EFS"
defaultK10BackupVaultName = "k10vault"
testMarker = ""
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's this? Should be removed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should also be there. This is the default value in case it's set.

Copy link
Contributor

@carlbraganza carlbraganza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bathina2 bathina2 added the kueue label Sep 23, 2021
@mergify mergify bot merged commit 7ae5cd0 into master Sep 23, 2021
@mergify mergify bot deleted the efs-vault-name branch September 23, 2021 17:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants