317 Commits

Author SHA1 Message Date
Keepers
cc3306e5e0
validate required storage props (#85) (#108)
* validate required storage props (#85)

Centralizes validation of required storage config properties within
the storage package.  Requiremens are checked eagerly at
configuration creation, and lazily at config retrieval.

Additionally, updates /pkg/storage tests to use suites
and assert funcs.

* add validation failure tests to storage
2022-06-02 15:33:19 -06:00
Keepers
535cb9e1f5
add common config and encryption passwd (#74) (#99)
* add common config and encryption passwd

Adds a provider-independent configuration handler, and the
the encryption password config property.  The password is used
to encrypt and decrypt the kopia repository properties file.

* fix corso_password in ci.yml

* actually use the corso password in testing

* replace passwd in ci.yml with a secret

* ci.yml secret typo fix
2022-06-01 16:00:41 -06:00
Keepers
f368c596b5
add readme to corso/src (#101) (#102)
Additional documentation to help guide new developers through the
repository layout and design decisions backing that layout.
2022-06-01 12:05:26 -06:00
Keepers
596a4cc37b
initial repo init integration test (#90) (#96)
Implements an integration test in the repository that runs an end-
to-end test of an s3 repo initialization through kopia.
2022-05-31 18:32:26 -06:00
Keepers
eaf6018996
add prefix flag for s3 (#94)
* add prefix flag for s3

Adds the flag --prefix for s3 repo init and creation.

* fix missing prefix flag in repo s3 cli
2022-05-27 17:22:50 -06:00
Vaibhav Kamra
d34175bd19
Use testify for repository tests (#88) 2022-05-27 10:25:24 -07:00
Keepers
d923c4072b
expose s3 endpoint as flag (#87)
Exposes the s3 endpoint option as a cli flag and storage config
property.  Uses the kopia default s3.amazonaws.com as a fallback.
2022-05-27 09:11:26 -06:00
Keepers
e6663fd0f1
changes requried for manual repo init (#25) (#80)
A small collection of changes and code cleanup to successfully run
'corso repo init s3' manually.  Adds a default s3 url (might want
this configurable for local testing) and aws session token support.
2022-05-25 17:27:23 -06:00
Keepers
548eb1be72
add e2e wiring of cli to kopia (#77)
* add e2e wiring of cli to kopia

Now that pkg/storage and internal/kopia are in place, we
can wire up the init flow from the cli all the way to kopia.  Testing
harness for this functionality still needs investigation afterward.

* factor out awsVars struct for s3Cfg
2022-05-25 14:06:05 -06:00
Keepers
569ba524ac
adds kopia pkg to handle integration (#25) (#76)
* adds kopia pkg to handle integration (#25)

internal/kopia will be used to abstract all kopia integration in a
central location.

* defer blob.Storage closure in kopia

blob.Storage objects must get closed at the end of their usage.
This currently isn't getting called.
2022-05-25 13:08:47 -06:00
Keepers
99358c5d6e
introduces storage pkg (#25) (#73)
* introduces storage pkg (#25)

Adds a new package /pkg/storage.  Storage is used to
communicate storage provider information throughout the corso
app.  In particular, it allows per-provider data to cross interface
boundaries without slicing their details.

* use consts for s3 config keys
2022-05-25 09:50:52 -06:00
Keepers
f2d5c878a3
adds s3 repo commands to the cli (#67)
Adds the s3 provider set to the repo cli commands.  Flag, env
vars, and other configuration is still incomplete and will require
iteration.  But this sets us up for quick testing of the commands.
2022-05-20 15:20:15 -06:00
Keepers
2ae4f4cdcb
introduce repository api scaffold with s3 (#6) (#54)
* introduce repository api scaffold with s3 (#6)

introduces the public repository package in /pkg, with a
skeleton implementation for generating the s3 provider config
and boilerplate for where that usage gets centralized.

* condense init/connect to single action

A double-pass NewRepo() && Connect() allows Repository structs
to exist independent guarantees that their usage will be successful.
This hides the struct generation within the Connect and Initialize
funcs so that the construction and guarantees can occur as
a single process.
2022-05-19 16:05:33 -06:00
Keepers
82c9a1f182
Add 'repo' cli command set (#31)
Adds the 'repo' command and its primary subcommands to the
Corso cli command list.
2022-05-09 16:15:07 -06:00
Keepers
a352ddf8a1
add coba and cli to corso (#30)
Adds the spf13/cobra cli handling package.  Main() now
processes cli commands defined by the /cli package.
2022-05-09 13:36:44 -06:00
Ashlie Martinez
0734a990d2 Move/update gomode file.
Now reflects the fact that this will be cloned from github. Also place
in source directory so that all packages in the project don't need to be
`src/foo`.
2022-05-03 16:12:30 -07:00
ryanfkeepers
6d1b8325e5 initializing directory structure and github actions 2022-04-27 17:49:17 -06:00