Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 13 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,25 @@ Follow these steps to add a new version:

### Foreman

Generate API docs in Foreman:
Fetch API docs for Foreman:

1. cd to foreman directory and checkout the relevant stable branch
1. disable any plugins installed locally
1. `APIPIE_RECORD=examples bundle exec rake test`
1. `FOREMAN_APIPIE_LANGS=en bundle exec rake apipie:cache`
1. Go to https://github.com/theforeman/foreman/actions/workflows/foreman.yml?query=branch%3AX.Y-stable
1. Pick the latest run of the action
1. Download the `apidoc-*` artifact (there might be multiple, pick any one of them)

You can also do this from the CLI using `gh`:
```
gh run download --repo theforeman/foreman --pattern 'apidoc-*' $(gh run list --repo theforeman/foreman --workflow foreman.yml --branch X.Y-stable --status completed --limit 1 --json databaseId --jq '.[].databaseId')
```
Note: `gh` will automatically unzip the artifacts, so you only have to copy them.

Prepare folder for the new version (X.Y)

1. cd to foreman directory
1. `cd foreman`
1. `cp -r TEMPLATE X.Y`
1. `ln -snf X.Y latest`
1. `cp -r dir/to/foreman/public/apipie-cache/apidoc/* X.Y/apidoc`
1. run cleanup script in apidocs repo: `cleanup.sh`
1. `unzip -d X.Y/apidoc ~/Downloads/apidoc-<…>.zip`
1. run cleanup script in the root of the apidocs repo: `cleanup.sh`
1. update index.html file with a link to the new page

### Katello
Expand Down