Skip to content

Add new remotes backend to bravetools.#125

Merged
idroz merged 1 commit intobravetools:masterfrom
Szubie:multiple-remotes
Aug 12, 2022
Merged

Add new remotes backend to bravetools.#125
idroz merged 1 commit intobravetools:masterfrom
Szubie:multiple-remotes

Conversation

@Szubie
Copy link
Collaborator

@Szubie Szubie commented Aug 12, 2022

Remotes are stored in a new "remotes" folder in bravetools home dir. A remote is a human-editable json file and associates a remote with a name, address, and protocol. TLS auth for a remote is loaded if necessary.

For now, the only remote is the default bravetools local remote created during init - if all works fine then next step is to expose the ability to select and create different remotes to users.

Multiple protocols are supported for backends, allowing for use of the Unix socket when running on Linux for less overhead. This also potentially allows for storing remote "simplestreams" image stores as remotes too.

Remotes are stored in a new "remotes" folder in bravetools home dir.
A remote is a human-editable json file and associates a remote with a name, address, and protocol.
TLS auth for a remote is loaded if necessary.

For now, the only remote is the default bravetools local remote created
during init - if all works fine then next step is to expose the ability to select
different remotes to users.
@@ -21,6 +21,12 @@ const PlatformConfig = BraveHome + "/config.yml"
// ImageStore ..
const ImageStore = BraveHome + "/images/"
Copy link
Contributor

Choose a reason for hiding this comment

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

for these paths, can we have filepath.Join to make it more os-agnostic

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Unfortunately filepath.Join does not work with constants.

However, Windows is pretty good about accepting forward slashes in paths nowadays - many paths bravetools currently creates are actually a mixture of forward and backwards slashes and they still work fine.

@idroz idroz merged commit bcf8619 into bravetools:master Aug 12, 2022
@Szubie Szubie deleted the multiple-remotes branch September 3, 2022 19:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants