mirror of
https://github.com/kopia/kopia.git
synced 2026-03-18 06:06:16 -04:00
* cli: added --tls-print-server-cert flag This prints complete server certificate that is base64 and PEM-encoded. It is needed for Electron to securely connect to the server outside of the browser, since there's no way to trust certificate by fingerprint. * server: added repo/exists API * server: added ClientOptions to create and connect API * server: exposed current-user API * server: API to change description of a repository * htmlui: refactored connect/create flow This cleaned up the code a lot and made UX more obvious. * kopia-ui: simplified repository management UX Removed repository configuration window which was confusing due to the notion of 'server'. Now KopiaUI will automatically launch 'kopia server --ui' for each config found in the kopia config directory and shut it down every time repository is disconnected. See https://youtu.be/P4Ll_LR4UVM for a quick demo. Fixes #583
30 lines
893 B
JavaScript
30 lines
893 B
JavaScript
import React, { Component } from 'react';
|
|
import Form from 'react-bootstrap/Form';
|
|
import { handleChange, OptionalField, RequiredField, validateRequiredFields } from './forms';
|
|
|
|
export class SetupRclone extends Component {
|
|
constructor(props) {
|
|
super();
|
|
|
|
this.state = {
|
|
...props.initial
|
|
};
|
|
this.handleChange = handleChange.bind(this);
|
|
}
|
|
|
|
validate() {
|
|
return validateRequiredFields(this, ["remotePath"])
|
|
}
|
|
|
|
render() {
|
|
return <>
|
|
<Form.Row>
|
|
{RequiredField(this, "Rclone Remote Path", "remotePath", { autoFocus: true, placeholder: "enter <name-of-rclone-remote>:<path>" })}
|
|
</Form.Row>
|
|
<Form.Row>
|
|
{OptionalField(this, "rclone executable", "rcloneExe", { placeholder: "enter path to rclone executable" })}
|
|
</Form.Row>
|
|
</>;
|
|
}
|
|
}
|