-
Notifications
You must be signed in to change notification settings - Fork 35
repository doc example #278
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
Changes from 13 commits
ceb4285
db6f02b
982687c
a49ebbc
fb1315f
af27744
0c04e6a
7b3020e
03c20bf
18c5604
b40c858
2a4a94d
6855ca6
67481cc
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,10 +1,54 @@ | ||
| --- | ||
| title: "Setting Up Repositories" | ||
| title: "Managing Porch Repositories" | ||
| type: docs | ||
| weight: 2 | ||
| description: | ||
| description: "Tutorial on setting up porch repositories and using them. Before Porch can manage packages, you must register the Git repositories where those packages are stored. This tells Porch where to find package blueprints and where to store deployment packages." | ||
lapentad marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| --- | ||
|
|
||
| ## Lorem Ipsum | ||
| If you don't have a Git repository already created and initialized, follow the steps below to create and use your own Git repository. | ||
|
|
||
| tutorial in setting up porch repositories and using them | ||
| ## Creating and initializing a Git Repository | ||
|
|
||
| 1. **Create a new repository** in your Git hosting service (e.g., GitHub, GitLab, Gitea, Bitbucket). Navigate to your user or organization page and create a new repository. Provide a name (e.g., `porch-repo`), description, and set visibility as needed. | ||
lapentad marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| 2. **Initialize the repository** for the main/master branch to exist (typically done by adding a README.md file in the UI) or by cloning it locally and add initial content. | ||
lapentad marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| For detailed instructions on repository creation, refer to your Git hosting service documentation. [For example on GitHub](https://docs.github.com/en/repositories/creating-and-managing-repositories/quickstart-for-repositories). | ||
|
|
||
| ## Register a Git-Repository as a Porch-Repository | ||
|
|
||
| The `porchctl` command-line tool provides a straightforward way to register a repository. | ||
|
|
||
| ### Command Syntax | ||
|
|
||
| The basic command for registering a repository is: | ||
|
|
||
| ```bash | ||
| porchctl repo register REPOSITORY [flags] | ||
| ``` | ||
|
|
||
| For more information about the `repo` command and available flags, see the porchctl CLI guide [Repository registration]({{% relref "/docs/neo-porch/7_cli_api/relevant_old_docs/porchctl-cli-guide.md#repository-registration" %}}). | ||
lapentad marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ### Example | ||
|
|
||
| This example registers a private Git repository hosted on Gitea and configures it as a deployment repository. | ||
|
|
||
| ```bash | ||
| # Register a Git repository with Porch | ||
| porchctl repo register http://gitea.gitea:3000/nephio/porch-test.git \ | ||
| --name=porch-test \ | ||
| --description="Test repository for Porch packages" \ | ||
| --branch=main \ | ||
| --deployment=true \ | ||
| --repo-basic-username=nephio \ | ||
| --repo-basic-password=secret | ||
| ``` | ||
|
|
||
|
Comment on lines
+38
to
+47
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. now that i think of it this shows input and no output.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. maybe even a FAQ of common registration issues reason for repo not being ready e.g. invalid password/username combo etc |
||
| {{% alert title="Note" color="primary" %}} | ||
| Replace the Git URL, repository name, username, and password with your values. | ||
lapentad marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| {{% /alert %}} | ||
|
|
||
| # See Also | ||
|
|
||
| In this example we demonstrate a simple HTTP Basic auth setup using a Kubernetes `Secret`. For production environments, prefer secret management solutions (external secret stores, sealed-secrets, or platform secrets) and avoid embedding plaintext credentials in scripts. | ||
lapentad marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| [Authenticating to Remote Git Repositories]({{% relref "/docs/neo-porch/6_configuration_and_deployments/relevant_old_docs/git-authentication-config.md" %}}) | ||
Uh oh!
There was an error while loading. Please reload this page.