summaryrefslogtreecommitdiffstats
path: root/docs/content/usage/packages/chef.en-us.md
diff options
context:
space:
mode:
authorJohn Olheiser <john.olheiser@gmail.com>2023-07-25 21:00:14 -0500
committerGitHub <noreply@github.com>2023-07-26 10:00:14 +0800
commit4033d95dbf1eb525130a0701bfc58c0844220f7c (patch)
tree1a710272b1a3157fa3d26246ef2a7bd752d09571 /docs/content/usage/packages/chef.en-us.md
parent43213b816d4cc4de9dd46a7b667925516e305443 (diff)
downloadgitea-4033d95dbf1eb525130a0701bfc58c0844220f7c.tar.gz
gitea-4033d95dbf1eb525130a0701bfc58c0844220f7c.zip
Docusaurus-ify 1.20 (#26052)
See https://github.com/go-gitea/gitea/pull/26051 --------- Signed-off-by: jolheiser <john.olheiser@gmail.com> Co-authored-by: JonRB <4564448+eeyrjmr@users.noreply.github.com>
Diffstat (limited to 'docs/content/usage/packages/chef.en-us.md')
-rw-r--r--docs/content/usage/packages/chef.en-us.md93
1 files changed, 93 insertions, 0 deletions
diff --git a/docs/content/usage/packages/chef.en-us.md b/docs/content/usage/packages/chef.en-us.md
new file mode 100644
index 0000000000..9f23b9eac8
--- /dev/null
+++ b/docs/content/usage/packages/chef.en-us.md
@@ -0,0 +1,93 @@
+---
+date: "2023-01-20T00:00:00+00:00"
+title: "Chef Package Registry"
+slug: "chef"
+sidebar_position: 5
+draft: false
+toc: false
+menu:
+ sidebar:
+ parent: "packages"
+ name: "Chef"
+ sidebar_position: 5
+ identifier: "chef"
+---
+
+# Chef Package Registry
+
+Publish [Chef](https://chef.io/) cookbooks for your user or organization.
+
+## Requirements
+
+To work with the Chef package registry, you have to use [`knife`](https://docs.chef.io/workstation/knife/).
+
+## Authentication
+
+The Chef package registry does not use an username:password authentication but signed requests with a private:public key pair.
+Visit the package owner settings page to create the necessary key pair.
+Only the public key is stored inside Gitea. if you loose access to the private key you must re-generate the key pair.
+[Configure `knife`](https://docs.chef.io/workstation/knife_setup/) to use the downloaded private key with your Gitea username as `client_name`.
+
+## Configure the package registry
+
+To [configure `knife`](https://docs.chef.io/workstation/knife_setup/) to use the Gitea package registry add the url to the `~/.chef/config.rb` file.
+
+```
+knife[:supermarket_site] = 'https://gitea.example.com/api/packages/{owner}/chef'
+```
+
+| Parameter | Description |
+| --------- | ----------- |
+| `owner` | The owner of the package. |
+
+## Publish a package
+
+To publish a Chef package execute the following command:
+
+```shell
+knife supermarket share {package_name}
+```
+
+| Parameter | Description |
+| -------------- | ----------- |
+| `package_name` | The package name. |
+
+You cannot publish a package if a package of the same name and version already exists. You must delete the existing package first.
+
+## Install a package
+
+To install a package from the package registry, execute the following command:
+
+```shell
+knife supermarket install {package_name}
+```
+
+Optional you can specify the package version:
+
+```shell
+knife supermarket install {package_name} {package_version}
+```
+
+| Parameter | Description |
+| ----------------- | ----------- |
+| `package_name` | The package name. |
+| `package_version` | The package version. |
+
+## Delete a package
+
+If you want to remove a package from the registry, execute the following command:
+
+```shell
+knife supermarket unshare {package_name}
+```
+
+Optional you can specify the package version:
+
+```shell
+knife supermarket unshare {package_name}/versions/{package_version}
+```
+
+| Parameter | Description |
+| ----------------- | ----------- |
+| `package_name` | The package name. |
+| `package_version` | The package version. |