-
Notifications
You must be signed in to change notification settings - Fork 594
Increase rclone startup timeout #4472
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
Conversation
increase rclone startup timeout from 15 seconds to 15 minutes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of changing the const / fixed default value, make the value configurable, persist it in the configuration and use the same default value as before.
To my understanding, it is already configurable: However, this is useless on the UI builds, for which you can't modify the configuration (at least, I couldn't see how to). |
|
@julio-lopez , please could you have another look at this? |
|
The rclone storage provider has a |
|
@julio-lopez I would say modifying the default value is desirable, because it clearly blocks me and others from using kopia. If it is higher, I do not see any downsides major enough to warrant blocking people from using the app. |
|
|
||
| // rcloneStartupTimeout is the time we wait for rclone to print the https address it's serving at. | ||
| rcloneStartupTimeout = 15 * time.Second | ||
| rcloneStartupTimeout = 15 * time.Minute |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the default of 15 minutes is way too high, I would be ok with 1 minute
+1 to what Julio says about making it configurable. Configuration options like this are actually quite easy to expose in the CLI and UI.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jkowalski
My current rclone config takes 3 minutes and 10 seconds to start up. (I realise this may not be normal, but nevertheless.) So I wouldn't mind 5 minutes, but 1 minute wouldn't help me (though might resolve others' problems).
I believe you when you say it would be easy, but I'm not confident enough in my own programming knowledge to attempt this with no knowledge of go.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding a field in UI configuration is easily copy-pasteable:
You need to change:
https://github.com/kopia/htmlui/blob/main/src/components/SetupRepositoryRclone.jsx
Adding OptionalNumberField for a field named startupTimeout should do the trick.
https://github.com/kopia/htmlui/blob/1e35b648ac5a9444dce2d07fdbede9abb78daf83/src/components/SetupRepositorySFTP.jsx#L62C17-L62C103 is an example.
Instructions for testing UI changes are in the readme file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, that does look easy enough to implement, but I can't get it to build on my system.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you need to install npm from NodeJS and then npm install in htmlui directory followed by npm run build should do the trick.
npm run serve should launch the UI for testing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So the readme says to run go run . server start --insecure --without-password --disable-csrf-token-checks --log-level=debug --config-file=$HOME/.config/kopia/disabled/repository-dev.config to start the server (running in kopia directory), which works and serves a webpage on port 51515.
Then I ran npm etc. and it served on port 3000 and failed to load.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like running the server builds with the html from htmlui?
|
Am I correct in understanding (given #4543 was merged) that the change needs to be made to htmlui rather than this repository, and so this pull request can be closed? |
Increase rclone startup timeout from 15 seconds to 15 minutes
Should fix #2573