Skip to content

[cloudprober] Add support for reading files from S3 and GCS. - #396

Merged
manugarg merged 3 commits into
masterfrom
file_s3_http
May 10, 2024
Merged

manugarg merged 3 commits into
masterfrom
file_s3_http

Conversation

@manugarg

Copy link
Copy Markdown
Contributor

This applies to all kinds of file resources:

  • File based targets
  • TLS certificate files
  • OAuth token files
  • Cloudprober config itself.

@manugarg manugarg added this to the v0.12.8 milestone Jun 1, 2023
@manugarg manugarg added the enhancement New feature or request label Jun 1, 2023
@manugarg manugarg modified the milestones: v0.12.8, v0.12.9 Jul 25, 2023
@manugarg manugarg removed this from the v0.12.9 milestone Aug 24, 2023
@theduke

theduke commented Sep 9, 2023

Copy link
Copy Markdown

Would be awesome to get this merged!

Without checking if this is already done: would be great if the code saved a snapshot of the most recently retrieved content for the config and targets, so that if the backend should be down, or someone uploaded a bad config, the checks still keep working.

Also: does this watch for changes and automatically reapplies, like with local files?

 - File based targets
 - TLS certificate files
 - OAuth token files
 - Cloudprober config itself.
@manugarg

Copy link
Copy Markdown
Contributor Author

Note about this change: It will increase convenience but it will make cloudprober run dependent on external configs. For the most part it's okay -- it will only make debugging a bit harder as you'll have to find the external file content when cloudprober started running. Maybe, as @theduke suggested above, we can cache file contents locally, which will be useful in two cases:

a. to debug.
b. for the restarts where external file service is unavailable and you need to restart. Note, ideally, you don't want to start if you cannot get the latest content, so maybe we'll provide a flag to use cache if actual file is not available -- it will not be the default behavior.

I'll consider hashing this out and implementing it in a different pull request / issue.

@manugarg
manugarg merged commit 9e5800a into master May 10, 2024
@manugarg
manugarg deleted the file_s3_http branch May 10, 2024 22:59
manugarg added a commit that referenced this pull request May 10, 2024
* This applies to all kinds of file resources:

 - File based targets
 - TLS certificate files
 - OAuth token files
 - Cloudprober config itself.
allagoichuk added a commit to allagoichuk/cloudprober that referenced this pull request Jun 22, 2024
…er#396

as path.join converts double slash into single slash
manugarg pushed a commit that referenced this pull request Jun 25, 2024
#396 broke accessing Google Storage as path.join converts any double slash into a single slash.
@manugarg manugarg added this to the v0.13.5 milestone Jun 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants