Skip to content
This repository has been archived by the owner on Feb 21, 2022. It is now read-only.

RedHatInsights/patchman-clients

Repository files navigation

This repo is no longer used in patchman-engine and will be removed!

patchman-clients

This repo stores automatically generated Go clients for Red Hat Insights projects:

These clients are primarily used in patchman-engine project.

Generate Go clients

This repo also contains script to generate current version of clients using containerized openapi-generator-cli tool.

To generate current version of clients run:

./generate-clients.sh # Use --docker or --podman to select specific container engine.

Note: be careful and don't delete {inventory,rbac,vmaas}/client_test.go files needed for build testing.

Note: Optionally use VMAAS_ADDRESS=http:https://vmaas.example:8080, INVENTORY_ADDRESS, RBAC_ADDRESS env vars to set places to download openapi.json spec to generate clients from.

Test compilation

You can test locally whether newly generated sources are valid and possible to build.

docker-compose -f docker-compose.test.yml up --build test