Skip to content

Commit

Permalink
Enable plugin writers to install packages on the host OS
Browse files Browse the repository at this point in the history
[noissue]
  • Loading branch information
lubosmj committed Jun 26, 2024
1 parent 747bcf8 commit 6f2bebb
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,9 @@ The following settings are stored in `template_config.yml`.

docs_test Include a CI build for testing the 'make html' command for sphinx docs.

os_required_packages A list of packages to be installed on the host OS (Ubuntu) in the build
step.

parallel_test_workers Run tests in parallel using `pytest-xdist` with N parallel runners. This
settings specifies N. By default it is 8.

Expand Down
1 change: 1 addition & 0 deletions plugin-template
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ DEFAULT_SETTINGS = {
"latest_release_branch": None,
"lint_requirements": True,
"noissue_marker": "[noissue]",
"os_required_packages": [],
"parallel_test_workers": 8,
"plugin_app_label": None,
"plugin_default_branch": "main",
Expand Down
5 changes: 5 additions & 0 deletions templates/github/.github/workflows/build.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ jobs:
{{ checkout(repository="pulp/pulp-openapi-generator", path="pulp-openapi-generator") | indent(6) }}
{{ setup_python() | indent(6) }}
{{ install_python_deps(["packaging", "twine", "wheel", "mkdocs", "jq"]) | indent(6) }}
{%- if os_required_packages %}
- name: "Install OS packages"
run: |
sudo apt-get install -y {{ os_required_packages|join(' ') }}
{%- endif %}
- name: "Build package"
run: |
python3 setup.py sdist bdist_wheel --python-tag py3
Expand Down

0 comments on commit 6f2bebb

Please sign in to comment.