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

Add readonly and htpasswd configuration flags #2879

Merged
merged 3 commits into from
May 13, 2024
Merged

Conversation

plar
Copy link
Contributor

@plar plar commented May 9, 2024

Change Overview

This PR introduces 2 new flags to enhance Kopia's server mode.

  • Added a new boolean flag ReadOnly to ServerStartCommandArgs struct. When enabled, this flag ensures that the Kopia server operates in a read-only mode by preventing write operations to the repository.
  • Added a new string argument HtpasswdFilePath to ServerStartCommandArgs struct. This allows Kopia to authenticate users using HTTP authentication.

The new fields in the ServerStartCommandArgs struct have default zero values (false for ReadOnly and "" for HtpasswdFilePath) and should not affect existing code.

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

Signed-off-by: Pavel Larkin <pavel.larkin@veeam.com>
@plar plar requested review from pavannd1, alexvbg and r4rajat May 9, 2024 22:47
@plar plar self-assigned this May 9, 2024
@infraq infraq added this to In Progress in Kanister May 9, 2024
Copy link
Contributor

@julio-lopez julio-lopez left a comment

Choose a reason for hiding this comment

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

+1: LG πŸ‘

Other folks should review though.

Kanister automation moved this from In Progress to Reviewer approved May 10, 2024
Copy link
Contributor

@pavannd1 pavannd1 left a comment

Choose a reason for hiding this comment

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

Can we add this flag to the unit tests in server_test.go?

@plar
Copy link
Contributor Author

plar commented May 13, 2024

Can we add this flag to the unit tests in server_test.go?

Oops, missed a file, got lost among my local changes. Done.

@plar plar requested a review from pavannd1 May 13, 2024 23:12
@plar plar added the kueue label May 13, 2024
@mergify mergify bot merged commit 190f57b into master May 13, 2024
15 checks passed
Kanister automation moved this from Reviewer approved to Done May 13, 2024
@mergify mergify bot deleted the feat-readonly-support branch May 13, 2024 23:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Development

Successfully merging this pull request may close these issues.

None yet

5 participants