-
Notifications
You must be signed in to change notification settings - Fork 21
Install Test Storage Backend for Hub when USE_TEST_SETUP=true
#655
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
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
b136050
Include Test storage backend in Capact installation for testing purposes
pkosiec e8cf713
Register Test Storage Backend
pkosiec 1d1aa40
Build image and update test instruction
pkosiec 9e7d712
Generate docs for Populator
pkosiec c9a79a9
Fix providers
pkosiec 9bc8e84
Improve comment and chart description
pkosiec File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| package cmd | ||
|
|
||
| import ( | ||
| "capact.io/capact/internal/frontmatter" | ||
| "github.com/spf13/cobra" | ||
| "github.com/spf13/cobra/doc" | ||
| ) | ||
|
|
||
| const ( | ||
| docsTargetDir = "./cmd/populator/docs" | ||
| ) | ||
|
|
||
| // NewDocs returns a cobra.Command for generating Populator documentation. | ||
| func NewDocs(cliName string) *cobra.Command { | ||
| return &cobra.Command{ | ||
| Use: "gen-usage-docs", | ||
| Hidden: true, | ||
| Short: "Generate usage documentation", | ||
| RunE: func(cmd *cobra.Command, args []string) error { | ||
| root := NewRoot(cliName) | ||
| root.DisableAutoGenTag = true | ||
|
|
||
| defaultLinkHandler := func(s string) string { return s } | ||
| return doc.GenMarkdownTreeCustom(root, docsTargetDir, frontmatter.FilePrepender, defaultLinkHandler) | ||
| }, | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| package register | ||
|
|
||
| import ( | ||
| "capact.io/capact/internal/cli/testing" | ||
| "github.com/docker/cli/cli" | ||
| "github.com/spf13/cobra" | ||
|
|
||
| "capact.io/capact/internal/cli/heredoc" | ||
| ) | ||
|
|
||
| // NewTestStorageBackend returns a cobra.Command for populating storage backend TypeInstance for testing purposes. | ||
| func NewTestStorageBackend(cliName string) *cobra.Command { | ||
| return &cobra.Command{ | ||
| Use: "test-storage-backend", | ||
| Short: "Produces and uploads TypeInstances which describe storage backend for testing purposes", | ||
| Example: heredoc.WithCLIName(` | ||
| <cli> test-storage-backend | ||
| `, cliName), | ||
| Args: cli.RequiresMaxArgs(1), | ||
| RunE: func(cmd *cobra.Command, args []string) error { | ||
| storageRegister, err := testing.NewStorageBackendRegister() | ||
| if err != nil { | ||
| return err | ||
| } | ||
| return storageRegister.RegisterTypeInstances(cmd.Context()) | ||
| }, | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| --- | ||
| title: populator | ||
| --- | ||
|
|
||
| ## populator | ||
|
|
||
|
|
||
|
|
||
| ``` | ||
| populator [flags] | ||
| ``` | ||
|
|
||
| ### Options | ||
|
|
||
| ``` | ||
| -h, --help help for populator | ||
| ``` | ||
|
|
||
| ### SEE ALSO | ||
|
|
||
| * [populator register](populator_register.md) - This command consists of multiple subcommands which allows you to register Capact resources | ||
|
|
21 changes: 0 additions & 21 deletions
21
cmd/populator/docs/populator_register-capact-installation.md
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| --- | ||
| title: populator register | ||
| --- | ||
|
|
||
| ## populator register | ||
|
|
||
| This command consists of multiple subcommands which allows you to register Capact resources | ||
|
|
||
| ### Options | ||
|
|
||
| ``` | ||
| -h, --help help for register | ||
| ``` | ||
|
|
||
| ### SEE ALSO | ||
|
|
||
| * [populator](populator.md) - | ||
| * [populator register capact-installation](populator_register_capact-installation.md) - Produces and uploads TypeInstances which describe Capact installation | ||
| * [populator register ocf-manifests](populator_register_ocf-manifests.md) - Populates locally available manifests into Neo4j database | ||
| * [populator register test-storage-backend](populator_register_test-storage-backend.md) - Produces and uploads TypeInstances which describe storage backend for testing purposes | ||
|
|
29 changes: 29 additions & 0 deletions
29
cmd/populator/docs/populator_register_capact-installation.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| --- | ||
| title: populator register capact-installation | ||
| --- | ||
|
|
||
| ## populator register capact-installation | ||
|
|
||
| Produces and uploads TypeInstances which describe Capact installation | ||
|
|
||
| ``` | ||
| populator register capact-installation [flags] | ||
| ``` | ||
|
|
||
| ### Examples | ||
|
|
||
| ``` | ||
| populator capact-installation | ||
|
|
||
| ``` | ||
|
|
||
| ### Options | ||
|
|
||
| ``` | ||
| -h, --help help for capact-installation | ||
| ``` | ||
|
|
||
| ### SEE ALSO | ||
|
|
||
| * [populator register](populator_register.md) - This command consists of multiple subcommands which allows you to register Capact resources | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| --- | ||
| title: populator register ocf-manifests | ||
| --- | ||
|
|
||
| ## populator register ocf-manifests | ||
|
|
||
| Populates locally available manifests into Neo4j database | ||
|
|
||
| ``` | ||
| populator register ocf-manifests [MANIFEST_PATH] [flags] | ||
| ``` | ||
|
|
||
| ### Examples | ||
|
|
||
| ``` | ||
| APP_JSON_PUBLISH_ADDR=http://{HOST_IP} populator . | ||
|
|
||
| ``` | ||
|
|
||
| ### Options | ||
|
|
||
| ``` | ||
| -h, --help help for ocf-manifests | ||
| --source strings Manifests location | ||
| ``` | ||
|
|
||
| ### SEE ALSO | ||
|
|
||
| * [populator register](populator_register.md) - This command consists of multiple subcommands which allows you to register Capact resources | ||
|
|
29 changes: 29 additions & 0 deletions
29
cmd/populator/docs/populator_register_test-storage-backend.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| --- | ||
| title: populator register test-storage-backend | ||
| --- | ||
|
|
||
| ## populator register test-storage-backend | ||
|
|
||
| Produces and uploads TypeInstances which describe storage backend for testing purposes | ||
|
|
||
| ``` | ||
| populator register test-storage-backend [flags] | ||
| ``` | ||
|
|
||
| ### Examples | ||
|
|
||
| ``` | ||
| populator test-storage-backend | ||
|
|
||
| ``` | ||
|
|
||
| ### Options | ||
|
|
||
| ``` | ||
| -h, --help help for test-storage-backend | ||
| ``` | ||
|
|
||
| ### SEE ALSO | ||
|
|
||
| * [populator register](populator_register.md) - This command consists of multiple subcommands which allows you to register Capact resources | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.