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

[kots]: add storage to preflight checks #9939

Merged
merged 1 commit into from
Jun 8, 2022
Merged

Conversation

mrsimonemms
Copy link
Contributor

@mrsimonemms mrsimonemms commented May 11, 2022

Description

Add a storage check to the KOTS preflight checks. This validates that the given configuration is able to create a bucket, upload a file, download a file and then delete the bucket. The bucket names include two randomly generated strings to avoid global name collisions. This checks against Azure, GCP and S3.

In-cluster connections always return as valid

Arguably, it may look a little strange how I've done the test. As the test is for the connection to be valid and we use the commands, I took the view that testing that it's able to fulfil the required requests was a good idea as there's no "are these credentials valid?" command. I'm open to a discussion on a better way if you can think of one

NB Azure doesn't test the region because this is defined on the storage account and the access key/secret are generated within the storage account.

Related Issue(s)

Fixes #9933

How to test

Install with KOTS - the version to use is sje-kots-storage-check.10 in sje/kots-storage-check channel

Release Notes

[kots]: add storage to preflight checks

Documentation

@mrsimonemms
Copy link
Contributor Author

mrsimonemms commented May 12, 2022

/werft run no-preview publish-to-kots

👍 started the job as gitpod-build-sje-kots-storage-check.6
(with .werft/ from main)

@mrsimonemms mrsimonemms changed the title WIP: [kots]: add storage to preflight checks [kots]: add storage to preflight checks May 12, 2022
@mrsimonemms mrsimonemms marked this pull request as ready for review May 12, 2022 11:18
@mrsimonemms mrsimonemms requested a review from a team May 12, 2022 11:18
@github-actions github-actions bot added the team: delivery Issue belongs to the self-hosted team label May 12, 2022
@corneliusludmann corneliusludmann changed the base branch from main to sje/kots-config-check May 17, 2022 07:46
@roboquat roboquat added size/L and removed size/XL labels May 17, 2022
Copy link
Contributor

@corneliusludmann corneliusludmann left a comment

Choose a reason for hiding this comment

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

Great!

Putting this on hold for now until we handled my comments in #9759.

@mrsimonemms mrsimonemms force-pushed the sje/kots-config-check branch from 9271a07 to 5f69faf Compare May 30, 2022 15:15
Base automatically changed from sje/kots-config-check to main June 1, 2022 12:16
@roboquat roboquat added size/XL and removed size/L labels Jun 1, 2022
@mrsimonemms mrsimonemms force-pushed the sje/kots-storage-check branch from 1fccdca to f2aec10 Compare June 1, 2022 12:31
@roboquat roboquat added size/L and removed size/XL labels Jun 1, 2022
@mrsimonemms
Copy link
Contributor Author

mrsimonemms commented Jun 1, 2022

/werft run no-preview publish-to-kots

👍 started the job as gitpod-build-sje-kots-storage-check.8
(with .werft/ from main)

This checks the connection is correct, based upon the configuration
given.
@mrsimonemms mrsimonemms force-pushed the sje/kots-storage-check branch from f2aec10 to 4db0500 Compare June 1, 2022 16:49
@mrsimonemms mrsimonemms marked this pull request as ready for review June 1, 2022 17:05
@mrsimonemms
Copy link
Contributor Author

mrsimonemms commented Jun 1, 2022

/werft run no-preview publish-to-kots

👍 started the job as gitpod-build-sje-kots-storage-check.10
(with .werft/ from main)

Copy link
Contributor

@nandajavarma nandajavarma left a comment

Choose a reason for hiding this comment

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

Tested this and the changes look good!

@roboquat roboquat merged commit 3c63e7e into main Jun 8, 2022
@roboquat roboquat deleted the sje/kots-storage-check branch June 8, 2022 15:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note size/L team: delivery Issue belongs to the self-hosted team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

KOTS storage checks
4 participants