From 33d3a02ee5da3404433757ea8d2cbb0b71476177 Mon Sep 17 00:00:00 2001 From: schutzbot Date: Wed, 23 Jul 2025 08:40:00 +0000 Subject: [PATCH 001/123] Post release version bump [skip ci] --- cockpit/cockpit-image-builder.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cockpit/cockpit-image-builder.spec b/cockpit/cockpit-image-builder.spec index 23f7cfd0..ea02528e 100644 --- a/cockpit/cockpit-image-builder.spec +++ b/cockpit/cockpit-image-builder.spec @@ -1,5 +1,5 @@ Name: cockpit-image-builder -Version: 72 +Version: 73 Release: 1%{?dist} Summary: Image builder plugin for Cockpit From 8dd82d58016129a125a4ac906732cc30192a78b0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 23 Jul 2025 04:05:59 +0000 Subject: [PATCH 002/123] build(deps): bump @sentry/webpack-plugin from 3.6.1 to 4.0.0 Bumps [@sentry/webpack-plugin](https://github.com/getsentry/sentry-javascript-bundler-plugins) from 3.6.1 to 4.0.0. - [Release notes](https://github.com/getsentry/sentry-javascript-bundler-plugins/releases) - [Changelog](https://github.com/getsentry/sentry-javascript-bundler-plugins/blob/main/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-javascript-bundler-plugins/compare/3.6.1...4.0.0) --- updated-dependencies: - dependency-name: "@sentry/webpack-plugin" dependency-version: 4.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- package-lock.json | 186 +++++++++++++++++++++++----------------------- package.json | 2 +- 2 files changed, 94 insertions(+), 94 deletions(-) diff --git a/package-lock.json b/package-lock.json index 507742a4..723352d0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,7 +19,7 @@ "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", - "@sentry/webpack-plugin": "3.6.1", + "@sentry/webpack-plugin": "4.0.0", "@unleash/proxy-client-react": "5.0.0", "classnames": "2.5.1", "jwt-decode": "4.0.0", @@ -4753,9 +4753,9 @@ } }, "node_modules/@sentry/babel-plugin-component-annotate": { - "version": "3.6.1", - "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-3.6.1.tgz", - "integrity": "sha512-zmvUa4RpzDG3LQJFpGCE8lniz8Rk1Wa6ZvvK+yEH+snZeaHHRbSnAQBMR607GOClP+euGHNO2YtaY4UAdNTYbg==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.0.tgz", + "integrity": "sha512-1sozj4esnQBhJ2QO4imiLMl1858StkLjUxFF1KxgX/X1uEL/QlW2MYL8CKzbLeACy1SkR9h4V8GXSZvCnci5Dw==", "license": "MIT", "engines": { "node": ">= 14" @@ -4781,13 +4781,13 @@ } }, "node_modules/@sentry/bundler-plugin-core": { - "version": "3.6.1", - "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-3.6.1.tgz", - "integrity": "sha512-/ubWjPwgLep84sUPzHfKL2Ns9mK9aQrEX4aBFztru7ygiJidKJTxYGtvjh4dL2M1aZ0WRQYp+7PF6+VKwdZXcQ==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.0.tgz", + "integrity": "sha512-dTdbcctT5MJUwdbttZm2zomO+ui1F062ZIkogHeHqlA938Fwd1+9JIJ328+XL4XdcUG2yiFAZBWUPW3bYwoN9A==", "license": "MIT", "dependencies": { "@babel/core": "^7.18.5", - "@sentry/babel-plugin-component-annotate": "3.6.1", + "@sentry/babel-plugin-component-annotate": "4.0.0", "@sentry/cli": "^2.49.0", "dotenv": "^16.3.1", "find-up": "^5.0.0", @@ -4842,9 +4842,9 @@ } }, "node_modules/@sentry/cli": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-2.50.0.tgz", - "integrity": "sha512-OHRRQPUNjBpzOT6arNhxXQ71DKs5jSziCfDzmEGwAs+K8J/I1QxnvJkto88HbXE54oiWhSEJwL0pvcowFXyVbA==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-2.50.2.tgz", + "integrity": "sha512-m1L9shxutF3WHSyNld6Y1vMPoXfEyQhoRh1V3SYSdl+4AB40U+zr2sRzFa2OPm7XP4zYNaWuuuHLkY/iHITs8Q==", "hasInstallScript": true, "license": "BSD-3-Clause", "dependencies": { @@ -4861,20 +4861,20 @@ "node": ">= 10" }, "optionalDependencies": { - "@sentry/cli-darwin": "2.50.0", - "@sentry/cli-linux-arm": "2.50.0", - "@sentry/cli-linux-arm64": "2.50.0", - "@sentry/cli-linux-i686": "2.50.0", - "@sentry/cli-linux-x64": "2.50.0", - "@sentry/cli-win32-arm64": "2.50.0", - "@sentry/cli-win32-i686": "2.50.0", - "@sentry/cli-win32-x64": "2.50.0" + "@sentry/cli-darwin": "2.50.2", + "@sentry/cli-linux-arm": "2.50.2", + "@sentry/cli-linux-arm64": "2.50.2", + "@sentry/cli-linux-i686": "2.50.2", + "@sentry/cli-linux-x64": "2.50.2", + "@sentry/cli-win32-arm64": "2.50.2", + "@sentry/cli-win32-i686": "2.50.2", + "@sentry/cli-win32-x64": "2.50.2" } }, "node_modules/@sentry/cli-darwin": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-darwin/-/cli-darwin-2.50.0.tgz", - "integrity": "sha512-Aj+cLBZ0dCw+pdUxvJ1U71PnKh2YjvpzLN9h1ZTe8UI3FqmkKkSH/J8mN/5qmR7qUHjDcm2l+wfgVUaaP8CWbA==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-darwin/-/cli-darwin-2.50.2.tgz", + "integrity": "sha512-0Pjpl0vQqKhwuZm19z6AlEF+ds3fJg1KWabv8WzGaSc/fwxMEwjFwOZj+IxWBJPV578cXXNvB39vYjjpCH8j7A==", "license": "BSD-3-Clause", "optional": true, "os": [ @@ -4885,9 +4885,9 @@ } }, "node_modules/@sentry/cli-linux-arm": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm/-/cli-linux-arm-2.50.0.tgz", - "integrity": "sha512-SGPAFwOY2of2C+RUBJcxMN2JXikVFEk8ypYOsQTEvV/48cLejcO/O2mHIj/YKgIkrfn3t7LlqdK6g75lkz+F8Q==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm/-/cli-linux-arm-2.50.2.tgz", + "integrity": "sha512-jzFwg9AeeuFAFtoCcyaDEPG05TU02uOy1nAX09c1g7FtsyQlPcbhI94JQGmnPzdRjjDmORtwIUiVZQrVTkDM7w==", "cpu": [ "arm" ], @@ -4903,9 +4903,9 @@ } }, "node_modules/@sentry/cli-linux-arm64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm64/-/cli-linux-arm64-2.50.0.tgz", - "integrity": "sha512-p6hIh4Bb87qBfEz9w5dxEPAohIKcw68qoy5VUTx+cCanO8uXNWWsT78xtUNFRscW9zc6MxQMSITTWaCEIKvxRA==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm64/-/cli-linux-arm64-2.50.2.tgz", + "integrity": "sha512-03Cj215M3IdoHAwevCxm5oOm9WICFpuLR05DQnODFCeIUsGvE1pZsc+Gm0Ky/ZArq2PlShBJTpbHvXbCUka+0w==", "cpu": [ "arm64" ], @@ -4921,9 +4921,9 @@ } }, "node_modules/@sentry/cli-linux-i686": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-i686/-/cli-linux-i686-2.50.0.tgz", - "integrity": "sha512-umhGmbiCUG7MvjTm8lXFmFxQjyTVtYakilBwPTVzRELmNKxxhfKRxwSSA+hUKetAUzNd8fJx8K7yqdw+qRA7Pg==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-i686/-/cli-linux-i686-2.50.2.tgz", + "integrity": "sha512-J+POvB34uVyHbIYF++Bc/OCLw+gqKW0H/y/mY7rRZCiocgpk266M4NtsOBl6bEaurMx1D+BCIEjr4nc01I/rqA==", "cpu": [ "x86", "ia32" @@ -4940,9 +4940,9 @@ } }, "node_modules/@sentry/cli-linux-x64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-x64/-/cli-linux-x64-2.50.0.tgz", - "integrity": "sha512-ugIIx9+wUmguxOUe9ZVacvdCffZwqtFSKwpJ06Nqes0XfL4ZER4Qlq3/miCZ8m150C4xK5ym/QCwB41ffBqI4g==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-x64/-/cli-linux-x64-2.50.2.tgz", + "integrity": "sha512-81yQVRLj8rnuHoYcrM7QbOw8ubA3weiMdPtTxTim1s6WExmPgnPTKxLCr9xzxGJxFdYo3xIOhtf5JFpUX/3j4A==", "cpu": [ "x64" ], @@ -4958,9 +4958,9 @@ } }, "node_modules/@sentry/cli-win32-arm64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-arm64/-/cli-win32-arm64-2.50.0.tgz", - "integrity": "sha512-fMyBSKLrVHY9944t8oTpul+6osyQeuN8GGGP3diDxGQpynYL+vhcHZIpXFRH398+3kedG/IFoY7EwGgIEqWzmw==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-arm64/-/cli-win32-arm64-2.50.2.tgz", + "integrity": "sha512-QjentLGvpibgiZlmlV9ifZyxV73lnGH6pFZWU5wLeRiaYKxWtNrrHpVs+HiWlRhkwQ0mG1/S40PGNgJ20DJ3gA==", "cpu": [ "arm64" ], @@ -4974,9 +4974,9 @@ } }, "node_modules/@sentry/cli-win32-i686": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-i686/-/cli-win32-i686-2.50.0.tgz", - "integrity": "sha512-VbC+l2Y2kB7Lsun2c8t7ZGwmljmXnyncZLW9PjdEyJSTAJ9GnEnSvyFSPXNLV/eHJnfQffzU7QTjU8vkQ7XMYg==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-i686/-/cli-win32-i686-2.50.2.tgz", + "integrity": "sha512-UkBIIzkQkQ1UkjQX8kHm/+e7IxnEhK6CdgSjFyNlxkwALjDWHJjMztevqAPz3kv4LdM6q1MxpQ/mOqXICNhEGg==", "cpu": [ "x86", "ia32" @@ -4991,9 +4991,9 @@ } }, "node_modules/@sentry/cli-win32-x64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-x64/-/cli-win32-x64-2.50.0.tgz", - "integrity": "sha512-nMktyF93NtQUOViAAKHpHSWACOGjOkKjiewi4pD6W3sWllFiPPyt15XoyApqWwnICDRQu2DI5vnil4ck6/k7mw==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-x64/-/cli-win32-x64-2.50.2.tgz", + "integrity": "sha512-tE27pu1sRRub1Jpmemykv3QHddBcyUk39Fsvv+n4NDpQyMgsyVPcboxBZyby44F0jkpI/q3bUH2tfCB1TYDNLg==", "cpu": [ "x64" ], @@ -5071,12 +5071,12 @@ } }, "node_modules/@sentry/webpack-plugin": { - "version": "3.6.1", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-3.6.1.tgz", - "integrity": "sha512-F2yqwbdxfCENMN5u4ih4WfOtGjW56/92DBC0bU6un7Ns/l2qd+wRONIvrF+58rl/VkCFfMlUtZTVoKGRyMRmHA==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.0.tgz", + "integrity": "sha512-Uhfjqnuxv4eYIt0GbPAdlFPum3BtasNhQrO3OJuVQRYRq21En7ARKXISoOhZHMo4tRRiiv+3npKYmpzHTALbQg==", "license": "MIT", "dependencies": { - "@sentry/bundler-plugin-core": "3.6.1", + "@sentry/bundler-plugin-core": "4.0.0", "unplugin": "1.0.1", "uuid": "^9.0.0" }, @@ -22928,9 +22928,9 @@ } }, "@sentry/babel-plugin-component-annotate": { - "version": "3.6.1", - "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-3.6.1.tgz", - "integrity": "sha512-zmvUa4RpzDG3LQJFpGCE8lniz8Rk1Wa6ZvvK+yEH+snZeaHHRbSnAQBMR607GOClP+euGHNO2YtaY4UAdNTYbg==" + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.0.tgz", + "integrity": "sha512-1sozj4esnQBhJ2QO4imiLMl1858StkLjUxFF1KxgX/X1uEL/QlW2MYL8CKzbLeACy1SkR9h4V8GXSZvCnci5Dw==" }, "@sentry/browser": { "version": "7.120.3", @@ -22948,12 +22948,12 @@ } }, "@sentry/bundler-plugin-core": { - "version": "3.6.1", - "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-3.6.1.tgz", - "integrity": "sha512-/ubWjPwgLep84sUPzHfKL2Ns9mK9aQrEX4aBFztru7ygiJidKJTxYGtvjh4dL2M1aZ0WRQYp+7PF6+VKwdZXcQ==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.0.tgz", + "integrity": "sha512-dTdbcctT5MJUwdbttZm2zomO+ui1F062ZIkogHeHqlA938Fwd1+9JIJ328+XL4XdcUG2yiFAZBWUPW3bYwoN9A==", "requires": { "@babel/core": "^7.18.5", - "@sentry/babel-plugin-component-annotate": "3.6.1", + "@sentry/babel-plugin-component-annotate": "4.0.0", "@sentry/cli": "^2.49.0", "dotenv": "^16.3.1", "find-up": "^5.0.0", @@ -22989,18 +22989,18 @@ } }, "@sentry/cli": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-2.50.0.tgz", - "integrity": "sha512-OHRRQPUNjBpzOT6arNhxXQ71DKs5jSziCfDzmEGwAs+K8J/I1QxnvJkto88HbXE54oiWhSEJwL0pvcowFXyVbA==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-2.50.2.tgz", + "integrity": "sha512-m1L9shxutF3WHSyNld6Y1vMPoXfEyQhoRh1V3SYSdl+4AB40U+zr2sRzFa2OPm7XP4zYNaWuuuHLkY/iHITs8Q==", "requires": { - "@sentry/cli-darwin": "2.50.0", - "@sentry/cli-linux-arm": "2.50.0", - "@sentry/cli-linux-arm64": "2.50.0", - "@sentry/cli-linux-i686": "2.50.0", - "@sentry/cli-linux-x64": "2.50.0", - "@sentry/cli-win32-arm64": "2.50.0", - "@sentry/cli-win32-i686": "2.50.0", - "@sentry/cli-win32-x64": "2.50.0", + "@sentry/cli-darwin": "2.50.2", + "@sentry/cli-linux-arm": "2.50.2", + "@sentry/cli-linux-arm64": "2.50.2", + "@sentry/cli-linux-i686": "2.50.2", + "@sentry/cli-linux-x64": "2.50.2", + "@sentry/cli-win32-arm64": "2.50.2", + "@sentry/cli-win32-i686": "2.50.2", + "@sentry/cli-win32-x64": "2.50.2", "https-proxy-agent": "^5.0.0", "node-fetch": "^2.6.7", "progress": "^2.0.3", @@ -23009,51 +23009,51 @@ } }, "@sentry/cli-darwin": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-darwin/-/cli-darwin-2.50.0.tgz", - "integrity": "sha512-Aj+cLBZ0dCw+pdUxvJ1U71PnKh2YjvpzLN9h1ZTe8UI3FqmkKkSH/J8mN/5qmR7qUHjDcm2l+wfgVUaaP8CWbA==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-darwin/-/cli-darwin-2.50.2.tgz", + "integrity": "sha512-0Pjpl0vQqKhwuZm19z6AlEF+ds3fJg1KWabv8WzGaSc/fwxMEwjFwOZj+IxWBJPV578cXXNvB39vYjjpCH8j7A==", "optional": true }, "@sentry/cli-linux-arm": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm/-/cli-linux-arm-2.50.0.tgz", - "integrity": "sha512-SGPAFwOY2of2C+RUBJcxMN2JXikVFEk8ypYOsQTEvV/48cLejcO/O2mHIj/YKgIkrfn3t7LlqdK6g75lkz+F8Q==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm/-/cli-linux-arm-2.50.2.tgz", + "integrity": "sha512-jzFwg9AeeuFAFtoCcyaDEPG05TU02uOy1nAX09c1g7FtsyQlPcbhI94JQGmnPzdRjjDmORtwIUiVZQrVTkDM7w==", "optional": true }, "@sentry/cli-linux-arm64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm64/-/cli-linux-arm64-2.50.0.tgz", - "integrity": "sha512-p6hIh4Bb87qBfEz9w5dxEPAohIKcw68qoy5VUTx+cCanO8uXNWWsT78xtUNFRscW9zc6MxQMSITTWaCEIKvxRA==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-arm64/-/cli-linux-arm64-2.50.2.tgz", + "integrity": "sha512-03Cj215M3IdoHAwevCxm5oOm9WICFpuLR05DQnODFCeIUsGvE1pZsc+Gm0Ky/ZArq2PlShBJTpbHvXbCUka+0w==", "optional": true }, "@sentry/cli-linux-i686": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-i686/-/cli-linux-i686-2.50.0.tgz", - "integrity": "sha512-umhGmbiCUG7MvjTm8lXFmFxQjyTVtYakilBwPTVzRELmNKxxhfKRxwSSA+hUKetAUzNd8fJx8K7yqdw+qRA7Pg==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-i686/-/cli-linux-i686-2.50.2.tgz", + "integrity": "sha512-J+POvB34uVyHbIYF++Bc/OCLw+gqKW0H/y/mY7rRZCiocgpk266M4NtsOBl6bEaurMx1D+BCIEjr4nc01I/rqA==", "optional": true }, "@sentry/cli-linux-x64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-linux-x64/-/cli-linux-x64-2.50.0.tgz", - "integrity": "sha512-ugIIx9+wUmguxOUe9ZVacvdCffZwqtFSKwpJ06Nqes0XfL4ZER4Qlq3/miCZ8m150C4xK5ym/QCwB41ffBqI4g==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-linux-x64/-/cli-linux-x64-2.50.2.tgz", + "integrity": "sha512-81yQVRLj8rnuHoYcrM7QbOw8ubA3weiMdPtTxTim1s6WExmPgnPTKxLCr9xzxGJxFdYo3xIOhtf5JFpUX/3j4A==", "optional": true }, "@sentry/cli-win32-arm64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-arm64/-/cli-win32-arm64-2.50.0.tgz", - "integrity": "sha512-fMyBSKLrVHY9944t8oTpul+6osyQeuN8GGGP3diDxGQpynYL+vhcHZIpXFRH398+3kedG/IFoY7EwGgIEqWzmw==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-arm64/-/cli-win32-arm64-2.50.2.tgz", + "integrity": "sha512-QjentLGvpibgiZlmlV9ifZyxV73lnGH6pFZWU5wLeRiaYKxWtNrrHpVs+HiWlRhkwQ0mG1/S40PGNgJ20DJ3gA==", "optional": true }, "@sentry/cli-win32-i686": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-i686/-/cli-win32-i686-2.50.0.tgz", - "integrity": "sha512-VbC+l2Y2kB7Lsun2c8t7ZGwmljmXnyncZLW9PjdEyJSTAJ9GnEnSvyFSPXNLV/eHJnfQffzU7QTjU8vkQ7XMYg==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-i686/-/cli-win32-i686-2.50.2.tgz", + "integrity": "sha512-UkBIIzkQkQ1UkjQX8kHm/+e7IxnEhK6CdgSjFyNlxkwALjDWHJjMztevqAPz3kv4LdM6q1MxpQ/mOqXICNhEGg==", "optional": true }, "@sentry/cli-win32-x64": { - "version": "2.50.0", - "resolved": "https://registry.npmjs.org/@sentry/cli-win32-x64/-/cli-win32-x64-2.50.0.tgz", - "integrity": "sha512-nMktyF93NtQUOViAAKHpHSWACOGjOkKjiewi4pD6W3sWllFiPPyt15XoyApqWwnICDRQu2DI5vnil4ck6/k7mw==", + "version": "2.50.2", + "resolved": "https://registry.npmjs.org/@sentry/cli-win32-x64/-/cli-win32-x64-2.50.2.tgz", + "integrity": "sha512-tE27pu1sRRub1Jpmemykv3QHddBcyUk39Fsvv+n4NDpQyMgsyVPcboxBZyby44F0jkpI/q3bUH2tfCB1TYDNLg==", "optional": true }, "@sentry/core": { @@ -23101,11 +23101,11 @@ } }, "@sentry/webpack-plugin": { - "version": "3.6.1", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-3.6.1.tgz", - "integrity": "sha512-F2yqwbdxfCENMN5u4ih4WfOtGjW56/92DBC0bU6un7Ns/l2qd+wRONIvrF+58rl/VkCFfMlUtZTVoKGRyMRmHA==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.0.tgz", + "integrity": "sha512-Uhfjqnuxv4eYIt0GbPAdlFPum3BtasNhQrO3OJuVQRYRq21En7ARKXISoOhZHMo4tRRiiv+3npKYmpzHTALbQg==", "requires": { - "@sentry/bundler-plugin-core": "3.6.1", + "@sentry/bundler-plugin-core": "4.0.0", "unplugin": "1.0.1", "uuid": "^9.0.0" }, diff --git a/package.json b/package.json index 57758b8e..65d3cbea 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,7 @@ "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", - "@sentry/webpack-plugin": "3.6.1", + "@sentry/webpack-plugin": "4.0.0", "@unleash/proxy-client-react": "5.0.0", "classnames": "2.5.1", "jwt-decode": "4.0.0", From 253317497e86c1b68d72c53be1e8ab06f800cdee Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli Date: Mon, 31 Mar 2025 17:00:12 +0000 Subject: [PATCH 003/123] CreateImageWizard: hide aws sources for on-prem For now just allow manual entry of the aws account id, since we aren't able to configure sources on-premise yet (if ever). --- .../CreateImageWizard/CreateImageWizard.tsx | 5 ++++ .../steps/TargetEnvironment/Aws/index.tsx | 29 ++++++++++--------- 2 files changed, 21 insertions(+), 13 deletions(-) diff --git a/src/Components/CreateImageWizard/CreateImageWizard.tsx b/src/Components/CreateImageWizard/CreateImageWizard.tsx index 7a86b14e..bcaa79e6 100644 --- a/src/Components/CreateImageWizard/CreateImageWizard.tsx +++ b/src/Components/CreateImageWizard/CreateImageWizard.tsx @@ -74,6 +74,7 @@ import './CreateImageWizard.scss'; import { addImageType, changeArchitecture, + changeAwsShareMethod, changeDistribution, initializeWizard, selectAwsAccountId, @@ -235,6 +236,10 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { dispatch(changeArchitecture(arch)); }; + if (process.env.IS_ON_PREMISE) { + dispatch(changeAwsShareMethod('manual')); + } + if (process.env.IS_ON_PREMISE && !isEdit) { if (!searchParams.get('release')) { initializeHostDistro(); diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx index a5c7d6ef..8de40831 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx @@ -68,19 +68,21 @@ const Aws = () => { by Red Hat, to your own AWS account. - { - dispatch(changeAwsSourceId(undefined)); - dispatch(changeAwsAccountId('')); - dispatch(changeAwsShareMethod('sources')); - }} - autoFocus - /> + {!process.env.IS_ON_PREMISE && ( + { + dispatch(changeAwsSourceId(undefined)); + dispatch(changeAwsAccountId('')); + dispatch(changeAwsShareMethod('sources')); + }} + autoFocus + /> + )} { dispatch(changeAwsAccountId('')); dispatch(changeAwsShareMethod('manual')); }} + autoFocus={!!process.env.IS_ON_PREMISE} /> {shareMethod === 'sources' && ( From 2ce62d4ef0c22310fb2cfcc83f4bd0b3cfe42d61 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli Date: Mon, 31 Mar 2025 17:01:37 +0000 Subject: [PATCH 004/123] store/cockpitApi: enable aws image types --- .../components/TargetEnvironment.tsx | 10 ++- src/store/cockpit/cockpitApi.ts | 74 ++++++++++++------- 2 files changed, 54 insertions(+), 30 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx index fd4093ff..e6b121dc 100644 --- a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx +++ b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx @@ -69,9 +69,13 @@ const TargetEnvironmentCard = ({ }} > - - {imageAlt} - + {!process.env.IS_ON_PREMISE && ( + // the logos don't display in cockpit, + // so we can just hide them + + {imageAlt} + + )} {title} diff --git a/src/store/cockpit/cockpitApi.ts b/src/store/cockpit/cockpitApi.ts index 6caee6af..68fdf69e 100644 --- a/src/store/cockpit/cockpitApi.ts +++ b/src/store/cockpit/cockpitApi.ts @@ -124,6 +124,19 @@ const readComposes = async (bpID: string) => { return composes; }; +const getCloudConfigs = async () => { + try { + const worker_config = cockpit.file( + '/etc/osbuild-worker/osbuild-worker.toml' + ); + const contents = await worker_config.read(); + const parsed = TOML.parse(contents); + return Object.keys(parsed).filter((k) => k === 'aws'); + } catch { + return []; + } +}; + export const cockpitApi = contentSourcesApi.injectEndpoints({ endpoints: (builder) => { return { @@ -131,33 +144,40 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ GetArchitecturesApiResponse, GetArchitecturesApiArg >({ - queryFn: () => { - // TODO: this is hardcoded for now, but we may need to query - // the cloudapi endpoint on the composer socket to get the - // available information - return { - data: [ - { - arch: 'aarch64', - image_types: ['guest-image', 'image-installer'], - repositories: [], - }, - { - arch: 'x86_64', - image_types: [ - 'rhel-edge-commit', - 'rhel-edge-installer', - 'edge-commit', - 'edge-installer', - 'guest-image', - 'image-installer', - 'vsphere', - 'vsphere-ova', - ], - repositories: [], - }, - ], - }; + queryFn: async () => { + try { + const cloudImageTypes = await getCloudConfigs(); + return { + data: [ + { + arch: 'aarch64', + image_types: [ + 'guest-image', + 'image-installer', + ...cloudImageTypes, + ], + repositories: [], + }, + { + arch: 'x86_64', + image_types: [ + 'rhel-edge-commit', + 'rhel-edge-installer', + 'edge-commit', + 'edge-installer', + 'guest-image', + 'image-installer', + 'vsphere', + 'vsphere-ova', + ...cloudImageTypes, + ], + repositories: [], + }, + ], + }; + } catch (error) { + return { error }; + } }, }), getBlueprint: builder.query<GetBlueprintApiResponse, GetBlueprintApiArg>({ From 2f765a1d4b6a94776fb7b1b3ca551ed344a57069 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 1 Jul 2025 16:03:13 +0100 Subject: [PATCH 005/123] multi: fix analytics for on-prem This commit fixes some more analytics calls happening in the on-prem frontend. --- .../Blueprints/BuildImagesButton.tsx | 12 ++++--- src/Components/ImagesTable/ImageDetails.tsx | 36 ++++++++++--------- src/store/wizardSlice.ts | 11 ++++++ 3 files changed, 38 insertions(+), 21 deletions(-) diff --git a/src/Components/Blueprints/BuildImagesButton.tsx b/src/Components/Blueprints/BuildImagesButton.tsx index 5d505704..9bc3d7ba 100644 --- a/src/Components/Blueprints/BuildImagesButton.tsx +++ b/src/Components/Blueprints/BuildImagesButton.tsx @@ -57,11 +57,13 @@ export const BuildImagesButton = ({ children }: BuildImagesButtonPropTypes) => { ), }, }); - analytics.track(`${AMPLITUDE_MODULE_NAME} - Image Requested`, { - module: AMPLITUDE_MODULE_NAME, - trigger: 'synchronize images', - account_id: userData?.identity.internal?.account_id || 'Not found', - }); + if (!process.env.IS_ON_PREMISE) { + analytics.track(`${AMPLITUDE_MODULE_NAME} - Image Requested`, { + module: AMPLITUDE_MODULE_NAME, + trigger: 'synchronize images', + account_id: userData?.identity.internal?.account_id || 'Not found', + }); + } } }; const [isOpen, setIsOpen] = useState(false); diff --git a/src/Components/ImagesTable/ImageDetails.tsx b/src/Components/ImagesTable/ImageDetails.tsx index 45cca690..9e830c22 100644 --- a/src/Components/ImagesTable/ImageDetails.tsx +++ b/src/Components/ImagesTable/ImageDetails.tsx @@ -163,13 +163,15 @@ export const AwsDetails = ({ compose }: AwsDetailsPropTypes) => { clickTip="Copied" variant="inline-compact" onClick={() => { - analytics.track(`${AMPLITUDE_MODULE_NAME} - Copy UUID`, { - module: AMPLITUDE_MODULE_NAME, - link_name: compose.id, - current_path: window.location.pathname, - account_id: - userData?.identity.internal?.account_id || 'Not found', - }); + if (!process.env.IS_ON_PREMISE) { + analytics.track(`${AMPLITUDE_MODULE_NAME} - Copy UUID`, { + module: AMPLITUDE_MODULE_NAME, + link_name: compose.id, + current_path: window.location.pathname, + account_id: + userData?.identity.internal?.account_id || 'Not found', + }); + } }} > {compose.id} @@ -203,16 +205,18 @@ export const AwsDetails = ({ compose }: AwsDetailsPropTypes) => { // https://docs.aws.amazon.com/signin/latest/userguide/sign-in-urls-defined.html href={`https://${options.share_with_accounts[0]}.signin.aws.amazon.com/console/`} onClick={() => { - analytics.track(`${AMPLITUDE_MODULE_NAME} - Link Clicked`, { - module: AMPLITUDE_MODULE_NAME, + if (!process.env.IS_ON_PREMISE) { + analytics.track(`${AMPLITUDE_MODULE_NAME} - Link Clicked`, { + module: AMPLITUDE_MODULE_NAME, - link_name: options.share_with_accounts - ? options.share_with_accounts[0] - : '', - current_path: window.location.pathname, - account_id: - userData?.identity.internal?.account_id || 'Not found', - }); + link_name: options.share_with_accounts + ? options.share_with_accounts[0] + : '', + current_path: window.location.pathname, + account_id: + userData?.identity.internal?.account_id || 'Not found', + }); + } }} > {options.share_with_accounts[0]} diff --git a/src/store/wizardSlice.ts b/src/store/wizardSlice.ts index ada5f2c6..9f1b7733 100644 --- a/src/store/wizardSlice.ts +++ b/src/store/wizardSlice.ts @@ -94,6 +94,7 @@ export type wizardState = { shareMethod: AwsShareMethod; source: V1ListSourceResponseItem | undefined; sourceId?: string | undefined; + region?: string | undefined; }; azure: { shareMethod: AzureShareMethod; @@ -189,6 +190,7 @@ export const initialState: wizardState = { accountId: '', shareMethod: 'sources', source: undefined, + region: 'us-east-1', }, azure: { shareMethod: 'sources', @@ -312,6 +314,10 @@ export const selectAwsShareMethod = (state: RootState) => { return state.wizard.aws.shareMethod; }; +export const selectAwsRegion = (state: RootState) => { + return state.wizard.aws.region; +}; + export const selectAzureTenantId = (state: RootState) => { return state.wizard.azure.tenantId; }; @@ -534,10 +540,14 @@ export const wizardSlice = createSlice({ changeAwsSourceId: (state, action: PayloadAction<string | undefined>) => { state.aws.sourceId = action.payload; }, + changeAwsRegion: (state, action: PayloadAction<string | undefined>) => { + state.aws.region = action.payload; + }, reinitializeAws: (state) => { state.aws.accountId = ''; state.aws.shareMethod = 'sources'; state.aws.source = undefined; + state.aws.region = 'us-east-1'; }, changeAzureTenantId: (state, action: PayloadAction<string>) => { state.azure.tenantId = action.payload; @@ -1136,6 +1146,7 @@ export const { changeAwsAccountId, changeAwsShareMethod, changeAwsSourceId, + changeAwsRegion, reinitializeAws, changeAzureTenantId, changeAzureShareMethod, From c88171da19acfa8ee654f9ac09063262d777c44c Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 1 Jul 2025 16:07:45 +0100 Subject: [PATCH 006/123] cockpit: add cockpit image request types Update the types to include some cockpit specific fields to the image requests. We could also update the image-builder-crc api openapi specs, but this would need further discussion --- src/store/cockpit/types.ts | 57 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/src/store/cockpit/types.ts b/src/store/cockpit/types.ts index 3614390b..3f942ce6 100644 --- a/src/store/cockpit/types.ts +++ b/src/store/cockpit/types.ts @@ -1,3 +1,15 @@ +import { + Awss3UploadRequestOptions, + AwsUploadRequestOptions, + ComposeRequest, + ComposesResponseItem, + CreateBlueprintApiArg, + CreateBlueprintRequest, + ImageRequest, + UpdateBlueprintApiArg, + UploadTypes, +} from '../imageBuilderApi'; + // eslint-disable-next-line @typescript-eslint/no-explicit-any export type Params = Record<string, any>; export type Method = 'GET' | 'DELETE' | 'POST' | 'PUT' | 'PATCH'; // We can add more if we need @@ -47,3 +59,48 @@ export type WorkerConfigRequest = { export type UpdateWorkerConfigApiArg = { updateWorkerConfigRequest: WorkerConfigRequest | undefined; }; + +export type CockpitUploadTypes = UploadTypes | 'local'; + +export type CockpitAwsUploadRequestOptions = AwsUploadRequestOptions & { + region?: string | undefined; +}; + +type CockpitUploadRequest = { + type: CockpitUploadTypes; + options: Awss3UploadRequestOptions | CockpitAwsUploadRequestOptions; +}; + +export type CockpitImageRequest = Omit<ImageRequest, 'upload_request'> & { + upload_request: CockpitUploadRequest; +}; + +export type CockpitCreateBlueprintRequest = Omit< + CreateBlueprintRequest, + 'image_requests' +> & { + image_requests: CockpitImageRequest[]; +}; + +export type CockpitCreateBlueprintApiArg = Omit< + CreateBlueprintApiArg, + 'createBlueprintRequest' +> & { + createBlueprintRequest: CockpitCreateBlueprintRequest; +}; + +export type CockpitUpdateBlueprintApiArg = Omit< + UpdateBlueprintApiArg, + 'createBlueprintRequest' +> & { + createBlueprintRequest: CockpitCreateBlueprintRequest; +}; + +export type CockpitComposesResponseItem = Omit< + ComposesResponseItem, + 'request' +> & { + request: Omit<ComposeRequest, 'image_requests'> & { + image_requests: CockpitImageRequest[]; + }; +}; From fe5abaeb45b6f41f3f4662cbf4cbc4fee3a0e324 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 1 Jul 2025 16:18:42 +0100 Subject: [PATCH 007/123] Table: fix the image table status for on prem aws uploads We need to make some minor tweaks to get this to show properly for the on-prem frontend. --- src/Components/ImagesTable/ClonesTable.tsx | 24 ++++++++++++++++----- src/Components/ImagesTable/Status.tsx | 3 ++- src/Components/ImagesTable/Target.tsx | 25 +++++++++++++--------- 3 files changed, 36 insertions(+), 16 deletions(-) diff --git a/src/Components/ImagesTable/ClonesTable.tsx b/src/Components/ImagesTable/ClonesTable.tsx index 436e1459..165b39cc 100644 --- a/src/Components/ImagesTable/ClonesTable.tsx +++ b/src/Components/ImagesTable/ClonesTable.tsx @@ -5,13 +5,17 @@ import { Table, Tbody, Td, Th, Thead, Tr } from '@patternfly/react-table'; import { AwsDetailsStatus, StatusClone } from './Status'; +import { useGetComposeStatusQuery } from '../../store/backendApi'; +import { + CockpitAwsUploadRequestOptions, + CockpitComposesResponseItem, +} from '../../store/cockpit/types'; import { ClonesResponseItem, ComposesResponseItem, UploadStatus, useGetCloneStatusQuery, useGetComposeClonesQuery, - useGetComposeStatusQuery, } from '../../store/imageBuilderApi'; type RowPropTypes = { @@ -42,8 +46,8 @@ const Ami = ({ status }: AmiPropTypes) => { } }; -const ComposeRegion = () => { - return <p>us-east-1</p>; +const ComposeRegion = ({ region }: { region?: string | undefined }) => { + return <p>{region || 'us-east-1'}</p>; }; type CloneRegionPropTypes = { @@ -98,17 +102,27 @@ const CloneRow = ({ clone }: CloneRowPropTypes) => { }; type ComposeRowPropTypes = { - compose: ComposesResponseItem; + compose: ComposesResponseItem | CockpitComposesResponseItem; }; const ComposeRow = ({ compose }: ComposeRowPropTypes) => { const { data, isSuccess } = useGetComposeStatusQuery({ composeId: compose.id, }); + + const region = !process.env.IS_ON_PREMISE + ? 'us-east-1' + : // since this is on-premise, we know the type casting + // is okay to do here. + ( + compose.request.image_requests[0].upload_request + .options as CockpitAwsUploadRequestOptions + ).region; + return isSuccess ? ( <Row ami={<Ami status={data?.image_status.upload_status} />} - region={<ComposeRegion />} + region={<ComposeRegion region={region} />} status={<AwsDetailsStatus compose={compose} />} /> ) : null; diff --git a/src/Components/ImagesTable/Status.tsx b/src/Components/ImagesTable/Status.tsx index 80f1bdf6..7d0dba19 100644 --- a/src/Components/ImagesTable/Status.tsx +++ b/src/Components/ImagesTable/Status.tsx @@ -32,6 +32,7 @@ import { OCI_STORAGE_EXPIRATION_TIME_IN_DAYS, } from '../../constants'; import { useGetComposeStatusQuery } from '../../store/backendApi'; +import { CockpitComposesResponseItem } from '../../store/cockpit/types'; import { ClonesResponseItem, ComposesResponseItem, @@ -70,7 +71,7 @@ export const StatusClone = ({ clone, status }: StatusClonePropTypes) => { }; type ComposeStatusPropTypes = { - compose: ComposesResponseItem; + compose: ComposesResponseItem | CockpitComposesResponseItem; }; export const AwsDetailsStatus = ({ compose }: ComposeStatusPropTypes) => { diff --git a/src/Components/ImagesTable/Target.tsx b/src/Components/ImagesTable/Target.tsx index 9d6c50de..33a7dea5 100644 --- a/src/Components/ImagesTable/Target.tsx +++ b/src/Components/ImagesTable/Target.tsx @@ -17,15 +17,20 @@ type AwsTargetPropTypes = { compose: ComposesResponseItem; }; -export const AwsTarget = ({ compose }: AwsTargetPropTypes) => { - const { data, isSuccess } = useGetComposeClonesQuery({ - composeId: compose.id, - }); +export const AwsTarget = process.env.IS_ON_PREMISE + ? // we don't need to clone composes for on-prem + // since we can upload directly to the desired + // region + () => <>{targetOptions.aws}</> + : ({ compose }: AwsTargetPropTypes) => { + const { data, isSuccess } = useGetComposeClonesQuery({ + composeId: compose.id, + }); - if (!isSuccess) { - return <Skeleton />; - } + if (!isSuccess) { + return <Skeleton />; + } - const text = `${targetOptions.aws} (${(data?.data.length ?? 0) + 1})`; - return <>{text}</>; -}; + const text = `${targetOptions.aws} (${(data?.data.length ?? 0) + 1})`; + return <>{text}</>; + }; From 4339420cb83c80a2e4e47c8d174a59d3073c8449 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 1 Jul 2025 16:19:09 +0100 Subject: [PATCH 008/123] Wizard: add region selector for on-prem AWS We need to be able to select the region for AWS targets in the frontend image builder. This commit adds the field to the wizard, but doesn't wire this up to the api call just yet. --- .../CreateImageWizard/CreateImageWizard.tsx | 10 +- .../steps/Review/ReviewStepTextLists.tsx | 6 +- .../steps/TargetEnvironment/Aws/index.tsx | 170 ++++++++++++------ 3 files changed, 132 insertions(+), 54 deletions(-) diff --git a/src/Components/CreateImageWizard/CreateImageWizard.tsx b/src/Components/CreateImageWizard/CreateImageWizard.tsx index bcaa79e6..2999d1a5 100644 --- a/src/Components/CreateImageWizard/CreateImageWizard.tsx +++ b/src/Components/CreateImageWizard/CreateImageWizard.tsx @@ -404,9 +404,13 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { footer={ <CustomWizardFooter disableNext={ - awsShareMethod === 'manual' - ? !isAwsAccountIdValid(awsAccountId) - : awsSourceId === undefined + // we don't need the account id for + // on-prem aws. + process.env.IS_ON_PREMISE + ? false + : awsShareMethod === 'manual' + ? !isAwsAccountIdValid(awsAccountId) + : awsSourceId === undefined } /> } diff --git a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx index 6a539ac3..03fc4b01 100644 --- a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx +++ b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx @@ -44,6 +44,7 @@ import { selectActivationKey, selectArchitecture, selectAwsAccountId, + selectAwsRegion, selectAwsShareMethod, selectAwsSourceId, selectAzureResourceGroup, @@ -225,6 +226,7 @@ export const TargetEnvAWSList = () => { const awsAccountId = useAppSelector(selectAwsAccountId); const awsShareMethod = useAppSelector(selectAwsShareMethod); const sourceId = useAppSelector(selectAwsSourceId); + const region = useAppSelector(selectAwsRegion); const { source } = useGetSourceListQuery( { provider: 'aws', @@ -261,7 +263,9 @@ export const TargetEnvAWSList = () => { <Content component={ContentVariants.dt} className="pf-v6-u-min-width"> Default region </Content> - <Content component={ContentVariants.dd}>us-east-1</Content> + <Content component={ContentVariants.dd}> + {region || 'us-east-1'} + </Content> </Content> </Content> ); diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx index 8de40831..bcbaffc9 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx @@ -1,4 +1,4 @@ -import React from 'react'; +import React, { useState } from 'react'; import { Button, @@ -9,7 +9,11 @@ import { GalleryItem, HelperText, HelperTextItem, + MenuToggle, + MenuToggleElement, Radio, + Select, + SelectOption, TextInput, Title, } from '@patternfly/react-core'; @@ -18,12 +22,15 @@ import { ExternalLinkAltIcon } from '@patternfly/react-icons'; import { AwsAccountId } from './AwsAccountId'; import { AwsSourcesSelect } from './AwsSourcesSelect'; +import { AWS_REGIONS } from '../../../../../constants'; import { useAppDispatch, useAppSelector } from '../../../../../store/hooks'; import { changeAwsAccountId, + changeAwsRegion, changeAwsShareMethod, changeAwsSourceId, selectAwsAccountId, + selectAwsRegion, selectAwsShareMethod, } from '../../../../../store/wizardSlice'; import { ValidatedInput } from '../../../ValidatedInput'; @@ -47,11 +54,60 @@ const SourcesButton = () => { ); }; +type FormGroupProps<T> = { + value: string; + onChange: (value: T) => void; +}; + +const AWSRegion = ({ value, onChange }: FormGroupProps<string>) => { + const [isOpen, setIsOpen] = useState(false); + + const onSelect = ( + _event: React.MouseEvent<Element, MouseEvent> | undefined, + value: string | number | undefined, + ) => { + onChange(value as string); + setIsOpen(false); + }; + + const toggle = (toggleRef: React.Ref<MenuToggleElement>) => ( + <MenuToggle + ref={toggleRef} + onClick={() => setIsOpen(!isOpen)} + isExpanded={isOpen} + style={ + { + width: '100%', + } as React.CSSProperties + } + > + {value} + </MenuToggle> + ); + + return ( + <Select + isOpen={isOpen} + selected={value} + onSelect={onSelect} + onOpenChange={() => setIsOpen(!isOpen)} + toggle={toggle} + > + {AWS_REGIONS.map(({ description, value: region }) => ( + <SelectOption key={description} value={region}> + {region} + </SelectOption> + ))} + </Select> + ); +}; + const Aws = () => { const dispatch = useAppDispatch(); const shareMethod = useAppSelector(selectAwsShareMethod); const shareWithAccount = useAppSelector(selectAwsAccountId); + const region = useAppSelector(selectAwsRegion); return ( <Form> @@ -62,40 +118,42 @@ const Aws = () => { Your image will be uploaded to AWS and shared with the account you provide below. </Content> - <Content> - <b>The shared image will expire within 14 days.</b> To permanently - access the image, copy the image, which will be shared to your account - by Red Hat, to your own AWS account. - </Content> - <FormGroup label="Share method:"> - {!process.env.IS_ON_PREMISE && ( - <Radio - id="radio-with-description" - label="Use an account configured from Sources." - name="radio-7" - description="Use a configured source to launch environments directly from the console." - isChecked={shareMethod === 'sources'} - onChange={() => { - dispatch(changeAwsSourceId(undefined)); - dispatch(changeAwsAccountId('')); - dispatch(changeAwsShareMethod('sources')); - }} - autoFocus - /> - )} - <Radio - id="radio" - label="Manually enter an account ID." - name="radio-8" - isChecked={shareMethod === 'manual'} - onChange={() => { - dispatch(changeAwsSourceId(undefined)); - dispatch(changeAwsAccountId('')); - dispatch(changeAwsShareMethod('manual')); - }} - autoFocus={!!process.env.IS_ON_PREMISE} - /> - </FormGroup> + {!process.env.IS_ON_PREMISE && ( + <> + <Content> + <b>The shared image will expire within 14 days.</b> To permanently + access the image, copy the image, which will be shared to your + account by Red Hat, to your own AWS account. + </Content> + <FormGroup label="Share method:"> + <Radio + id="radio-with-description" + label="Use an account configured from Sources." + name="radio-7" + description="Use a configured source to launch environments directly from the console." + isChecked={shareMethod === 'sources'} + onChange={() => { + dispatch(changeAwsSourceId(undefined)); + dispatch(changeAwsAccountId('')); + dispatch(changeAwsShareMethod('sources')); + }} + autoFocus + /> + <Radio + id="radio" + label="Manually enter an account ID." + name="radio-8" + isChecked={shareMethod === 'manual'} + onChange={() => { + dispatch(changeAwsSourceId(undefined)); + dispatch(changeAwsAccountId('')); + dispatch(changeAwsShareMethod('manual')); + }} + autoFocus={!!process.env.IS_ON_PREMISE} + /> + </FormGroup> + </> + )} {shareMethod === 'sources' && ( <> <AwsSourcesSelect /> @@ -125,22 +183,34 @@ const Aws = () => { )} {shareMethod === 'manual' && ( <> - <FormGroup label="AWS account ID" isRequired> - <ValidatedInput - ariaLabel="aws account id" - value={shareWithAccount || ''} - validator={isAwsAccountIdValid} - onChange={(_event, value) => dispatch(changeAwsAccountId(value))} - helperText="Should be 12 characters long." - /> - </FormGroup> + {!process.env.IS_ON_PREMISE && ( + <FormGroup label="AWS account ID" isRequired> + <ValidatedInput + ariaLabel="aws account id" + value={shareWithAccount || ''} + validator={isAwsAccountIdValid} + onChange={(_event, value) => + dispatch(changeAwsAccountId(value)) + } + helperText="Should be 12 characters long." + /> + </FormGroup> + )} <FormGroup label="Default region" isRequired> - <TextInput - value={'us-east-1'} - type="text" - aria-label="default region" - readOnlyVariant="default" - /> + {!process.env.IS_ON_PREMISE && ( + <TextInput + value={'us-east-1'} + type="text" + aria-label="default region" + readOnlyVariant="default" + /> + )} + {process.env.IS_ON_PREMISE && ( + <AWSRegion + value={region || ''} + onChange={(v) => dispatch(changeAwsRegion(v))} + /> + )} </FormGroup> </> )} From 3a9e3aa2006f5c700ff9ebbd4ef69a637fbeb847 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 1 Jul 2025 16:15:26 +0100 Subject: [PATCH 009/123] requestMapper: add region to aws upload type The on-prem backend needs the aws region in order to upload the ami target to aws. In order to do this, we use some specific cockpit types that contain the region field, meaning that requests to image-builder-crc should be unchanged. This is essentialy the wiring commit to get this functionality into the `/composes` endpoint for on-prem. --- .../steps/Review/Footer/CreateDropdown.tsx | 17 +++++++++-- .../steps/Review/Footer/EditDropdown.tsx | 22 +++++++++++--- .../utilities/requestMapper.ts | 30 +++++++++++++++---- 3 files changed, 57 insertions(+), 12 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx b/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx index d9ee3d82..1f50f45f 100644 --- a/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx +++ b/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx @@ -22,6 +22,7 @@ import { useCreateBPWithNotification as useCreateBlueprintMutation, } from '../../../../../Hooks'; import { setBlueprintId } from '../../../../../store/BlueprintSlice'; +import { CockpitCreateBlueprintRequest } from '../../../../../store/cockpit/types'; import { useAppDispatch, useAppSelector } from '../../../../../store/hooks'; import { CreateBlueprintRequest, @@ -31,7 +32,9 @@ import { selectPackages } from '../../../../../store/wizardSlice'; import { createAnalytics } from '../../../../../Utilities/analytics'; type CreateDropdownProps = { - getBlueprintPayload: () => Promise<'' | CreateBlueprintRequest | undefined>; + getBlueprintPayload: () => Promise< + '' | CreateBlueprintRequest | CockpitCreateBlueprintRequest | undefined + >; setIsOpen: (isOpen: boolean) => void; isDisabled: boolean; }; @@ -62,7 +65,11 @@ export const CreateSaveAndBuildBtn = ({ setIsOpen(false); if (!process.env.IS_ON_PREMISE && requestBody) { - const analyticsData = createAnalytics(requestBody, packages, isBeta); + const analyticsData = createAnalytics( + requestBody as CreateBlueprintRequest, + packages, + isBeta + ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Created`, { ...analyticsData, type: 'createBlueprintAndBuildImages', @@ -161,7 +168,11 @@ export const CreateSaveButton = ({ setIsOpen(false); if (!process.env.IS_ON_PREMISE && requestBody) { - const analyticsData = createAnalytics(requestBody, packages, isBeta); + const analyticsData = createAnalytics( + requestBody as CreateBlueprintRequest, + packages, + isBeta + ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Created`, { ...analyticsData, type: 'createBlueprint', diff --git a/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx b/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx index b3325b13..132e4818 100644 --- a/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx +++ b/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx @@ -16,13 +16,16 @@ import { useComposeBPWithNotification as useComposeBlueprintMutation, useUpdateBPWithNotification as useUpdateBlueprintMutation, } from '../../../../../Hooks'; +import { CockpitCreateBlueprintRequest } from '../../../../../store/cockpit/types'; import { useAppSelector } from '../../../../../store/hooks'; import { CreateBlueprintRequest } from '../../../../../store/imageBuilderApi'; import { selectPackages } from '../../../../../store/wizardSlice'; import { createAnalytics } from '../../../../../Utilities/analytics'; type EditDropdownProps = { - getBlueprintPayload: () => Promise<'' | CreateBlueprintRequest | undefined>; + getBlueprintPayload: () => Promise< + '' | CreateBlueprintRequest | CockpitCreateBlueprintRequest | undefined + >; setIsOpen: (isOpen: boolean) => void; blueprintId: string; isDisabled: boolean; @@ -54,7 +57,11 @@ export const EditSaveAndBuildBtn = ({ const requestBody = await getBlueprintPayload(); if (!process.env.IS_ON_PREMISE && requestBody) { - const analyticsData = createAnalytics(requestBody, packages, isBeta); + const analyticsData = createAnalytics( + requestBody as CreateBlueprintRequest, + packages, + isBeta + ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Updated`, { ...analyticsData, type: 'editBlueprintAndBuildImages', @@ -111,7 +118,11 @@ export const EditSaveButton = ({ const requestBody = await getBlueprintPayload(); if (!process.env.IS_ON_PREMISE && requestBody) { - const analyticsData = createAnalytics(requestBody, packages, isBeta); + const analyticsData = createAnalytics( + requestBody as CreateBlueprintRequest, + packages, + isBeta + ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Updated`, { ...analyticsData, type: 'editBlueprint', @@ -120,7 +131,10 @@ export const EditSaveButton = ({ } setIsOpen(false); if (requestBody) { - updateBlueprint({ id: blueprintId, createBlueprintRequest: requestBody }); + updateBlueprint({ + id: blueprintId, + createBlueprintRequest: requestBody, + }); } }; return ( diff --git a/src/Components/CreateImageWizard/utilities/requestMapper.ts b/src/Components/CreateImageWizard/utilities/requestMapper.ts index 3b496da0..fc9756e1 100644 --- a/src/Components/CreateImageWizard/utilities/requestMapper.ts +++ b/src/Components/CreateImageWizard/utilities/requestMapper.ts @@ -18,6 +18,12 @@ import { SATELLITE_SERVICE_PATH, } from '../../../constants'; import { RootState } from '../../../store'; +import { + CockpitAwsUploadRequestOptions, + CockpitCreateBlueprintRequest, + CockpitImageRequest, + CockpitUploadTypes, +} from '../../../store/cockpit/types'; import { AwsUploadRequestOptions, AzureUploadRequestOptions, @@ -48,6 +54,7 @@ import { selectActivationKey, selectArchitecture, selectAwsAccountId, + selectAwsRegion, selectAwsShareMethod, selectAwsSourceId, selectAzureHyperVGeneration, @@ -122,7 +129,7 @@ import { GcpAccountType, GcpShareMethod } from '../steps/TargetEnvironment/Gcp'; export const mapRequestFromState = ( store: Store, orgID: string -): CreateBlueprintRequest => { +): CreateBlueprintRequest | CockpitCreateBlueprintRequest => { const state = store.getState(); const imageRequests = getImageRequests(state); const customizations = getCustomizations(state, orgID); @@ -456,7 +463,9 @@ const getFirstBootScript = (files?: File[]): string => { return firstBootFile?.data ? atob(firstBootFile.data) : ''; }; -const getImageRequests = (state: RootState): ImageRequest[] => { +const getImageRequests = ( + state: RootState +): ImageRequest[] | CockpitImageRequest[] => { const imageTypes = selectImageTypes(state); const snapshotDate = selectSnapshotDate(state); const useLatest = selectUseLatest(state); @@ -482,7 +491,9 @@ const getSatelliteCommand = (files?: File[]): string => { return satelliteCommandFile?.data ? atob(satelliteCommandFile.data) : ''; }; -const uploadTypeByTargetEnv = (imageType: ImageTypes): UploadTypes => { +const uploadTypeByTargetEnv = ( + imageType: ImageTypes +): UploadTypes | CockpitUploadTypes => { switch (imageType) { case 'aws': return 'aws'; @@ -516,12 +527,21 @@ const getImageOptions = ( ): | AwsUploadRequestOptions | AzureUploadRequestOptions - | GcpUploadRequestOptions => { + | GcpUploadRequestOptions + | CockpitAwsUploadRequestOptions => { switch (imageType) { case 'aws': if (selectAwsShareMethod(state) === 'sources') return { share_with_sources: [selectAwsSourceId(state) || ''] }; - return { share_with_accounts: [selectAwsAccountId(state)] }; + if (!process.env.IS_ON_PREMISE) + return { share_with_accounts: [selectAwsAccountId(state)] }; + + // TODO: we might want to update the image-builder-crc api + // to accept a region instead (with default us-east-1) + return { + share_with_accounts: [selectAwsAccountId(state)], + region: selectAwsRegion(state), + }; case 'azure': if (selectAzureShareMethod(state) === 'sources') return { From 8af4181ae94693c96dd548f55e6712c9c6b47850 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 1 Jul 2025 16:55:04 +0100 Subject: [PATCH 010/123] store/cockpitApi: refactor `/compose` endpoint The on-prem `/compose` endpoint needs to know about two different compose requests. The image-builder-crc compose request gets saved to the frontend's local storage. While a different request gets sent to osbuild's cloudapi. This commit tidy's up and refactors the code in the /compose endpoint in the cockpit api. --- src/store/cockpit/cockpitApi.ts | 97 +++++++++++++++++++-------------- 1 file changed, 57 insertions(+), 40 deletions(-) diff --git a/src/store/cockpit/cockpitApi.ts b/src/store/cockpit/cockpitApi.ts index 68fdf69e..b2487b29 100644 --- a/src/store/cockpit/cockpitApi.ts +++ b/src/store/cockpit/cockpitApi.ts @@ -11,6 +11,7 @@ import cockpit from 'cockpit'; import { fsinfo } from 'cockpit/fsinfo'; import { v4 as uuidv4 } from 'uuid'; +import { Blueprint } from './composerCloudApi'; // We have to work around RTK query here, since it doesn't like splitting // out the same api into two separate apis. So, instead, we can just // inherit/import the `contentSourcesApi` and build on top of that. @@ -19,6 +20,10 @@ import { v4 as uuidv4 } from 'uuid'; // bit so that the `cockpitApi` doesn't become a monolith. import { contentSourcesApi } from './contentSourcesApi'; import type { + CockpitCreateBlueprintApiArg, + CockpitCreateBlueprintRequest, + CockpitImageRequest, + CockpitUpdateBlueprintApiArg, UpdateWorkerConfigApiArg, WorkerConfigFile, WorkerConfigResponse, @@ -35,7 +40,6 @@ import { ComposeBlueprintApiResponse, ComposeResponse, ComposesResponseItem, - CreateBlueprintApiArg, CreateBlueprintApiResponse, CreateBlueprintRequest, DeleteBlueprintApiArg, @@ -57,7 +61,6 @@ import { GetOscapCustomizationsApiResponse, GetOscapProfilesApiArg, GetOscapProfilesApiResponse, - UpdateBlueprintApiArg, UpdateBlueprintApiResponse, } from '../service/imageBuilderApi'; @@ -137,6 +140,28 @@ const getCloudConfigs = async () => { } }; +const mapToOnpremRequest = ( + blueprint: Blueprint, + distribution: string, + image_requests: CockpitImageRequest[] +) => { + return { + blueprint, + distribution, + image_requests: image_requests.map((ir) => ({ + architecture: ir.architecture, + image_type: ir.image_type, + repositories: [], + upload_targets: [ + { + type: ir.upload_request.type, + upload_options: ir.upload_request.options, + }, + ], + })), + }; +}; + export const cockpitApi = contentSourcesApi.injectEndpoints({ endpoints: (builder) => { return { @@ -285,7 +310,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ }), createBlueprint: builder.mutation< CreateBlueprintApiResponse, - CreateBlueprintApiArg + CockpitCreateBlueprintApiArg >({ queryFn: async ({ createBlueprintRequest: blueprintReq }) => { try { @@ -310,7 +335,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ }), updateBlueprint: builder.mutation< UpdateBlueprintApiResponse, - UpdateBlueprintApiArg + CockpitUpdateBlueprintApiArg >({ queryFn: async ({ id: id, createBlueprintRequest: blueprintReq }) => { try { @@ -460,55 +485,47 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ const contents = await file.read(); const parsed = JSON.parse(contents); - const createBPReq = parsed as CreateBlueprintRequest; - const blueprint = mapHostedToOnPrem(createBPReq); + const blueprint = parsed as CockpitCreateBlueprintRequest; const composes: ComposeResponse[] = []; - for (const ir of parsed.image_requests) { - const composeReq = { - distribution: createBPReq.distribution, - blueprint: blueprint, - image_requests: [ - { - architecture: ir.architecture, - image_type: ir.image_type, - repositories: [], - upload_targets: [ - { - type: 'local', - upload_options: {}, - }, - ], - }, - ], - }; - const saveReq = { - distribution: createBPReq.distribution, - blueprint: parsed, - image_requests: [ - { - architecture: ir.architecture, - image_type: ir.image_type, - repositories: [], - upload_request: { - type: 'local', - options: {}, - }, - }, - ], + for (const ir of blueprint.image_requests) { + if (ir.upload_request.type === 'aws.s3') { + // this differs to crc because the on-prem backend + // can actually understand a `local` image type. + // We can build this locally rather than sending it + // to an s3 bucket. + ir.upload_request.type = 'local'; + } + + // this request gets saved to the local storage and needs to + // match the hosted format + const crcComposeRequest = { + ...blueprint, + image_requests: [ir], }; + const composeResp = await baseQuery({ url: '/compose', method: 'POST', - body: JSON.stringify(composeReq), + body: JSON.stringify( + // since this is the request that gets sent to the cloudapi + // backend, we need to modify it slightly + mapToOnpremRequest( + mapHostedToOnPrem(blueprint as CreateBlueprintRequest), + crcComposeRequest.distribution, + [ir] + ) + ), headers: { 'content-type': 'application/json', }, }); + await cockpit .file(path.join(blueprintsDir, filename, composeResp.data?.id)) - .replace(JSON.stringify(saveReq)); + .replace(JSON.stringify(crcComposeRequest)); composes.push({ id: composeResp.data?.id }); } + return { data: composes, }; From a6eadbffac0a3ffcc66131a5f4ee5cc82cd7e27d Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 22 Jul 2025 09:50:46 +0100 Subject: [PATCH 011/123] playwright: add an aws upload test Create a blueprint configured for AWS and make sure it shows up in the images table when it is built. --- playwright/test.spec.ts | 49 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/playwright/test.spec.ts b/playwright/test.spec.ts index a8c43830..87b1b1f2 100644 --- a/playwright/test.spec.ts +++ b/playwright/test.spec.ts @@ -240,4 +240,53 @@ test.describe.serial('test', () => { ); await frame.getByRole('button', { name: 'Cancel' }).click(); }); + + test('cockpit cloud upload', async ({ page }) => { + if (isHosted()) { + return; + } + + await ensureAuthenticated(page); + await closePopupsIfExist(page); + // Navigate to IB landing page and get the frame + await navigateToLandingPage(page); + await page.goto('/cockpit-image-builder'); + const frame = ibFrame(page); + + frame.getByRole('heading', { name: 'Images About image builder' }); + frame.getByRole('heading', { name: 'Blueprints' }); + await frame.getByTestId('blueprints-create-button').click(); + + frame.getByRole('heading', { name: 'Image output' }); + // the first card should be the AWS card + await frame.locator('.pf-v6-c-card').first().click(); + await frame.getByRole('button', { name: 'Next', exact: true }).click(); + await frame.getByRole('button', { name: 'Next', exact: true }).click(); + await frame.getByRole('button', { name: 'Review and finish' }).click(); + await frame.getByRole('button', { name: 'Back', exact: true }).click(); + + frame.getByRole('heading', { name: 'Details' }); + await frame.getByTestId('blueprint').fill(blueprintName); + await expect(frame.getByTestId('blueprint')).toHaveValue(blueprintName); + await frame.getByRole('button', { name: 'Next', exact: true }).click(); + + await frame.getByRole('button', { name: 'Create blueprint' }).click(); + await frame.getByTestId('close-button-saveandbuild-modal').click(); + await frame.getByRole('button', { name: 'Create blueprint' }).click(); + + await frame + .getByRole('textbox', { name: 'Search input' }) + .fill(blueprintName); + // the clickable blueprint cards are a bit awkward, so use the + // button's id instead + await frame.locator(`button[id="${blueprintName}"]`).click(); + await frame.getByTestId('blueprint-build-image-menu-option').click(); + + // make sure the image is present + await frame + .getByTestId('images-table') + .getByRole('button', { name: 'Details' }) + .click(); + frame.getByText('Build Information'); + }); }); From 690b71636afb80597514bb978ea470a963385f14 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Tue, 22 Jul 2025 16:23:13 +0100 Subject: [PATCH 012/123] playwright: fix cockpit cloud provider test The test was a bit flaky, move the worker file check to the end of the test since it appears that we might be trying to read the file before it has been created. --- playwright/test.spec.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/playwright/test.spec.ts b/playwright/test.spec.ts index 87b1b1f2..86572a17 100644 --- a/playwright/test.spec.ts +++ b/playwright/test.spec.ts @@ -221,13 +221,6 @@ test.describe.serial('test', () => { ).toBeVisible(); } - const config = readFileSync('/etc/osbuild-worker/osbuild-worker.toml'); - // this is for testing, the field `aws` should exist - // eslint-disable-next-line - const parsed = TOML.parse(config) as any; - expect(parsed.aws?.bucket).toBe(bucket); - expect(parsed.aws?.credentials).toBe(credentials); - await frame .getByRole('button', { name: 'Configure Cloud Providers' }) .click(); @@ -236,9 +229,16 @@ test.describe.serial('test', () => { await expect(frame.getByPlaceholder('AWS bucket')).toHaveValue(bucket); await expect(frame.getByPlaceholder('Path to AWS credentials')).toHaveValue( - credentials + credentials, ); await frame.getByRole('button', { name: 'Cancel' }).click(); + + const config = readFileSync('/etc/osbuild-worker/osbuild-worker.toml'); + // this is for testing, the field `aws` should exist + // eslint-disable-next-line + const parsed = TOML.parse(config) as any; + expect(parsed.aws?.bucket).toBe(bucket); + expect(parsed.aws?.credentials).toBe(credentials); }); test('cockpit cloud upload', async ({ page }) => { From f86f81d6d5b0b70b61ffcd21a7ecea2aee3d0b3c Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Wed, 23 Jul 2025 10:06:10 +0100 Subject: [PATCH 013/123] api: remove pull command The api config supports pulling in the openapi schema's via a url, so there isn't a need to pull this in manually and just run the code generation. We also need to remove the `openshift-virt` target since this was removed from image-builder-crc. --- .github/workflows/dev-checks.yml | 2 +- api/config/compliance.ts | 2 +- api/config/composerCloudApi.ts | 8 +- api/config/contentSources.ts | 2 +- api/config/edge.ts | 2 +- api/config/imageBuilder.ts | 3 +- api/config/provisioning.ts | 2 +- api/config/rhsm.ts | 2 +- api/pull.sh | 10 - api/schema/compliance.json | 17629 ---------------------- api/schema/composerCloudApi.v2.yaml | 2826 ---- api/schema/contentSources.json | 6657 -------- api/schema/edge.json | 5919 -------- api/schema/imageBuilder.yaml | 2277 --- api/schema/provisioning.json | 2193 --- api/schema/rhsm.json | 1 - package.json | 4 +- src/Components/ImagesTable/Instance.tsx | 18 +- src/constants.ts | 1 - src/store/cockpit/composerCloudApi.ts | 3 + src/store/service/edgeApi.ts | 26 +- src/store/service/imageBuilderApi.ts | 68 +- 22 files changed, 102 insertions(+), 37553 deletions(-) delete mode 100644 api/pull.sh delete mode 100644 api/schema/compliance.json delete mode 100644 api/schema/composerCloudApi.v2.yaml delete mode 100644 api/schema/contentSources.json delete mode 100644 api/schema/edge.json delete mode 100644 api/schema/imageBuilder.yaml delete mode 100644 api/schema/provisioning.json delete mode 100644 api/schema/rhsm.json diff --git a/.github/workflows/dev-checks.yml b/.github/workflows/dev-checks.yml index b67d0cc8..8f3a40bf 100644 --- a/.github/workflows/dev-checks.yml +++ b/.github/workflows/dev-checks.yml @@ -71,7 +71,7 @@ jobs: run: npm ci - name: Check for manual changes to API run: | - npm run api:generate + npm run api if [ -n "$(git status --porcelain)" ]; then echo echo "✗ API manually changed, please refer to the README for the procedure to follow for programmatically generated API endpoints." diff --git a/api/config/compliance.ts b/api/config/compliance.ts index f06197ce..2a005846 100644 --- a/api/config/compliance.ts +++ b/api/config/compliance.ts @@ -1,7 +1,7 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/compliance.json', + schemaFile: 'https://console.redhat.com/api/compliance/v2/openapi.json', apiFile: '../../src/store/service/emptyComplianceApi.ts', apiImport: 'emptyComplianceApi', outputFile: '../../src/store/service/complianceApi.ts', diff --git a/api/config/composerCloudApi.ts b/api/config/composerCloudApi.ts index ac6e3396..dc916936 100644 --- a/api/config/composerCloudApi.ts +++ b/api/config/composerCloudApi.ts @@ -1,17 +1,15 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/composerCloudApi.v2.yaml', + schemaFile: + 'https://raw.githubusercontent.com/osbuild/osbuild-composer/main/internal/cloudapi/v2/openapi.v2.yml', apiFile: '../../src/store/cockpit/emptyComposerCloudApi.ts', apiImport: 'emptyComposerCloudApi', outputFile: '../../src/store/cockpit/composerCloudApi.ts', exportName: 'composerCloudApi', hooks: false, unionUndefined: true, - filterEndpoints: [ - 'postCompose', - 'getComposeStatus', - ], + filterEndpoints: ['postCompose', 'getComposeStatus'], }; export default config; diff --git a/api/config/contentSources.ts b/api/config/contentSources.ts index c901dc20..7d4db495 100644 --- a/api/config/contentSources.ts +++ b/api/config/contentSources.ts @@ -1,7 +1,7 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/contentSources.json', + schemaFile: 'https://console.redhat.com/api/content-sources/v1/openapi.json', apiFile: '../../src/store/service/emptyContentSourcesApi.ts', apiImport: 'emptyContentSourcesApi', outputFile: '../../src/store/service/contentSourcesApi.ts', diff --git a/api/config/edge.ts b/api/config/edge.ts index ba528d07..4b1aa139 100644 --- a/api/config/edge.ts +++ b/api/config/edge.ts @@ -1,7 +1,7 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/edge.json', + schemaFile: 'https://console.redhat.com/api/edge/v1/openapi.json', apiFile: '../../src/store/service/emptyEdgeApi.ts', apiImport: 'emptyEdgeApi', outputFile: '../../src/store/service/edgeApi.ts', diff --git a/api/config/imageBuilder.ts b/api/config/imageBuilder.ts index 2bc1f324..da0bceea 100644 --- a/api/config/imageBuilder.ts +++ b/api/config/imageBuilder.ts @@ -1,7 +1,8 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/imageBuilder.yaml', + schemaFile: + 'https://raw.githubusercontent.com/osbuild/image-builder/main/internal/v1/api.yaml', apiFile: '../../src/store/service/emptyImageBuilderApi.ts', apiImport: 'emptyImageBuilderApi', outputFile: '../../src/store/service/imageBuilderApi.ts', diff --git a/api/config/provisioning.ts b/api/config/provisioning.ts index 40e5b91b..1b772426 100644 --- a/api/config/provisioning.ts +++ b/api/config/provisioning.ts @@ -1,7 +1,7 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/provisioning.json', + schemaFile: 'https://console.redhat.com/api/provisioning/v1/openapi.json', apiFile: '../../src/store/service/emptyProvisioningApi.ts', apiImport: 'emptyProvisioningApi', outputFile: '../../src/store/service/provisioningApi.ts', diff --git a/api/config/rhsm.ts b/api/config/rhsm.ts index 69797989..a2f9bfd3 100644 --- a/api/config/rhsm.ts +++ b/api/config/rhsm.ts @@ -1,7 +1,7 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/rhsm.json', + schemaFile: 'https://console.redhat.com/api/rhsm/v2/openapi.json', apiFile: '../../src/store/service/emptyRhsmApi.ts', apiImport: 'emptyRhsmApi', outputFile: '../../src/store/service/rhsmApi.ts', diff --git a/api/pull.sh b/api/pull.sh deleted file mode 100644 index b9b926d7..00000000 --- a/api/pull.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash - -# Download the most up-to-date schema files and overwrite the existing ones -curl https://raw.githubusercontent.com/osbuild/image-builder/main/internal/v1/api.yaml -o ./api/schema/imageBuilder.yaml -curl https://console.redhat.com/api/rhsm/v2/openapi.json -o ./api/schema/rhsm.json -curl https://console.redhat.com/api/content-sources/v1/openapi.json -o ./api/schema/contentSources.json -curl https://console.redhat.com/api/provisioning/v1/openapi.json -o ./api/schema/provisioning.json -curl https://console.redhat.com/api/edge/v1/openapi.json -o ./api/schema/edge.json -curl https://console.redhat.com/api/compliance/v2/openapi.json -o ./api/schema/compliance.json -curl https://raw.githubusercontent.com/osbuild/osbuild-composer/main/internal/cloudapi/v2/openapi.v2.yml -o ./api/schema/composerCloudApi.v2.yaml diff --git a/api/schema/compliance.json b/api/schema/compliance.json deleted file mode 100644 index 3b8497eb..00000000 --- a/api/schema/compliance.json +++ /dev/null @@ -1,17629 +0,0 @@ -{ - "openapi": "3.1.0", - "info": { - "title": "Cloud Services for RHEL Compliance API v2", - "version": "v2", - "description": "This is the API for Cloud Services for RHEL Compliance. You can find out more about Red Hat Cloud Services for RHEL at [https://console.redhat.com/](https://console.redhat.com/)" - }, - "servers": [ - { - "url": "https://{defaultHost}/api/compliance/v2", - "variables": { - "defaultHost": { - "default": "console.redhat.com" - } - } - } - ], - "paths": { - "/policies": { - "get": { - "summary": "Request Policies", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "os_major_version", - "total_system_count", - "business_objective", - "compliance_threshold", - "title:asc", - "title:desc", - "os_major_version:asc", - "os_major_version:desc", - "total_system_count:asc", - "total_system_count:desc", - "business_objective:asc", - "business_objective:desc", - "compliance_threshold:asc", - "compliance_threshold:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Policies are searchable using attributes `title`, `os_major_version`, and `os_minor_version`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Retrieve the list of policies that have been created to test the compliance of your registered systems.", - "operationId": "Policies", - "responses": { - "200": { - "description": "Lists Policies", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Policies": { - "value": { - "data": [ - { - "id": "0aef59f7-5aac-4614-9346-cc72723eface", - "title": "Maiores sunt quos et.", - "description": "Quia cupiditate quis. Rerum modi consequuntur. Voluptatem provident ullam.", - "business_objective": null, - "compliance_threshold": 24.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Quam voluptas eum iste.", - "ref_id": "xccdf_org.ssgproject.content_profile_7df4b808ec42b3692cda3bac1713260b" - }, - { - "id": "16114f64-f623-471c-b04e-12586c301e14", - "title": "Repellat at reprehenderit harum.", - "description": "Quam necessitatibus recusandae. Ut quae quisquam. Explicabo quae vel.", - "business_objective": null, - "compliance_threshold": 21.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Nam delectus qui rerum.", - "ref_id": "xccdf_org.ssgproject.content_profile_1e51f6f4679ce47508c6ce9d2ed0a8e9" - }, - { - "id": "18175462-2ae5-4f46-8430-2e73c06aa760", - "title": "Et odit dolorem magni.", - "description": "Non saepe exercitationem. Natus ut reiciendis. Deserunt qui consequatur.", - "business_objective": null, - "compliance_threshold": 29.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Voluptatem qui iste est.", - "ref_id": "xccdf_org.ssgproject.content_profile_301035df51e2f8756483224ee4ef7d2c" - }, - { - "id": "2661b423-d86f-4193-bcc7-36f9c6466e3b", - "title": "Labore minus quis deserunt.", - "description": "Est dicta ut. Omnis libero ea. Dignissimos et in.", - "business_objective": null, - "compliance_threshold": 89.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Quisquam aliquam quis ducimus.", - "ref_id": "xccdf_org.ssgproject.content_profile_6b2a26e4f036aaebef129114ebaf37b5" - }, - { - "id": "2709efbe-184f-4290-b9f6-ff577a9b7a5e", - "title": "Et voluptatum est aut.", - "description": "Facilis ratione tempora. Voluptates est eos. Occaecati tenetur dolores.", - "business_objective": null, - "compliance_threshold": 12.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Qui autem id id.", - "ref_id": "xccdf_org.ssgproject.content_profile_e8e17ff81d6b5c8b01481c13c851c1db" - }, - { - "id": "2cbfaa94-775b-4cad-b408-a05b6f53f144", - "title": "Quam est aut deserunt.", - "description": "Velit explicabo maiores. Laboriosam veniam rerum. Commodi et ut.", - "business_objective": null, - "compliance_threshold": 90.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Pariatur nam et sequi.", - "ref_id": "xccdf_org.ssgproject.content_profile_e45e56b6ca8fc23d5fa2bc4a49b19e22" - }, - { - "id": "30cc7e98-54ab-433d-8dc1-e6822941a956", - "title": "Aut ratione delectus beatae.", - "description": "Molestias totam animi. Magni vitae non. Perspiciatis eos et.", - "business_objective": null, - "compliance_threshold": 27.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Non voluptatem possimus non.", - "ref_id": "xccdf_org.ssgproject.content_profile_65f600924dbf8d9af413cd221d1f462d" - }, - { - "id": "31afdcbc-653c-451a-904c-6425c9c4bd69", - "title": "Perspiciatis provident reprehenderit ducimus.", - "description": "Excepturi sit sapiente. Perferendis fugit impedit. Porro rerum mollitia.", - "business_objective": null, - "compliance_threshold": 62.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Natus nisi sed qui.", - "ref_id": "xccdf_org.ssgproject.content_profile_c50c7ed64e711e0b5c376579ac9d321f" - }, - { - "id": "34572b3a-4c91-4479-8f94-65d73351e559", - "title": "Aperiam est quasi repudiandae.", - "description": "Qui alias sit. Recusandae beatae et. Nihil et et.", - "business_objective": null, - "compliance_threshold": 13.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Ex rerum asperiores molestiae.", - "ref_id": "xccdf_org.ssgproject.content_profile_e6e5d11ad98f0198f13d2cbfcb43b5a2" - }, - { - "id": "36f96798-e0c1-40bf-89da-5ada9ba4ce17", - "title": "Modi itaque dolorum delectus.", - "description": "Reprehenderit qui et. Debitis nihil sit. Aspernatur ut minus.", - "business_objective": null, - "compliance_threshold": 44.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Rerum rem placeat cupiditate.", - "ref_id": "xccdf_org.ssgproject.content_profile_0872cd6091ad51d082384e16e50d7cce" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies?limit=10&offset=0", - "last": "/api/compliance/v2/policies?limit=10&offset=20", - "next": "/api/compliance/v2/policies?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Policies sorted by \"os_major_version:asc\"": { - "value": { - "data": [ - { - "id": "04e247e5-fd9b-4f00-80ff-9e534a4ba19c", - "title": "Dolorum cumque culpa odit.", - "description": "Ut ut similique. Facilis illo ipsa. Facere mollitia aspernatur.", - "business_objective": null, - "compliance_threshold": 18.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Voluptatem modi maiores neque.", - "ref_id": "xccdf_org.ssgproject.content_profile_411ebd096aafa4af48be5d2aabbac684" - }, - { - "id": "073818bc-e4a5-49a7-b06f-fa7a08640c64", - "title": "Unde voluptates quia aut.", - "description": "Dolorem ullam molestiae. Qui sit consequuntur. Quis error neque.", - "business_objective": null, - "compliance_threshold": 86.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Perspiciatis accusantium sunt nam.", - "ref_id": "xccdf_org.ssgproject.content_profile_0de4dc72276aab82b68af219c3418531" - }, - { - "id": "1cff06a1-61d0-4200-93ba-e466b3c93e3f", - "title": "Non illum dolor expedita.", - "description": "Sunt dignissimos debitis. Iure temporibus eligendi. Aperiam ut deleniti.", - "business_objective": null, - "compliance_threshold": 71.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Earum et nihil quia.", - "ref_id": "xccdf_org.ssgproject.content_profile_bb6287a5729ffd55fee99b2b389848e3" - }, - { - "id": "2189d96c-991f-47ef-bdbf-86b009b3b757", - "title": "Laborum quia optio voluptatibus.", - "description": "Eveniet nemo eius. Quos et consequatur. Aut vero quibusdam.", - "business_objective": null, - "compliance_threshold": 85.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Sapiente pariatur omnis blanditiis.", - "ref_id": "xccdf_org.ssgproject.content_profile_5af3adb6287a78a1f0f3d702f7ec741e" - }, - { - "id": "23e9562d-b9ae-4f45-8b16-81f491dcc564", - "title": "Quia eum aut similique.", - "description": "Qui voluptatibus nesciunt. Hic ut aut. Provident fuga libero.", - "business_objective": null, - "compliance_threshold": 33.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Autem sit eligendi placeat.", - "ref_id": "xccdf_org.ssgproject.content_profile_9c4d69808ecf013e6b5a43bdc1c5a48d" - }, - { - "id": "27b5eaf7-cc20-4fc8-be46-3e4ec6544bf7", - "title": "Sed aut doloribus aspernatur.", - "description": "Et ducimus consequatur. Voluptate autem iusto. Doloremque accusamus labore.", - "business_objective": null, - "compliance_threshold": 83.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Nihil ipsa fuga laborum.", - "ref_id": "xccdf_org.ssgproject.content_profile_5831afccbbcb06df7211d7d02efdcc9b" - }, - { - "id": "2fba4a27-ecf8-466f-80d3-26474430047a", - "title": "Iusto qui commodi sint.", - "description": "Nostrum id quia. Quasi incidunt officiis. Quaerat non iure.", - "business_objective": null, - "compliance_threshold": 7.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Ullam dolorem dolor rem.", - "ref_id": "xccdf_org.ssgproject.content_profile_64060000bd8adf69b8dcc7d1de67d10f" - }, - { - "id": "32f0a4d1-7dfc-422c-986d-352526046d16", - "title": "Possimus cum quos pariatur.", - "description": "Architecto nobis veniam. Voluptatem facere voluptate. Quis voluptates ut.", - "business_objective": null, - "compliance_threshold": 71.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Quisquam nihil et rerum.", - "ref_id": "xccdf_org.ssgproject.content_profile_a6fdad4e61f45eded822d3ba9ba1a4b4" - }, - { - "id": "34021287-4a17-41b6-81e5-ea28388ff0b9", - "title": "Quia repellendus quia voluptas.", - "description": "Incidunt et debitis. Ut ipsa laboriosam. Ut dicta et.", - "business_objective": null, - "compliance_threshold": 80.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Eveniet est voluptatem accusantium.", - "ref_id": "xccdf_org.ssgproject.content_profile_1fb876d87ccc8e3e1ac79e40e5de7758" - }, - { - "id": "3e9ba4af-73e2-4254-a441-dda05f2ebf68", - "title": "Quidem est vel qui.", - "description": "Dolorem libero ut. Ipsam magni sint. Aut quidem est.", - "business_objective": null, - "compliance_threshold": 70.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Dicta a voluptatibus rem.", - "ref_id": "xccdf_org.ssgproject.content_profile_45b13b752789ae3201d5675ef9ecebfb" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "os_major_version" - }, - "links": { - "first": "/api/compliance/v2/policies?limit=10&offset=0&sort_by=os_major_version", - "last": "/api/compliance/v2/policies?limit=10&offset=20&sort_by=os_major_version", - "next": "/api/compliance/v2/policies?limit=10&offset=10&sort_by=os_major_version" - } - }, - "summary": "", - "description": "" - }, - "List of Policies filtered by \"(os_major_version=8)\"": { - "value": { - "data": [], - "meta": { - "total": 0, - "filter": "(os_major_version=8)", - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies?filter=%28os_major_version%3D8%29&limit=10&offset=0", - "last": "/api/compliance/v2/policies?filter=%28os_major_version%3D8%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/policy" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "post": { - "summary": "Create a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - } - ], - "tags": [ - "Policies" - ], - "description": "Create a new security policy.", - "operationId": "CreatePolicy", - "responses": { - "201": { - "description": "Creates a Policy", - "content": { - "application/vnd.api+json": { - "examples": { - "Response example": { - "value": { - "data": { - "id": "5666da40-a302-4d34-9da5-62af457a168a", - "title": "Foo", - "description": "Hello World", - "business_objective": "Serious Business Objective", - "compliance_threshold": 33.3, - "total_system_count": null, - "type": "policy", - "os_major_version": 7, - "profile_title": "Sed distinctio quia nihil.", - "ref_id": "xccdf_org.ssgproject.content_profile_1b9f1caa0965033a01793fa5231c7ad1" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/policy" - } - } - } - } - } - } - } - } - }, - "requestBody": { - "content": { - "application/vnd.api+json": { - "schema": { - "$ref": "#/components/schemas/policy" - } - } - } - } - } - }, - "/policies/{policy_id}": { - "get": { - "summary": "Request a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Retrieve a specific policy.", - "operationId": "Policy", - "responses": { - "200": { - "description": "Returns a Policy", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Policy": { - "value": { - "data": { - "id": "798a9ee1-4dff-4316-a536-59b283b33901", - "title": "Et voluptatibus dolores cum.", - "description": "Repellendus laboriosam tempora. Itaque ut quisquam. Incidunt reiciendis iste.", - "business_objective": null, - "compliance_threshold": 9.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Atque enim est magni.", - "ref_id": "xccdf_org.ssgproject.content_profile_2750dd8208bfe3bceaab0a64d63c1796" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/policy" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Policy": { - "value": { - "errors": [ - "V2::Policy not found with ID b91e15b6-7cf1-4bd6-8add-6edcc4769cc8" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "patch": { - "summary": "Update a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Edit or update an existing policy.", - "operationId": "UpdatePolicy", - "responses": { - "202": { - "description": "Updates a Policy", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns the updated Policy": { - "value": { - "data": { - "id": "3a5a634e-1d12-4eca-a073-93781384b3ed", - "title": "Sit perferendis fugiat fugit.", - "description": "Animi error sunt. Magnam soluta quis. Magni est esse.", - "business_objective": null, - "compliance_threshold": 100.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Et eum est beatae.", - "ref_id": "xccdf_org.ssgproject.content_profile_a089488092364d0b1afbc8dee2c270a8" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/policy" - } - } - } - } - } - } - } - } - }, - "requestBody": { - "content": { - "application/vnd.api+json": { - "schema": { - "$ref": "#/components/schemas/policy_update" - } - } - } - } - }, - "delete": { - "summary": "Delete a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Delete a specific policy.", - "operationId": "DeletePolicy", - "responses": { - "202": { - "description": "Deletes a Policy", - "content": { - "application/vnd.api+json": { - "examples": { - "Deletes a Policy": { - "value": { - "data": { - "id": "e066629a-f9d7-44c4-9aeb-e0e8249fb270", - "title": "Accusamus non consequatur facere.", - "description": "Voluptate porro et. Voluptates nobis nostrum. Voluptatum dolores velit.", - "business_objective": null, - "compliance_threshold": 18.0, - "total_system_count": 0, - "type": "policy", - "os_major_version": 7, - "profile_title": "Ea quia iusto dignissimos.", - "ref_id": "xccdf_org.ssgproject.content_profile_1a601f6d84f94a2dad0c71155ff571c8" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/policy" - } - } - } - } - } - } - } - } - } - } - }, - "/systems/{system_id}/policies": { - "get": { - "summary": "Request Policies assigned to a System", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "business_objective", - "compliance_threshold", - "title:asc", - "title:desc", - "business_objective:asc", - "business_objective:desc", - "compliance_threshold:asc", - "compliance_threshold:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Policies are searchable using attributes `title` and `os_minor_version`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "system_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Systems" - ], - "description": "List all policies assigned to a single system.", - "operationId": "SystemsPolicies", - "responses": { - "200": { - "description": "Lists Policies", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Policies under a System": { - "value": { - "data": [ - { - "id": "171e6813-9160-44b8-9c40-63e918662932", - "title": "Consequatur fugiat incidunt perspiciatis.", - "description": "Exercitationem ut quam. Voluptates repellendus nostrum. Saepe adipisci molestias.", - "business_objective": null, - "compliance_threshold": 2.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Autem et sapiente rerum.", - "ref_id": "xccdf_org.ssgproject.content_profile_48b11f1070adff49b656ce94b024a5b5" - }, - { - "id": "21ba7219-0e3d-40dc-844f-e996e32a5b39", - "title": "Autem nisi non qui.", - "description": "Dolores ipsum ut. Praesentium consequuntur qui. Magni ut ut.", - "business_objective": null, - "compliance_threshold": 46.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Odit earum reiciendis provident.", - "ref_id": "xccdf_org.ssgproject.content_profile_1f4633572e8003024f176b975034fef4" - }, - { - "id": "2d384102-4937-4308-8ba9-64c760403039", - "title": "Rerum voluptatem et eaque.", - "description": "Natus similique architecto. Necessitatibus modi reiciendis. Soluta omnis at.", - "business_objective": null, - "compliance_threshold": 55.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Aut omnis ad qui.", - "ref_id": "xccdf_org.ssgproject.content_profile_43829a2cddb4b7fb684d57b47bf7eef4" - }, - { - "id": "2fd38abe-75eb-450e-9f45-1684bbf370cc", - "title": "Earum rerum nemo sed.", - "description": "Quia optio est. Rerum assumenda ratione. Iusto rerum autem.", - "business_objective": null, - "compliance_threshold": 25.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Rerum occaecati alias quam.", - "ref_id": "xccdf_org.ssgproject.content_profile_2c53fc185f4e88f57cca730d51c85f0a" - }, - { - "id": "36b2bc7b-82d7-4359-b4ff-3c82c6c82c1c", - "title": "Cumque aspernatur ipsa officia.", - "description": "Repellendus porro iusto. Ipsum et id. Vel tempora minima.", - "business_objective": null, - "compliance_threshold": 48.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Dolorum totam repellendus non.", - "ref_id": "xccdf_org.ssgproject.content_profile_0f294cdc28dfde6e68acb85bee089d95" - }, - { - "id": "52eb5258-e423-4138-8bda-223c7898889c", - "title": "Harum sed consequatur cumque.", - "description": "Molestias officiis praesentium. Aut et voluptas. Tenetur et ratione.", - "business_objective": null, - "compliance_threshold": 50.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Quo possimus temporibus quis.", - "ref_id": "xccdf_org.ssgproject.content_profile_bd42968507dd661c58c974a92bb4a505" - }, - { - "id": "5eb1eef7-b84d-46f6-8a66-81fd9a74c819", - "title": "Amet molestias suscipit eos.", - "description": "Eos sit eligendi. Necessitatibus distinctio error. Debitis id qui.", - "business_objective": null, - "compliance_threshold": 82.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Quae provident aliquid eos.", - "ref_id": "xccdf_org.ssgproject.content_profile_9c170e8a7736e2dc5698ad3c897f1302" - }, - { - "id": "6225dfcb-8182-4e4a-8a6e-f218e63fa342", - "title": "Iure hic et inventore.", - "description": "Tempore eveniet quia. Ex deserunt facilis. Sit dolore odit.", - "business_objective": null, - "compliance_threshold": 88.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Velit quod commodi dolorem.", - "ref_id": "xccdf_org.ssgproject.content_profile_48ee54866283803b04bdaa60b0a483fd" - }, - { - "id": "6457bba8-3fab-4372-95e9-62ed9b54f06a", - "title": "In earum temporibus nulla.", - "description": "Rerum alias mollitia. Similique id ea. Optio aliquam commodi.", - "business_objective": null, - "compliance_threshold": 13.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Consequuntur aut dicta velit.", - "ref_id": "xccdf_org.ssgproject.content_profile_63d15f20d7dafd49220fe6bba561f308" - }, - { - "id": "69f94194-0eb9-485e-9913-910b72928989", - "title": "Nemo consequatur dolore nihil.", - "description": "Consequatur temporibus dicta. Consequuntur facere harum. Corrupti voluptas temporibus.", - "business_objective": null, - "compliance_threshold": 49.0, - "total_system_count": 1, - "type": "policy", - "os_major_version": 7, - "profile_title": "Illum vero sit doloribus.", - "ref_id": "xccdf_org.ssgproject.content_profile_3f1834b2eda537af769a452bb5779eca" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/systems/5090ca71-8bfc-4a20-8038-dd678a7498ad/policies?limit=10&offset=0", - "last": "/api/compliance/v2/systems/5090ca71-8bfc-4a20-8038-dd678a7498ad/policies?limit=10&offset=20", - "next": "/api/compliance/v2/systems/5090ca71-8bfc-4a20-8038-dd678a7498ad/policies?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/policy" - } - } - } - } - } - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/profiles": { - "get": { - "summary": "Request Profiles", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "title:asc", - "title:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Profiles are searchable using attributes `title` and `ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "List all security guide profiles.", - "operationId": "Profiles", - "responses": { - "200": { - "description": "Lists Profiles", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Profiles": { - "value": { - "data": [ - { - "id": "02634e33-878a-4f13-9457-28a61a8eefa2", - "ref_id": "xccdf_org.ssgproject.content_profile_4a52b138f1c8f1fdae876cc3c8f716f4", - "title": "Illum aspernatur dicta aut.", - "description": "Cum iure pariatur. Consequuntur cupiditate eaque. Sed nisi eligendi.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "0ac486e2-b9bf-4fc9-9f10-3335869a3a45", - "ref_id": "xccdf_org.ssgproject.content_profile_d2b0ec443fea7e27438b398a7a6eff3d", - "title": "Aut rerum doloremque est.", - "description": "Expedita dicta similique. Accusantium in impedit. Ipsam magnam hic.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "219c1916-a451-460c-9b16-74095a9eeed1", - "ref_id": "xccdf_org.ssgproject.content_profile_ad9035b7254506ba179e0703a44e8744", - "title": "Et ducimus minus saepe.", - "description": "Qui magnam sed. Nihil rem mollitia. Veritatis deleniti recusandae.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "2f54df73-18c5-40be-beca-d5f2db07bc71", - "ref_id": "xccdf_org.ssgproject.content_profile_8b96ef62861a8943fb1fea9df6461f1a", - "title": "Sit aspernatur est saepe.", - "description": "Fugit voluptatem aperiam. Sit itaque quam. Qui quia molestiae.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "52ab0c0d-3142-49dc-b2a8-566b0ffe6c6b", - "ref_id": "xccdf_org.ssgproject.content_profile_eb871a77a1e948193b236ba1dfffb19f", - "title": "Ad et beatae accusantium.", - "description": "Voluptatem voluptas laborum. Omnis est repellat. Molestias velit accusantium.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "5481fc11-6bfd-4170-b164-ac33f65e018a", - "ref_id": "xccdf_org.ssgproject.content_profile_bedfc52d32d5653741cd02f3634393eb", - "title": "Perferendis et incidunt at.", - "description": "Voluptate eum fugit. Ab alias assumenda. Autem quas numquam.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "58b97ed6-1850-459f-badb-bbb375311f40", - "ref_id": "xccdf_org.ssgproject.content_profile_3381f1ac22b4588db9e7ead2cc5a5530", - "title": "Deserunt assumenda tempora aut.", - "description": "Quas ut est. Maiores ut fugiat. Dolores sit quo.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "67ff27d6-e897-44b6-bea7-db4a31417a2f", - "ref_id": "xccdf_org.ssgproject.content_profile_ef52ac71e7310d6696e4889ebc308f44", - "title": "Quia est eius adipisci.", - "description": "Beatae eius a. Ut fugit facilis. Perspiciatis illum quia.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "740c9d10-b9b3-49ae-8cf3-4f92b6c0ea51", - "ref_id": "xccdf_org.ssgproject.content_profile_e1d8d2268ce32872eb3d1dab34d70cb0", - "title": "Dolorum nihil asperiores dolor.", - "description": "Et consectetur voluptatem. Non illo tenetur. Ut veniam esse.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "7cc7047a-f8f2-4e85-a8d5-8d0138e7dbcb", - "ref_id": "xccdf_org.ssgproject.content_profile_ac12ab0843dd12fe54bd972f895b555a", - "title": "Quo temporibus minima est.", - "description": "Eveniet dignissimos incidunt. Tenetur quia dignissimos. Qui id quia.", - "value_overrides": {}, - "type": "profile" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/0f79628a-f201-486a-96db-434eeab4db5a/profiles?limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/0f79628a-f201-486a-96db-434eeab4db5a/profiles?limit=10&offset=20", - "next": "/api/compliance/v2/security_guides/0f79628a-f201-486a-96db-434eeab4db5a/profiles?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Profiles sorted by \"title:asc\"": { - "value": { - "data": [ - { - "id": "3fd54e05-93f2-426f-8c54-9137f019c5f3", - "ref_id": "xccdf_org.ssgproject.content_profile_77d03e6b6077f69efd8401e0ae0cf438", - "title": "Ab aut nihil dolor.", - "description": "Expedita repudiandae sunt. Soluta tenetur expedita. Tempore ipsa corporis.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "6875cf9f-3a9c-4df7-ab8c-2113a5c7b420", - "ref_id": "xccdf_org.ssgproject.content_profile_5f7435ce6574cedccf72e8ac31f95a15", - "title": "Aut nihil optio iste.", - "description": "Similique modi et. Eum natus quaerat. Est aliquam similique.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "dea801a3-5732-494e-87cf-89c4ce9146a8", - "ref_id": "xccdf_org.ssgproject.content_profile_2153f6275650c0491085b79ea3264e62", - "title": "Deserunt illo natus qui.", - "description": "Impedit repudiandae voluptatibus. In tempora eaque. Voluptatibus libero consequuntur.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "f6820d61-6b0a-44d7-b174-5d3b244d8fd2", - "ref_id": "xccdf_org.ssgproject.content_profile_b70e43a998b924ded89a4e0d3b13e101", - "title": "Dolores doloribus aut labore.", - "description": "Consequatur molestias quis. Porro dolor sed. Et perferendis eius.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "c769a442-b3a2-4440-bc02-c6ee7bfd3aea", - "ref_id": "xccdf_org.ssgproject.content_profile_acc33de1ee26b6dd0b37f29809e89bab", - "title": "Ducimus inventore quod voluptatem.", - "description": "Minima culpa aut. Accusantium nostrum dolorum. Et porro repellendus.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "284a41e4-7305-42e8-b19a-aeef1fca9837", - "ref_id": "xccdf_org.ssgproject.content_profile_bc9c088d630b637b3c6686daff7d267f", - "title": "Enim aut esse accusantium.", - "description": "Corrupti explicabo dicta. Voluptatem minus quis. Est architecto aliquam.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "c6f93562-e43b-4894-ba99-3e6657ae5853", - "ref_id": "xccdf_org.ssgproject.content_profile_611318cefff27e62dabe0725474f0803", - "title": "Facere sunt quasi distinctio.", - "description": "Aut aut quia. Harum quam cupiditate. Beatae non dolore.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "00e6f5cd-2b2c-497b-8c30-57f080e5b19c", - "ref_id": "xccdf_org.ssgproject.content_profile_57e0f518b7df1d6ecb387d666993b4c9", - "title": "Fugiat facere voluptatem nemo.", - "description": "Et labore nemo. Ex officia sequi. Pariatur ducimus fuga.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "8d060097-e439-4aac-9a80-e8257335ede3", - "ref_id": "xccdf_org.ssgproject.content_profile_49c2f661799cca262dbb6a0296beeb22", - "title": "Fugit dignissimos excepturi culpa.", - "description": "Non voluptatem perspiciatis. Dolorum soluta accusamus. Harum tempore dolorem.", - "value_overrides": {}, - "type": "profile" - }, - { - "id": "471c1b53-b2f7-4369-be79-db9642459093", - "ref_id": "xccdf_org.ssgproject.content_profile_0d34aed1333dad59ac05a8729f1a2a62", - "title": "In et dolores vel.", - "description": "Quia nobis natus. Similique saepe non. Numquam maxime laborum.", - "value_overrides": {}, - "type": "profile" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "title" - }, - "links": { - "first": "/api/compliance/v2/security_guides/e998d0ee-9028-43cd-87d3-d6fdd088c6a8/profiles?limit=10&offset=0&sort_by=title", - "last": "/api/compliance/v2/security_guides/e998d0ee-9028-43cd-87d3-d6fdd088c6a8/profiles?limit=10&offset=20&sort_by=title", - "next": "/api/compliance/v2/security_guides/e998d0ee-9028-43cd-87d3-d6fdd088c6a8/profiles?limit=10&offset=10&sort_by=title" - } - }, - "summary": "", - "description": "" - }, - "List of Profiles filtered by '(title=Delectus quia impedit et.)'": { - "value": { - "data": [ - { - "id": "10ecc052-24a2-47f5-ab39-a7c5e020aa73", - "ref_id": "xccdf_org.ssgproject.content_profile_8787f3d5aa9d9e39c4015ffc371a944c", - "title": "Delectus quia impedit et.", - "description": "Laudantium consequuntur qui. Architecto qui fugit. Sapiente impedit odio.", - "value_overrides": {}, - "type": "profile" - } - ], - "meta": { - "total": 1, - "filter": "(title=\"Delectus quia impedit et.\")", - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/a2746af1-2cef-4f8f-a99b-18ac00fff9fb/profiles?filter=%28title%3D%22Delectus+quia+impedit+et.%22%29&limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/a2746af1-2cef-4f8f-a99b-18ac00fff9fb/profiles?filter=%28title%3D%22Delectus+quia+impedit+et.%22%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/profile" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/profiles/{profile_id}": { - "get": { - "summary": "Request a Profile", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "profile_id", - "in": "path", - "required": true, - "description": "UUID or a ref_id with '.' characters replaced with '-'", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a specific profile.", - "operationId": "Profile", - "responses": { - "200": { - "description": "Returns a Profile", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Profile": { - "value": { - "data": { - "id": "85d5e0de-b746-4c50-a630-015f18c1c84b", - "ref_id": "xccdf_org.ssgproject.content_profile_e48b4d97035e52abb08ce63a03ff4485", - "title": "Asperiores est qui assumenda.", - "description": "Saepe enim omnis. Voluptatem molestiae fugit. Modi eius et.", - "value_overrides": {}, - "type": "profile" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/profile" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Profile": { - "value": { - "errors": [ - "V2::Profile not found with ID a7acc7ca-5aff-4952-94a7-209c693d0e83" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/profiles/{profile_id}/rule_tree": { - "get": { - "summary": "Request the Rule Tree of a Profile", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "profile_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Returns the Rule Tree of a Profile", - "operationId": "ProfileTree", - "deprecated": true, - "responses": { - "200": { - "description": "Returns the Rule Tree of a Profile", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns the Rule Tree of a Profile": { - "value": [ - { - "id": "7e9393c8-3a8b-40c6-a929-2f4887457b23", - "type": "rule_group", - "children": [ - { - "id": "da39b210-b097-4c50-a44d-fb6d01863612", - "type": "rule" - } - ] - }, - { - "id": "45fb501e-e228-4d14-ba23-1a40bce4d8b0", - "type": "rule_group", - "children": [ - { - "id": "04825988-9691-4099-b6bd-54eccd7d338d", - "type": "rule" - } - ] - }, - { - "id": "d9fe2525-c6b6-4d57-817b-0456c09ee781", - "type": "rule_group", - "children": [ - { - "id": "6093118b-4308-4a8e-8a08-dc283cef6dce", - "type": "rule" - } - ] - }, - { - "id": "7357b6f7-effe-40c3-9c41-6ad035810477", - "type": "rule_group", - "children": [ - { - "id": "1ed667f3-5c25-42c2-935e-c8a0c046d4a5", - "type": "rule" - } - ] - }, - { - "id": "bbdc225e-f46a-4874-9e7f-6b8a8cddc721", - "type": "rule_group", - "children": [ - { - "id": "aa5c2c3b-953d-4cd2-be35-f33c0afe9fcd", - "type": "rule" - } - ] - }, - { - "id": "c28e7dbf-3ecb-4b5a-a59c-cd4ba2873729", - "type": "rule_group", - "children": [ - { - "id": "1f5a96eb-a2ed-43e8-8416-14f5f49ccb35", - "type": "rule" - } - ] - }, - { - "id": "d26e18a7-2918-43a6-8b25-d2ec3946d268", - "type": "rule_group", - "children": [ - { - "id": "1801298a-9b54-4553-b532-73063c75c951", - "type": "rule" - } - ] - }, - { - "id": "c57b9d6d-c46b-4498-a0db-303595abea07", - "type": "rule_group", - "children": [ - { - "id": "5d96deeb-3369-4d06-9065-77cf45410a60", - "type": "rule" - } - ] - }, - { - "id": "f0777a8e-fbc0-412e-815c-397ebaf3724a", - "type": "rule_group", - "children": [ - { - "id": "2000a8b6-0b24-4b2f-bfee-f6adcb2b1d19", - "type": "rule" - } - ] - }, - { - "id": "4179cd23-8308-4933-954d-00c0362c2b24", - "type": "rule_group", - "children": [ - { - "id": "3ef28b8e-ca2a-46bf-8316-c437904a0c61", - "type": "rule" - } - ] - } - ], - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/rule_tree" - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Profile": { - "value": { - "errors": [ - "V2::Profile not found with ID fd37ca20-4bf6-4d3c-b7be-5ddedfaaf1fc" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/reports": { - "get": { - "summary": "Request Reports", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "os_major_version", - "business_objective", - "compliance_threshold", - "percent_compliant", - "title:asc", - "title:desc", - "os_major_version:asc", - "os_major_version:desc", - "business_objective:asc", - "business_objective:desc", - "compliance_threshold:asc", - "compliance_threshold:desc", - "percent_compliant:asc", - "percent_compliant:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Reports are searchable using attributes `title`, `os_major_version`, `with_reported_systems`, and `percent_compliant`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve a list of all available reports.", - "operationId": "Reports", - "responses": { - "200": { - "description": "Lists Reports", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Reports": { - "value": { - "data": [ - { - "id": "689f537f-2b70-4fb6-b424-b14953c87c48", - "title": "Iste est at tempore.", - "description": "Harum quaerat neque. Dolorem sit qui. Tempore qui praesentium.", - "business_objective": "matrix", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "A aut dolorum id.", - "ref_id": "xccdf_org.ssgproject.content_profile_788fdf94a1646efa05a8c3e03aba5911", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "7b29ef42-a3b9-4c77-94fe-78600f9e5dee", - "title": "Sint sed repellendus fugiat.", - "description": "Expedita sint consequatur. Dolores et tempore. Et distinctio ut.", - "business_objective": "transmitter", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Sed qui et quam.", - "ref_id": "xccdf_org.ssgproject.content_profile_793151f9a5c0f346f17ad1c5f2b68bc5", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "a5eb644c-5186-444b-a610-5010f042398e", - "title": "Mollitia dolores molestiae consequatur.", - "description": "Dicta explicabo id. Ipsam voluptates consequatur. Dolorem dolore totam.", - "business_objective": "port", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Dicta blanditiis cum tempore.", - "ref_id": "xccdf_org.ssgproject.content_profile_c777e7940ded07dac91968f98a117a46", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "a8dd26a4-9ab2-4af0-aa4e-cd92941af447", - "title": "Quo vel nesciunt expedita.", - "description": "Alias vel aliquid. Adipisci nihil consequuntur. Vero nihil quidem.", - "business_objective": "card", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Sunt sapiente occaecati illo.", - "ref_id": "xccdf_org.ssgproject.content_profile_ccc792a7d436513de7e79c04a3ee98c8", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "b733adaf-9a84-40ba-9366-4b1ab497d45f", - "title": "Est maiores est voluptas.", - "description": "Aliquid dolorem aut. Et voluptatem consequatur. Laboriosam eum quisquam.", - "business_objective": "firewall", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Accusamus perferendis aliquid voluptatum.", - "ref_id": "xccdf_org.ssgproject.content_profile_34a697fd9b2da38dffe90cda4131a7f2", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - } - ], - "meta": { - "total": 5, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/reports?limit=10&offset=0", - "last": "/api/compliance/v2/reports?limit=10&offset=0" - } - }, - "summary": "", - "description": "" - }, - "List of Reports sorted by \"os_major_version:asc\"": { - "value": { - "data": [ - { - "id": "551ad74f-aa50-4e14-8b21-24d793a6164c", - "title": "Non et nemo suscipit.", - "description": "Quaerat et et. Reprehenderit voluptatem ab. Et sunt ut.", - "business_objective": "driver", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Harum ducimus molestiae laboriosam.", - "ref_id": "xccdf_org.ssgproject.content_profile_4e630caaabb4e1661654a35b6eb1a067", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "b174983f-6864-4447-8f8b-a7811f5f8db4", - "title": "Rerum et in similique.", - "description": "Dolores optio sunt. Voluptatem et ipsum. Et quod nihil.", - "business_objective": "matrix", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Non enim maxime inventore.", - "ref_id": "xccdf_org.ssgproject.content_profile_49a034de5556425364fc51b85736a177", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "b64fc37e-ccb3-4f71-a500-dadc86d01f89", - "title": "Dicta aperiam consectetur veniam.", - "description": "Et quaerat omnis. Eos occaecati maiores. Maiores unde commodi.", - "business_objective": "monitor", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Sequi sit autem ipsum.", - "ref_id": "xccdf_org.ssgproject.content_profile_2779186bdee8247b917c04f5829b04a1", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "b986f4af-8dcc-49b1-a105-a8815887ad2d", - "title": "Minima error ipsa quidem.", - "description": "Ipsum ab ea. Soluta cupiditate praesentium. Quia quis vero.", - "business_objective": "monitor", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Fugit magni est laudantium.", - "ref_id": "xccdf_org.ssgproject.content_profile_85684217dcaf9ea3696c9308bd428f3e", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - }, - { - "id": "d9073e82-4549-4edb-812f-4040fa3fa585", - "title": "Incidunt unde commodi quae.", - "description": "Est maiores aliquid. Doloremque est nobis. Modi nihil magnam.", - "business_objective": "port", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Omnis qui et ipsam.", - "ref_id": "xccdf_org.ssgproject.content_profile_a34e14a9c5bd4ce4f5f4950e1fbc47d3", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - } - ], - "meta": { - "total": 5, - "limit": 10, - "offset": 0, - "sort_by": "os_major_version" - }, - "links": { - "first": "/api/compliance/v2/reports?limit=10&offset=0&sort_by=os_major_version", - "last": "/api/compliance/v2/reports?limit=10&offset=0&sort_by=os_major_version" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/report" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/reports/os_versions": { - "get": { - "summary": "Request the list of available OS versions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Reports are searchable using attributes `title`, `os_major_version`, `with_reported_systems`, and `percent_compliant`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "This feature is exclusively used by the frontend", - "operationId": "ReportsOS", - "deprecated": true, - "responses": { - "200": { - "description": "Lists available OS versions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of available OS versions": { - "value": [], - "summary": "", - "description": "" - } - }, - "schema": { - "type": "array", - "items": { - "type": "integer" - } - } - } - } - } - } - } - }, - "/reports/{report_id}": { - "get": { - "summary": "Request a Report", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve a specific report.", - "operationId": "Report", - "responses": { - "200": { - "description": "Returns a Report", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Report": { - "value": { - "data": { - "id": "38bd6f12-bb1d-448e-aaa5-6c9f5a822f77", - "title": "Mollitia architecto minus ut.", - "description": "Est explicabo commodi. Enim officia accusantium. Asperiores odit cupiditate.", - "business_objective": "feed", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 9, - "profile_title": "Dolores in atque voluptatem.", - "ref_id": "xccdf_org.ssgproject.content_profile_da6c3791047f4d8546ba1f2574bd5cda", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/report" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Report": { - "value": { - "errors": [ - "V2::Report not found with ID 47d35ae2-582a-42d4-b797-d5a30b6c0afd" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "delete": { - "summary": "Delete a Report results", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Delete test results for a specific report.", - "operationId": "DeleteReport", - "responses": { - "202": { - "description": "Deletes Report's test results", - "content": { - "application/vnd.api+json": { - "examples": { - "Deletes Report's test results": { - "value": { - "data": { - "id": "5f74ce7c-9961-486a-84cb-30a77e5bcc72", - "title": "Aut non sed quisquam.", - "description": "Voluptas ut velit. Officiis veritatis minima. Eum id est.", - "business_objective": "pixel", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 9, - "profile_title": "Adipisci autem sequi distinctio.", - "ref_id": "xccdf_org.ssgproject.content_profile_c396a88fb792eecbe95fd47f837fc4b8", - "all_systems_exposed": true, - "percent_compliant": 25, - "assigned_system_count": 4, - "compliant_system_count": 1, - "unsupported_system_count": 2, - "reported_system_count": 4 - } - }, - "summary": "", - "description": "" - } - } - } - } - } - } - } - }, - "/reports/{report_id}/stats": { - "get": { - "summary": "Request detailed stats for a Report", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Returns detailed stats for a Report", - "deprecated": true, - "operationId": "ReportStats", - "responses": { - "200": { - "description": "Returns detailed stats for a Report", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns detailed stats for a Report": { - "value": { - "top_failed_rules": [] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/report_stats" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Report": { - "value": { - "errors": [ - "V2::Report not found with ID 5fb02438-cea6-4057-96ef-0b1b875be20f" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/systems/{system_id}/reports": { - "get": { - "summary": "Request Reports", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "business_objective", - "compliance_threshold", - "percent_compliant", - "title:asc", - "title:desc", - "business_objective:asc", - "business_objective:desc", - "compliance_threshold:asc", - "compliance_threshold:desc", - "percent_compliant:asc", - "percent_compliant:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Reports are searchable using attributes `title`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "system_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve a list of reports for a specific system.", - "operationId": "SystemReports", - "responses": { - "200": { - "description": "Lists Reports", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Reports": { - "value": { - "data": [ - { - "id": "4c83b4a6-4d05-4dd6-994b-6980b3c46742", - "title": "Aut quis voluptatem asperiores.", - "description": "Et animi et. Quis dolor quos. Et possimus veniam.", - "business_objective": "program", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Vel nesciunt nemo maxime.", - "ref_id": "xccdf_org.ssgproject.content_profile_a9b71fe53e25afadef9176748478d64c", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "6627d125-0e9b-4e13-93a9-e53c67d464e5", - "title": "Libero quis dicta rerum.", - "description": "Et ratione amet. Assumenda molestias cupiditate. Ea quas et.", - "business_objective": "card", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Cupiditate est velit dolor.", - "ref_id": "xccdf_org.ssgproject.content_profile_5a2c7bc0a9b8d1f38edaebd2f1234faf", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "8a7ce129-473e-40d6-9498-3cdea9e01afc", - "title": "Beatae voluptatem quae voluptatem.", - "description": "Error est earum. Magni consequuntur quasi. Ab cum odit.", - "business_objective": "hard drive", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Odit nihil vitae dolores.", - "ref_id": "xccdf_org.ssgproject.content_profile_9079743385a167ba5a5cfd00e10f06ef", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "9aac9b71-c889-4a42-b5a2-11a178c7de64", - "title": "Eligendi ipsum perferendis facere.", - "description": "Officiis ea ducimus. Itaque excepturi aut. Modi itaque esse.", - "business_objective": "port", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "A iure aliquam eligendi.", - "ref_id": "xccdf_org.ssgproject.content_profile_1bf275d1badf0c69bce3296d2ac60443", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "a757e1cc-0b61-4dec-b974-e1c41384d19c", - "title": "A alias ipsam voluptatibus.", - "description": "Nam possimus consequatur. Ut culpa sit. Eos vel rerum.", - "business_objective": "pixel", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Voluptatibus sint est qui.", - "ref_id": "xccdf_org.ssgproject.content_profile_5cb3f27f7f1808c2af93ef2f9853da6f", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - } - ], - "meta": { - "total": 5, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/systems/6cf60085-1cbc-40ff-9265-e480cd952996/reports?limit=10&offset=0", - "last": "/api/compliance/v2/systems/6cf60085-1cbc-40ff-9265-e480cd952996/reports?limit=10&offset=0" - } - }, - "summary": "", - "description": "" - }, - "List of Reports sorted by \"title:asc\"": { - "value": { - "data": [ - { - "id": "869b4ff8-3eb2-46d9-ab72-1c7bd0ecc7ad", - "title": "Est omnis aut qui.", - "description": "Amet eligendi soluta. Et ut harum. Velit aut eveniet.", - "business_objective": "interface", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Provident aut est sequi.", - "ref_id": "xccdf_org.ssgproject.content_profile_9332b32e7c492853f280cd491162a07d", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "d95ad1f5-10d2-4f06-ba0d-75570f8cc1c3", - "title": "Et repudiandae itaque qui.", - "description": "Accusantium eveniet suscipit. Autem maiores accusamus. Ipsam consequatur perferendis.", - "business_objective": "hard drive", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Reiciendis in qui molestias.", - "ref_id": "xccdf_org.ssgproject.content_profile_5ffdb3a99006a9fe6f70285ed5eaf306", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "4a246d7c-6db1-44b4-b87a-1e3914a28540", - "title": "Excepturi aliquam consequatur ut.", - "description": "Vel sunt enim. Voluptatem numquam quisquam. Tempora culpa iure.", - "business_objective": "port", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Voluptatum in reiciendis sit.", - "ref_id": "xccdf_org.ssgproject.content_profile_b6efda8fbefdc8ac1a8a552e1f7c6fb8", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "38b2ac69-cd70-4596-9561-e9251b5e33b8", - "title": "Hic labore provident minus.", - "description": "Qui quos vel. Consequatur harum aliquam. Non corrupti est.", - "business_objective": "capacitor", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Molestiae aliquam sapiente consectetur.", - "ref_id": "xccdf_org.ssgproject.content_profile_5e5e0c0d25d85124367733cce26c2f3f", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - }, - { - "id": "12fb16e5-05f6-4bda-906c-808a888d7886", - "title": "Laborum quia suscipit illum.", - "description": "Qui vel tempore. Similique facilis et. Laboriosam et cum.", - "business_objective": "firewall", - "compliance_threshold": 90.0, - "type": "report", - "os_major_version": 8, - "profile_title": "Rerum earum natus aperiam.", - "ref_id": "xccdf_org.ssgproject.content_profile_3bbe2ba1e232ffccaec18c35e9cfe6a1", - "all_systems_exposed": false, - "percent_compliant": 0, - "compliant_system_count": 0, - "unsupported_system_count": 0, - "reported_system_count": 0 - } - ], - "meta": { - "total": 5, - "limit": 10, - "offset": 0, - "sort_by": "title" - }, - "links": { - "first": "/api/compliance/v2/systems/5102cb2d-d069-44e7-8251-855b920a8bd2/reports?limit=10&offset=0&sort_by=title", - "last": "/api/compliance/v2/systems/5102cb2d-d069-44e7-8251-855b920a8bd2/reports?limit=10&offset=0&sort_by=title" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/report" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/rule_groups": { - "get": { - "summary": "Request Rule Groups", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "precedence", - "precedence:asc", - "precedence:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Rule Groups are searchable using attributes `title` and `ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "List all rules groups.", - "operationId": "RuleGroups", - "responses": { - "200": { - "description": "Lists Rule Groups", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Rule Groups": { - "value": { - "data": [ - { - "id": "1b2164b8-ec27-4236-a38c-f4d51998b723", - "ref_id": "xccdf_org.ssgproject.content_rule_group_59be0d41b47d1136741d752fc94a3d44", - "title": "Aut et vero omnis.", - "rationale": "In nisi aut. Aut nisi et. Sequi asperiores et.", - "description": "Fugit vel veritatis. Itaque ut minima. Distinctio nulla ratione.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "20cbda89-4b05-416b-991c-25efa37f2a0c", - "ref_id": "xccdf_org.ssgproject.content_rule_group_540ff7d72090d4846cb08abcab1bd868", - "title": "Qui voluptatem autem itaque.", - "rationale": "Aliquam quisquam et. Exercitationem ipsa harum. Pariatur accusantium velit.", - "description": "Quasi et aspernatur. Corrupti quas vel. Iste et similique.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "23f8847e-bb56-409b-9107-fabe069d1f71", - "ref_id": "xccdf_org.ssgproject.content_rule_group_e189363ae27e385578d39c1d98ac3331", - "title": "Rerum odio aut est.", - "rationale": "Sint qui incidunt. Omnis rem voluptatem. Maiores officia voluptas.", - "description": "Sapiente natus id. Cum nisi unde. Modi officia non.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "2a5106ae-0c92-43d0-a3d0-993ea28588d3", - "ref_id": "xccdf_org.ssgproject.content_rule_group_413a345b52f3224588828ecdaa96f8bb", - "title": "Qui explicabo ut optio.", - "rationale": "Deserunt velit et. Quia quia ex. Enim occaecati eum.", - "description": "Placeat earum nihil. Ratione provident fugit. Sit beatae inventore.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "360a37d2-ccde-4f8e-b06f-6842ffc34460", - "ref_id": "xccdf_org.ssgproject.content_rule_group_65671dc89b0af9f53324b16ea166f3fb", - "title": "Sit omnis reiciendis quas.", - "rationale": "Et ratione et. Ad at sint. Veritatis laborum accusamus.", - "description": "Voluptatem facilis molestiae. Porro quod ullam. Voluptas enim est.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "3e21189e-5d48-4c78-ba13-f7808506f427", - "ref_id": "xccdf_org.ssgproject.content_rule_group_547ec032f53af80334ffb43a6ef1c630", - "title": "Placeat nemo eligendi praesentium.", - "rationale": "Dignissimos consequatur sit. Ut non in. Temporibus ipsa et.", - "description": "Ipsum quia non. Doloremque aut ut. Neque omnis eum.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "4a16c40c-0b08-45a0-82a2-458e65350430", - "ref_id": "xccdf_org.ssgproject.content_rule_group_f55b8c912247602c2efc3ee5ecbdf132", - "title": "Ab magni illum est.", - "rationale": "Ducimus quod non. Quibusdam adipisci non. Molestiae culpa aut.", - "description": "Quia velit beatae. Porro voluptatibus eum. Accusantium consequatur iste.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "5505ce06-2fd8-4c2a-b47f-9de4a889841e", - "ref_id": "xccdf_org.ssgproject.content_rule_group_4c39accb08fd734e1aa7372b0a2b97c9", - "title": "Reprehenderit quibusdam et numquam.", - "rationale": "Voluptate consequuntur molestiae. Aspernatur impedit quasi. Magni deserunt est.", - "description": "Eius molestiae asperiores. Reiciendis fuga earum. Molestias ipsam autem.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "60f58260-3459-4d23-80ba-ff1dd7c25333", - "ref_id": "xccdf_org.ssgproject.content_rule_group_af51287ced2b22f2cefe78d69a632e1b", - "title": "Culpa repellendus magni ut.", - "rationale": "Quo error ad. Et quis necessitatibus. Libero iste ut.", - "description": "Rerum aliquid ut. Illum vero quasi. Qui sed eius.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "62ae6b16-e27e-4f61-9585-369f62d689a2", - "ref_id": "xccdf_org.ssgproject.content_rule_group_0063552e83bd5ac920e03ce8f1cc50eb", - "title": "Quo laborum nihil itaque.", - "rationale": "Est dolores pariatur. Blanditiis necessitatibus voluptas. Doloribus maxime ut.", - "description": "Et qui libero. Expedita odit mollitia. Quia consequuntur perspiciatis.", - "precedence": null, - "type": "rule_group" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/07d639b2-4a92-42c5-b93a-93ddec69901e/rule_groups?limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/07d639b2-4a92-42c5-b93a-93ddec69901e/rule_groups?limit=10&offset=20", - "next": "/api/compliance/v2/security_guides/07d639b2-4a92-42c5-b93a-93ddec69901e/rule_groups?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Rule Groups sorted by \"precedence:asc\"": { - "value": { - "data": [ - { - "id": "117fe26b-b27a-43fb-9899-ec5faae878b8", - "ref_id": "xccdf_org.ssgproject.content_rule_group_b06cdee9d27b366e4615add6f24c89a6", - "title": "Cum reprehenderit dicta voluptatem.", - "rationale": "Aut libero et. Corporis placeat cupiditate. Ipsa magnam impedit.", - "description": "Et non pariatur. Mollitia a officiis. Est labore ut.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "1a1c66c2-1c77-4280-b40f-a1d41677c3f8", - "ref_id": "xccdf_org.ssgproject.content_rule_group_8ed28885d296b3b613ebd1c7c03fe6be", - "title": "Quia blanditiis asperiores quod.", - "rationale": "Excepturi molestiae soluta. Accusantium vero quibusdam. Voluptatibus tempore sit.", - "description": "Alias rerum temporibus. Quia dignissimos iste. Ullam facere minus.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "2174490b-f330-4973-83a0-f68b751af2a1", - "ref_id": "xccdf_org.ssgproject.content_rule_group_87ba8da18c70949b11b9de52c3c64a67", - "title": "Suscipit repellat esse ea.", - "rationale": "Sit molestiae fuga. Blanditiis vitae aliquid. Cum sunt aut.", - "description": "Maxime consequuntur consequatur. Atque neque ea. Quibusdam et sit.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "22d49f93-a569-47bf-b3b5-90da3d94e2fd", - "ref_id": "xccdf_org.ssgproject.content_rule_group_43911dc60cf1b32af9153320f0517b09", - "title": "Corrupti distinctio illum ea.", - "rationale": "Quos iure deserunt. Ut deleniti voluptas. Accusamus excepturi in.", - "description": "Incidunt aliquid autem. Nobis sit deleniti. Ullam veritatis assumenda.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "24485846-871a-4fd9-a3e4-fa82ea5e31e1", - "ref_id": "xccdf_org.ssgproject.content_rule_group_f459c30ca66ae97b5fab8e6a319d54a7", - "title": "Perferendis quidem sed ratione.", - "rationale": "Voluptatem assumenda animi. Est dolor quia. Sed qui suscipit.", - "description": "Temporibus quasi debitis. Rerum dolorem beatae. Dolores qui perspiciatis.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "3aa26f33-f16d-428b-8d10-bb21f941f87b", - "ref_id": "xccdf_org.ssgproject.content_rule_group_00b903c7cff7ddf99670462f73ada563", - "title": "Quis harum veniam tenetur.", - "rationale": "Laudantium dolorum hic. Assumenda amet doloribus. Est quis mollitia.", - "description": "Modi quia vitae. Natus quam in. Natus explicabo rem.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "40449fe5-5204-4959-ba82-cd132e247dff", - "ref_id": "xccdf_org.ssgproject.content_rule_group_4e3d9a95a7222315d4eafd4fe5854c46", - "title": "Voluptas architecto facere mollitia.", - "rationale": "Veniam nostrum minima. Quia quia eos. Facere porro mollitia.", - "description": "Harum beatae quo. Quasi voluptatem sed. Et sint pariatur.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "42af0545-7125-4d00-86c1-6e45c6eacb6d", - "ref_id": "xccdf_org.ssgproject.content_rule_group_fc5febdb02d5db2446f2d223dd0d7245", - "title": "Iusto quia beatae sapiente.", - "rationale": "Eaque dicta et. Inventore voluptatibus animi. Et quas nesciunt.", - "description": "Dolores voluptas dolores. Voluptatem dolorem iusto. Sit ut voluptatem.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "48614537-8441-41e9-8769-07882af202a5", - "ref_id": "xccdf_org.ssgproject.content_rule_group_5031ce9ec31d8580fd136d2e6f0f05a8", - "title": "Unde nam consequatur ut.", - "rationale": "Ipsum tenetur ex. Est doloribus similique. Quod ducimus et.", - "description": "Voluptatibus fugit et. Neque fugiat et. Qui fugit a.", - "precedence": null, - "type": "rule_group" - }, - { - "id": "4a84fa35-c0e4-435f-ab15-37bdcc3eb96c", - "ref_id": "xccdf_org.ssgproject.content_rule_group_67ce0875341b5edd959ddb68e48e7391", - "title": "Itaque expedita fuga nihil.", - "rationale": "Voluptates ullam soluta. Et explicabo quidem. Fugit consectetur quasi.", - "description": "Molestiae et aperiam. Unde vel ducimus. Fugit perspiciatis voluptatem.", - "precedence": null, - "type": "rule_group" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "precedence" - }, - "links": { - "first": "/api/compliance/v2/security_guides/565da504-b36b-4e3a-826e-8946b1d33588/rule_groups?limit=10&offset=0&sort_by=precedence", - "last": "/api/compliance/v2/security_guides/565da504-b36b-4e3a-826e-8946b1d33588/rule_groups?limit=10&offset=20&sort_by=precedence", - "next": "/api/compliance/v2/security_guides/565da504-b36b-4e3a-826e-8946b1d33588/rule_groups?limit=10&offset=10&sort_by=precedence" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/rule_group" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/rule_groups/{rule_group_id}": { - "get": { - "summary": "Request a Rule Group", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "rule_group_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a specific rule group.", - "operationId": "RuleGroup", - "responses": { - "200": { - "description": "Returns a Rule Group", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Rule Group": { - "value": { - "data": { - "id": "d4e0f85d-7e96-42f3-a812-32f9f664e17e", - "ref_id": "xccdf_org.ssgproject.content_rule_group_2dd9a9aa7d4d18476dcacfa7dcaf70ba", - "title": "Odio porro amet reiciendis.", - "rationale": "Consequatur aliquam facilis. Assumenda possimus corrupti. A tenetur optio.", - "description": "Ut ipsum veniam. Facere fugiat non. Facilis officiis excepturi.", - "precedence": null, - "type": "rule_group" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/rule_group" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Rule Group": { - "value": { - "errors": [ - "V2::RuleGroup not found with ID cd2259ff-3d67-4a09-9669-d23470d1c305" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/reports/{report_id}/test_results/{test_result_id}/rule_results": { - "get": { - "summary": "Request Rule Results under a Report", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "result", - "severity", - "title", - "precedence", - "remediation_available", - "result:asc", - "result:desc", - "severity:asc", - "severity:desc", - "title:asc", - "title:desc", - "precedence:asc", - "precedence:desc", - "remediation_available:asc", - "remediation_available:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Rule Results are searchable using attributes `result`, `title`, `severity`, and `rule_group_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "test_result_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve all of the rule results for a specific report.", - "operationId": "ReportRuleResults", - "responses": { - "200": { - "description": "Lists Rule Results under a Report", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Rule Results": { - "value": { - "data": [ - { - "id": "ffd28ef6-ad41-49b0-9492-0d4705acd1bd", - "result": "fail", - "rule_id": "efb91e1f-23e3-4013-b2d2-50b18318a6e3", - "type": "rule_result", - "system_id": "edfca2a0-197b-42a5-b093-32f36fa1706a", - "ref_id": "xccdf_org.ssgproject.content_rule_f3de9d1e4293348dd90d4752f9b2d501", - "rule_group_id": "7f6a285f-0bea-4052-a4b6-4cd71915cba4", - "title": "Dolorem iusto doloremque iste.", - "rationale": "Enim quia voluptas. Atque voluptas eum. Nemo qui et.", - "description": "Quasi ipsum delectus. Sed veritatis minima. Reprehenderit ratione blanditiis.", - "severity": "medium", - "precedence": 6445, - "identifier": { - "href": "http://weber-considine.example/irene", - "label": "Gerda Boffin" - }, - "references": [ - { - "href": "http://moore-wolff.test/dorian", - "label": "Meneldor" - }, - { - "href": "http://gibson.test/caroline", - "label": "Eofor" - }, - { - "href": "http://rowe-rice.example/angel.mckenzie", - "label": "Mimosa Bunce" - }, - { - "href": "http://white.example/dorsey", - "label": "Telchar" - }, - { - "href": "http://keebler.test/branden", - "label": "Gamil Zirak" - } - ], - "remediation_issue_id": null - } - ], - "meta": { - "total": 1, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/reports/12aa91eb-0e82-439c-a68f-0f444bda9748/test_results/29fb6038-c614-4e4e-ba29-b3d3003aa520/rule_results?limit=10&offset=0", - "last": "/api/compliance/v2/reports/12aa91eb-0e82-439c-a68f-0f444bda9748/test_results/29fb6038-c614-4e4e-ba29-b3d3003aa520/rule_results?limit=10&offset=0" - } - }, - "summary": "", - "description": "" - }, - "List of Rule Results sorted by \"result:asc\"": { - "value": { - "data": [ - { - "id": "3a815034-34c0-43ee-ba31-e98abc290f83", - "result": "fail", - "rule_id": "ea34901e-6760-48a9-84af-ac33dc132aa4", - "type": "rule_result", - "system_id": "3ec556b5-0c40-4b72-84f0-4860c7604c47", - "ref_id": "xccdf_org.ssgproject.content_rule_d76114d47c8d44fb959cc848b6904cbb", - "rule_group_id": "ffca9704-1b7a-4862-9ac7-2de7023b7ce6", - "title": "Officiis aperiam et qui.", - "rationale": "Fugiat pariatur doloremque. Dolor et sunt. Impedit veritatis delectus.", - "description": "Pariatur rem eum. Repudiandae unde ratione. Suscipit qui est.", - "severity": "medium", - "precedence": 6798, - "identifier": { - "href": "http://herzog.example/stefanie", - "label": "Adamanta Chubb" - }, - "references": [ - { - "href": "http://spencer.test/bryant.braun", - "label": "Camellia Sackville" - }, - { - "href": "http://koch-schaefer.test/adrien", - "label": "Hending" - }, - { - "href": "http://greenholt-hirthe.example/coretta_hoeger", - "label": "Gróin" - }, - { - "href": "http://kuhic.example/aurelio.schamberger", - "label": "Amarië" - }, - { - "href": "http://marquardt-halvorson.example/romona", - "label": "Fastolph Bolger" - } - ], - "remediation_issue_id": null - } - ], - "meta": { - "total": 1, - "limit": 10, - "offset": 0, - "sort_by": "result" - }, - "links": { - "first": "/api/compliance/v2/reports/6da3756e-be0d-4153-908c-ea454fb4b5d0/test_results/8cea3417-6541-4d59-afcc-3b69434366fc/rule_results?limit=10&offset=0&sort_by=result", - "last": "/api/compliance/v2/reports/6da3756e-be0d-4153-908c-ea454fb4b5d0/test_results/8cea3417-6541-4d59-afcc-3b69434366fc/rule_results?limit=10&offset=0&sort_by=result" - } - }, - "summary": "", - "description": "" - }, - "List of Rule Results filtered by \"(title=foo)\"": { - "value": { - "data": [], - "meta": { - "total": 0, - "filter": "(title=foo)", - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/reports/06720f81-984f-4a57-87d9-d505e72424d4/test_results/e769c553-4598-4712-8092-029429941fc0/rule_results?filter=%28title%3Dfoo%29&limit=10&offset=0", - "last": "/api/compliance/v2/reports/06720f81-984f-4a57-87d9-d505e72424d4/test_results/e769c553-4598-4712-8092-029429941fc0/rule_results?filter=%28title%3Dfoo%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/rule_result" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/rules": { - "get": { - "summary": "Request Rules", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "severity", - "precedence", - "remediation_available", - "title:asc", - "title:desc", - "severity:asc", - "severity:desc", - "precedence:asc", - "precedence:desc", - "remediation_available:asc", - "remediation_available:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Rules are searchable using attributes `title`, `severity`, `remediation_available`, and `rule_group_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a list of rules for a specific security guide.", - "operationId": "Rules", - "responses": { - "200": { - "description": "Lists Rules", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Rules": { - "value": { - "data": [ - { - "id": "006f105f-15a9-48ee-9db2-90fd0edf5576", - "ref_id": "xccdf_org.ssgproject.content_rule_8d76bcaec9d91b082ccf61c07645cbad", - "title": "Qui est error voluptatum.", - "rationale": "Porro harum rem. Ipsum atque qui. Aut ea sed.", - "description": "Consequatur sit sed. Et velit consequatur. Accusamus ea sint.", - "severity": "high", - "precedence": 7491, - "identifier": { - "href": "http://heathcote.example/art", - "label": "Smaug" - }, - "references": [ - { - "href": "http://morissette.test/alysha_collier", - "label": "Mrs. Maggot" - }, - { - "href": "http://ortiz.example/ronny", - "label": "Nellas" - }, - { - "href": "http://langosh.example/hallie_ferry", - "label": "Tolman Cotton Junior" - }, - { - "href": "http://abernathy-pollich.example/gennie.upton", - "label": "Lorgan" - }, - { - "href": "http://hand.example/necole", - "label": "Ivy Goodenough" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "8dc76775-c664-405d-9769-87623d43b810", - "type": "rule" - }, - { - "id": "027fe419-efc8-436a-931c-2c4fef9133c5", - "ref_id": "xccdf_org.ssgproject.content_rule_c58f9f78660c2d75140e25f565129ee0", - "title": "Qui quis quisquam ad.", - "rationale": "Temporibus nulla mollitia. Facilis qui quas. Reprehenderit tempore nesciunt.", - "description": "Culpa voluptatum voluptatem. Quasi impedit officia. Ut et ratione.", - "severity": "high", - "precedence": 7851, - "identifier": { - "href": "http://wunsch.example/colby", - "label": "Saradas Brandybuck" - }, - "references": [ - { - "href": "http://rempel-breitenberg.example/zoila", - "label": "Targon" - }, - { - "href": "http://morissette-rosenbaum.test/tia", - "label": "Baldor" - }, - { - "href": "http://leuschke.test/claris.runte", - "label": "Egalmoth" - }, - { - "href": "http://schneider.example/parker.schowalter", - "label": "Daisy Gamgee" - }, - { - "href": "http://gerlach-ernser.example/ernest", - "label": "Ohtar" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "6d4d655b-c0c8-4503-8e8e-df5882595c34", - "type": "rule" - }, - { - "id": "039514bb-2d89-4d5e-8b04-13350dd8a575", - "ref_id": "xccdf_org.ssgproject.content_rule_9790f96ec88c5400e3a023e4002665cc", - "title": "Voluptate occaecati autem iure.", - "rationale": "Mollitia dolorem distinctio. Quae velit quo. Quia impedit harum.", - "description": "Eius dolore ipsam. Dolores facilis aspernatur. Ea officia natus.", - "severity": "low", - "precedence": 6339, - "identifier": { - "href": "http://morar.example/lorene_lubowitz", - "label": "Rudolph Bolger" - }, - "references": [ - { - "href": "http://leuschke.test/ambrose_gutmann", - "label": "Elfwine" - }, - { - "href": "http://donnelly-hudson.example/ricky", - "label": "Anardil" - }, - { - "href": "http://welch.example/vanessa_gutkowski", - "label": "Bregor" - }, - { - "href": "http://franecki.test/julissa", - "label": "Tar-Meneldur" - }, - { - "href": "http://johns.example/german.toy", - "label": "Guthláf" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "c0c1b7eb-d2c7-4b4a-8f0e-902ae6aaff34", - "type": "rule" - }, - { - "id": "153e1432-a654-47c0-b844-75df7cae7e30", - "ref_id": "xccdf_org.ssgproject.content_rule_dfc28edac7ca17bf60edf58b6ea88815", - "title": "Eum suscipit et praesentium.", - "rationale": "Accusamus sunt ipsum. Ut odio repudiandae. A ratione temporibus.", - "description": "Earum est non. Aut porro aut. Sit animi et.", - "severity": "low", - "precedence": 1107, - "identifier": { - "href": "http://schamberger.example/oswaldo", - "label": "Huan" - }, - "references": [ - { - "href": "http://wilderman.example/vernie", - "label": "Gundahar Bolger" - }, - { - "href": "http://leannon-dach.test/anjelica", - "label": "Amandil" - }, - { - "href": "http://friesen-beer.example/maribel", - "label": "Aldamir" - }, - { - "href": "http://stamm-greenholt.example/taylor", - "label": "Thorin Stonehelm" - }, - { - "href": "http://oconner.test/brent", - "label": "Elanor Gardner" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "0463f755-7e79-4cc2-aaf5-1fe24fe148da", - "type": "rule" - }, - { - "id": "1d0e58f2-2ef2-43fe-bd2b-c4cb8b89c42f", - "ref_id": "xccdf_org.ssgproject.content_rule_1ad607bb23bada40ff4385fee8b00560", - "title": "Quis corporis nobis quo.", - "rationale": "Aliquid labore occaecati. Optio est delectus. Repudiandae sint tempora.", - "description": "Minima nobis sunt. Inventore ad eius. Sit minus voluptatum.", - "severity": "low", - "precedence": 3178, - "identifier": { - "href": "http://lowe.test/denver.romaguera", - "label": "Quennar" - }, - "references": [ - { - "href": "http://simonis-medhurst.example/jaime_donnelly", - "label": "Hallatan" - }, - { - "href": "http://brekke-pollich.test/myron.altenwerth", - "label": "Great Eagle" - }, - { - "href": "http://jones.test/carmen.yost", - "label": "Cora Goodbody" - }, - { - "href": "http://schmidt.test/alena_ernser", - "label": "Bungo Baggins" - }, - { - "href": "http://hahn.test/graham.mclaughlin", - "label": "Ceorl" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "ef5795e1-ecd0-4bab-ac74-314215ae35a1", - "type": "rule" - }, - { - "id": "3737ed0a-5d1e-4caf-be54-4ff8a40528cf", - "ref_id": "xccdf_org.ssgproject.content_rule_4f11ca515e61b1a0535c681cea4ab153", - "title": "Corporis provident sit enim.", - "rationale": "Dolores expedita quo. Quasi consequatur dolorum. Non ex eaque.", - "description": "Non laboriosam nemo. Quisquam cum autem. Aut minus excepturi.", - "severity": "high", - "precedence": 4661, - "identifier": { - "href": "http://abshire.test/kelley.crona", - "label": "Tolman Gardner" - }, - "references": [ - { - "href": "http://konopelski-feest.example/louise", - "label": "Elrohir" - }, - { - "href": "http://roberts.test/kathy", - "label": "Myrtle Burrows" - }, - { - "href": "http://leuschke.test/fredric", - "label": "Saeros" - }, - { - "href": "http://morissette-bins.test/mohammad", - "label": "Baragund" - }, - { - "href": "http://torp-dickens.example/jarred", - "label": "Primrose Boffin" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "d1806777-0082-4047-9934-e68af8bb44dd", - "type": "rule" - }, - { - "id": "3d314f56-6316-4d68-96e0-2d0f941a687e", - "ref_id": "xccdf_org.ssgproject.content_rule_96dca6822eb7f15774b5d95fe44a4d83", - "title": "Ad atque reiciendis quia.", - "rationale": "Et nihil saepe. Dolor veniam iure. Debitis dolorem officiis.", - "description": "Adipisci totam soluta. Voluptates id possimus. Ipsa quis optio.", - "severity": "medium", - "precedence": 3142, - "identifier": { - "href": "http://stark.example/alan.vandervort", - "label": "Gimli" - }, - "references": [ - { - "href": "http://hudson.test/vaughn_hermiston", - "label": "Halfast Gamgee" - }, - { - "href": "http://nader.test/kami.stroman", - "label": "Sangahyando" - }, - { - "href": "http://daniel.test/santiago_lang", - "label": "Briffo Boffin" - }, - { - "href": "http://brekke.test/teodoro", - "label": "Grór" - }, - { - "href": "http://harvey.test/jasper", - "label": "Peony Baggins" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "f0f5cd15-ea13-4540-abc7-0ac614cd5295", - "type": "rule" - }, - { - "id": "4dfd00c7-8283-4731-9be9-abe32acca1d6", - "ref_id": "xccdf_org.ssgproject.content_rule_d42fe1cfff51deba9068db0b0facf4fa", - "title": "Reprehenderit eum eaque ut.", - "rationale": "Voluptas quisquam aliquam. Nulla similique modi. Porro hic molestiae.", - "description": "Beatae officiis occaecati. Aperiam magnam debitis. In voluptas aut.", - "severity": "medium", - "precedence": 5046, - "identifier": { - "href": "http://adams.example/ellis", - "label": "Merry Gardner" - }, - "references": [ - { - "href": "http://lesch-rutherford.example/jerrold_wolf", - "label": "Minto Burrows" - }, - { - "href": "http://heathcote.test/miguel.volkman", - "label": "Ar-Adûnakhôr" - }, - { - "href": "http://boyle-koepp.test/cleo_langosh", - "label": "Wilcome" - }, - { - "href": "http://mckenzie-pollich.test/naomi_crona", - "label": "Frerin" - }, - { - "href": "http://runolfsdottir-dach.example/terrance.rogahn", - "label": "Filibert Bolger" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "9bd47fe2-7dcf-4bc9-981b-8139761cc502", - "type": "rule" - }, - { - "id": "4f74dd42-22d9-45b5-bbde-d405f077d671", - "ref_id": "xccdf_org.ssgproject.content_rule_87f55760f7238a970caa8b6dbfcd9297", - "title": "Sit vitae alias in.", - "rationale": "Facere alias totam. Itaque cupiditate consequatur. Aut suscipit cumque.", - "description": "Eveniet sit sunt. Facere dolorum vel. Non cum voluptate.", - "severity": "high", - "precedence": 8722, - "identifier": { - "href": "http://littel.example/faustino.windler", - "label": "Imin" - }, - "references": [ - { - "href": "http://kozey.example/yong", - "label": "Angamaitë" - }, - { - "href": "http://hettinger.test/lettie", - "label": "Nessanië" - }, - { - "href": "http://steuber-weber.test/wally", - "label": "Ivriniel" - }, - { - "href": "http://franecki-paucek.example/juliann", - "label": "Eldacar" - }, - { - "href": "http://kris-leffler.test/walker", - "label": "Axantur" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "a0d6e8be-c2f4-48f0-8f52-01abf5879823", - "type": "rule" - }, - { - "id": "4fd11ab8-9615-4f2f-8fbc-8a34583d1f14", - "ref_id": "xccdf_org.ssgproject.content_rule_9777b86ce8baae13c4aa6b3776039692", - "title": "Eveniet quam veniam quia.", - "rationale": "Est alias possimus. Ut corporis sit. Voluptas consequatur aut.", - "description": "Autem voluptatem neque. Error fugiat ea. Incidunt voluptatem saepe.", - "severity": "medium", - "precedence": 8550, - "identifier": { - "href": "http://gibson.example/tyler", - "label": "Dís" - }, - "references": [ - { - "href": "http://heaney.example/zackary", - "label": "Poppy Chubb-Baggins" - }, - { - "href": "http://reichel-breitenberg.example/kristeen", - "label": "Nolondil" - }, - { - "href": "http://romaguera-bogan.example/trey", - "label": "Mentha Brandybuck" - }, - { - "href": "http://kohler.example/gita_rowe", - "label": "Skinbark" - }, - { - "href": "http://kassulke.test/earleen", - "label": "Celegorm" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "8e2ad9ce-5578-44ab-a63b-3ef6d84ee488", - "type": "rule" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/ca8b1af1-6c64-45a8-aa64-6ca137582424/rules?limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/ca8b1af1-6c64-45a8-aa64-6ca137582424/rules?limit=10&offset=20", - "next": "/api/compliance/v2/security_guides/ca8b1af1-6c64-45a8-aa64-6ca137582424/rules?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Rules sorted by \"precedence:asc\"": { - "value": { - "data": [ - { - "id": "85cc9ecc-6c73-4411-b807-d7a236e2d0a2", - "ref_id": "xccdf_org.ssgproject.content_rule_c61b4d0770dfecbc55bc97fc8f33d5cc", - "title": "Ducimus aut repellendus voluptas.", - "rationale": "Mollitia ut ad. In soluta enim. Consequatur voluptas magnam.", - "description": "Omnis assumenda cupiditate. Ex dolor laboriosam. Perferendis fugit harum.", - "severity": "low", - "precedence": 42, - "identifier": { - "href": "http://will.example/adella.flatley", - "label": "Haldad" - }, - "references": [ - { - "href": "http://daugherty-schulist.example/dwain.stiedemann", - "label": "Fundin" - }, - { - "href": "http://ernser-berge.example/micheal", - "label": "Hunthor" - }, - { - "href": "http://block.example/willis.heaney", - "label": "Angrim" - }, - { - "href": "http://murazik.test/marica.nicolas", - "label": "Targon" - }, - { - "href": "http://mills.example/rickie", - "label": "Frodo Gardner" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "fb382d3f-837f-4561-9ba3-53ea2c68a9c7", - "type": "rule" - }, - { - "id": "2f38d117-b1c0-4e1b-939f-f9a0d65e940f", - "ref_id": "xccdf_org.ssgproject.content_rule_6f74b2027b80adf9d6da1fcfd82e3603", - "title": "In fugiat quia et.", - "rationale": "Quo est autem. Sed sit in. Quisquam distinctio reprehenderit.", - "description": "Ratione iure ut. Non voluptatem enim. Exercitationem cumque aut.", - "severity": "high", - "precedence": 257, - "identifier": { - "href": "http://stamm-moore.test/esteban_howell", - "label": "Asphodel Brandybuck" - }, - "references": [ - { - "href": "http://spinka.test/leonardo.feil", - "label": "Erling" - }, - { - "href": "http://thompson.example/ai", - "label": "Turambar" - }, - { - "href": "http://bartell-thiel.test/galen", - "label": "Bandobras Took" - }, - { - "href": "http://price-lang.example/karisa.stiedemann", - "label": "Beleth" - }, - { - "href": "http://schultz.example/rocco.schaefer", - "label": "Brandir" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "5b67effe-be0e-4f82-86e4-a0a8653fb8b7", - "type": "rule" - }, - { - "id": "c3265315-a6dd-4cbc-9803-b50fe55d42de", - "ref_id": "xccdf_org.ssgproject.content_rule_e65b8fa2b2a980deacf7d668d402c386", - "title": "Maiores autem ad corrupti.", - "rationale": "Dicta a quasi. Ex sunt ad. Sapiente quis voluptas.", - "description": "Reprehenderit in soluta. Ab ut rerum. Dolores ut voluptas.", - "severity": "high", - "precedence": 446, - "identifier": { - "href": "http://grimes.example/fernande_aufderhar", - "label": "Togo Goodbody" - }, - "references": [ - { - "href": "http://doyle.example/bradley", - "label": "Nob" - }, - { - "href": "http://witting.example/bebe", - "label": "Hirwen" - }, - { - "href": "http://bauch.test/margareta", - "label": "Nazgûl" - }, - { - "href": "http://dickinson-nolan.test/geoffrey_gutkowski", - "label": "Saruman" - }, - { - "href": "http://johnston-waters.test/kenneth_leuschke", - "label": "Chica Chubb" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "3bb25a4c-4741-47b9-adf6-abe6416e890a", - "type": "rule" - }, - { - "id": "929c7c70-f9ba-4674-8857-40b02e616c23", - "ref_id": "xccdf_org.ssgproject.content_rule_9f766ed99ab7bb1ca79a8c6fa3ec7c0b", - "title": "Voluptas atque nulla rem.", - "rationale": "Velit consectetur eius. Esse eius facere. Ut mollitia est.", - "description": "Maiores soluta perspiciatis. Aut nulla optio. Accusantium perferendis asperiores.", - "severity": "high", - "precedence": 449, - "identifier": { - "href": "http://schimmel-jacobson.test/hipolito_kulas", - "label": "Erling" - }, - "references": [ - { - "href": "http://kuhlman.test/elly", - "label": "Amandil" - }, - { - "href": "http://corkery.test/charles.schimmel", - "label": "Elendur" - }, - { - "href": "http://torp-oconnell.example/hubert.rowe", - "label": "Wulf" - }, - { - "href": "http://champlin.example/reyes", - "label": "Merimas Brandybuck" - }, - { - "href": "http://maggio-marvin.test/porfirio.ziemann", - "label": "Indor" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "2a91cf2f-b989-476e-bb23-561f850f5675", - "type": "rule" - }, - { - "id": "d9c63555-8942-4ad7-944f-51bca531acc5", - "ref_id": "xccdf_org.ssgproject.content_rule_833c9ea6e12d400f1b3641809f07d291", - "title": "Soluta quibusdam ut consequuntur.", - "rationale": "Ut vel quae. Ducimus quasi est. Nulla a consequatur.", - "description": "Aut nam quisquam. Maiores numquam debitis. Consequatur natus doloribus.", - "severity": "high", - "precedence": 689, - "identifier": { - "href": "http://runte.test/chastity", - "label": "Isengar Took" - }, - "references": [ - { - "href": "http://schuster-gottlieb.test/doria", - "label": "Elboron" - }, - { - "href": "http://kozey-fritsch.example/merle", - "label": "Gilly Brownlock" - }, - { - "href": "http://pfannerstill.example/sherlyn", - "label": "Peeping Jack" - }, - { - "href": "http://pagac-hegmann.test/reynalda", - "label": "Imrazôr" - }, - { - "href": "http://goyette.test/trista", - "label": "Elfhelm" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "e3fd10fe-eea6-452f-8b41-4d7218742df7", - "type": "rule" - }, - { - "id": "974e3b26-e6b7-42af-9fa5-ecb0fe68e2c6", - "ref_id": "xccdf_org.ssgproject.content_rule_607fbdfa5e8651be38d76922e467b486", - "title": "Non nesciunt est omnis.", - "rationale": "Ratione ab corporis. Aliquam quisquam provident. Pariatur eos in.", - "description": "Velit exercitationem magni. Et ut qui. Aut quisquam sunt.", - "severity": "high", - "precedence": 1800, - "identifier": { - "href": "http://krajcik.test/mariella_douglas", - "label": "Otto Boffin" - }, - "references": [ - { - "href": "http://kris.example/abigail", - "label": "Lindir" - }, - { - "href": "http://frami.example/charlyn.predovic", - "label": "Brego" - }, - { - "href": "http://kertzmann.test/bryanna_goyette", - "label": "Hallas" - }, - { - "href": "http://bernier.test/devin", - "label": "Mosco Burrows" - }, - { - "href": "http://hackett-marquardt.example/clemente", - "label": "Meriadoc Brandybuck" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "3fad9291-4194-45bb-807a-3752e44d6960", - "type": "rule" - }, - { - "id": "5bea4533-657e-4839-87d5-cddf3dc12545", - "ref_id": "xccdf_org.ssgproject.content_rule_6a7f03c08c3bfe103c7ef85e00fbfdb1", - "title": "Ab voluptas ut nulla.", - "rationale": "Illum ut soluta. Quos sed placeat. Recusandae delectus expedita.", - "description": "Quis rerum ut. Id voluptatem ullam. Omnis porro nihil.", - "severity": "medium", - "precedence": 1803, - "identifier": { - "href": "http://leuschke.example/lauryn.nitzsche", - "label": "Wulf" - }, - "references": [ - { - "href": "http://fadel.example/cletus", - "label": "Hallacar" - }, - { - "href": "http://treutel.test/lazaro", - "label": "Nazgûl" - }, - { - "href": "http://zemlak.example/joaquin.schmeler", - "label": "Haldar" - }, - { - "href": "http://berge-haag.test/evia.feeney", - "label": "Ferumbras Took" - }, - { - "href": "http://wilkinson.test/gidget", - "label": "Folcwine" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "ccafbec6-a8de-430d-b2be-7d479cc47c43", - "type": "rule" - }, - { - "id": "12d25aa7-517f-4fb1-b057-2d40b33dde9c", - "ref_id": "xccdf_org.ssgproject.content_rule_76776beca77d82abf43f9cc093d4702d", - "title": "Beatae qui nisi deserunt.", - "rationale": "Aut dolorum voluptate. Facere reprehenderit et. Aspernatur quod minima.", - "description": "Tempore suscipit consequuntur. Officiis ipsum excepturi. Provident suscipit fugit.", - "severity": "low", - "precedence": 2087, - "identifier": { - "href": "http://fahey-mills.example/leonel", - "label": "Aravorn" - }, - "references": [ - { - "href": "http://huel-abbott.example/vance_rolfson", - "label": "Primrose Gardner" - }, - { - "href": "http://schmeler-mante.example/georgann.king", - "label": "Dírhael" - }, - { - "href": "http://kiehn.example/joaquin", - "label": "Poldor" - }, - { - "href": "http://jaskolski-mckenzie.example/adolfo_greenfelder", - "label": "Eärendil" - }, - { - "href": "http://connelly.test/ginny", - "label": "Mallor" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "9d72c0fe-1fcb-48bc-ada6-81d399d687fc", - "type": "rule" - }, - { - "id": "3a423c63-4521-45bd-867c-00b1b6136e94", - "ref_id": "xccdf_org.ssgproject.content_rule_42c2783ee503bd662bf3c2030fa944b3", - "title": "Quisquam sed eveniet ipsum.", - "rationale": "Autem et ab. Quos possimus numquam. Saepe beatae eum.", - "description": "Dolorum saepe impedit. Quas sed reprehenderit. Sed rem nesciunt.", - "severity": "low", - "precedence": 2429, - "identifier": { - "href": "http://dickinson.example/mohamed_langosh", - "label": "Náli" - }, - "references": [ - { - "href": "http://gerlach-heidenreich.example/oswaldo.swift", - "label": "Daisy Gardner" - }, - { - "href": "http://kuhic.test/darron.zieme", - "label": "Lóni" - }, - { - "href": "http://mertz-herman.test/brooke_herzog", - "label": "Nina Lightfoot" - }, - { - "href": "http://legros-lubowitz.example/terry", - "label": "Sador" - }, - { - "href": "http://stiedemann-lang.test/sharen", - "label": "Tar-Atanamir" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "3d921f2e-3791-4f7c-b105-713e95b3a593", - "type": "rule" - }, - { - "id": "2f630791-6d44-4ae9-81b3-c362635caf6b", - "ref_id": "xccdf_org.ssgproject.content_rule_0339ab79c154679056a4529e6f4671d2", - "title": "Velit adipisci et nam.", - "rationale": "Neque consequatur numquam. Dolor ab eum. Odio ipsum qui.", - "description": "Exercitationem ea qui. Ullam vitae et. Molestiae ut corrupti.", - "severity": "high", - "precedence": 2605, - "identifier": { - "href": "http://dibbert.test/kum", - "label": "Tar-Ancalimë" - }, - "references": [ - { - "href": "http://paucek-kutch.example/angela.rohan", - "label": "Vidumavi" - }, - { - "href": "http://turner-rippin.example/ramon", - "label": "Isumbras" - }, - { - "href": "http://runolfsdottir-gutmann.test/noelle.marquardt", - "label": "Poppy Chubb-Baggins" - }, - { - "href": "http://kohler.test/george_luettgen", - "label": "Ondoher" - }, - { - "href": "http://cruickshank-runte.example/gilberto", - "label": "Ardamir" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "aaa374a2-2a09-4a39-b77c-6b9c660fe571", - "type": "rule" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "precedence" - }, - "links": { - "first": "/api/compliance/v2/security_guides/d06948c3-94fb-49a9-ad1c-2ccdfbb257f7/rules?limit=10&offset=0&sort_by=precedence", - "last": "/api/compliance/v2/security_guides/d06948c3-94fb-49a9-ad1c-2ccdfbb257f7/rules?limit=10&offset=20&sort_by=precedence", - "next": "/api/compliance/v2/security_guides/d06948c3-94fb-49a9-ad1c-2ccdfbb257f7/rules?limit=10&offset=10&sort_by=precedence" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/rule" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/rules/{rule_id}": { - "get": { - "summary": "Request a Rule", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "rule_id", - "in": "path", - "required": true, - "description": "UUID or a ref_id with '.' characters replaced with '-'", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a specific rule from a specific security guide.", - "operationId": "Rule", - "responses": { - "200": { - "description": "Returns a Rule", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Rule": { - "value": { - "data": { - "id": "5b086919-9045-4dcf-b515-3a35a512060d", - "ref_id": "xccdf_org.ssgproject.content_rule_ffe10e40dc6f8d0b6194675f51053976", - "title": "Similique repellendus velit quidem.", - "rationale": "Explicabo ea consequatur. Quia est nihil. Reiciendis qui tempora.", - "description": "Qui esse ut. Aut dolorem similique. Autem sint sed.", - "severity": "low", - "precedence": 8296, - "identifier": { - "href": "http://champlin-predovic.example/granville", - "label": "Tosto Boffin" - }, - "references": [ - { - "href": "http://skiles-funk.example/dong", - "label": "Hunthor" - }, - { - "href": "http://lindgren.example/jaquelyn.farrell", - "label": "Eldacar" - }, - { - "href": "http://green.example/elmer.oconnell", - "label": "Almáriel" - }, - { - "href": "http://aufderhar.test/barney", - "label": "Dís" - }, - { - "href": "http://roob.test/sade", - "label": "Finduilas" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "fe2c02e1-d4af-43fd-b8a6-386f6438c977", - "type": "rule" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/rule" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Rule": { - "value": { - "errors": [ - "V2::Rule not found with ID 0c49fd1b-2e2a-48b1-a477-0a52c9473de1" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/profiles/{profile_id}/rules": { - "get": { - "summary": "Request Rules assigned to a Profile", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "severity", - "precedence", - "remediation_available", - "title:asc", - "title:desc", - "severity:asc", - "severity:desc", - "precedence:asc", - "precedence:desc", - "remediation_available:asc", - "remediation_available:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Rules are searchable using attributes `title`, `severity`, `remediation_available`, and `rule_group_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "profile_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a list of all security guide rules for a specific profile.", - "operationId": "ProfileRules", - "responses": { - "200": { - "description": "Lists Rules assigned to a Profile", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Rules": { - "value": { - "data": [ - { - "id": "039e6979-ebb1-4efa-88a1-0dedacbc110a", - "ref_id": "xccdf_org.ssgproject.content_rule_ecc7dd07460bf751c056e0cb662c07a2", - "title": "Temporibus fuga corporis impedit.", - "rationale": "Minus ut quasi. Eum quod quo. Dolor assumenda et.", - "description": "Fuga sed consequatur. Rerum quis deserunt. Aliquam eum architecto.", - "severity": "medium", - "precedence": 2679, - "identifier": { - "href": "http://nader.example/florene", - "label": "Cora Goodbody" - }, - "references": [ - { - "href": "http://glover.test/bill_kertzmann", - "label": "Amdír" - }, - { - "href": "http://olson-larson.test/asha", - "label": "Guilin" - }, - { - "href": "http://schroeder-wiza.example/rosette", - "label": "Ibun" - }, - { - "href": "http://sipes.example/christia_monahan", - "label": "Hardang" - }, - { - "href": "http://ruecker.test/luther.stehr", - "label": "Adalbert Bolger" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "882f5c7e-9e08-4f34-8e4b-d2a0950a7ed7", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "27678b80-1095-490c-b2b3-33623c8a3561", - "ref_id": "xccdf_org.ssgproject.content_rule_255f09f55c4f64b367f3f5b86819617a", - "title": "Magni voluptatem quibusdam aliquid.", - "rationale": "Nemo eligendi eum. Nihil praesentium unde. Facere pariatur veniam.", - "description": "At culpa provident. Quas deserunt rerum. Et porro nostrum.", - "severity": "medium", - "precedence": 8546, - "identifier": { - "href": "http://mayert.test/anh.farrell", - "label": "Ebor" - }, - "references": [ - { - "href": "http://dach-kovacek.test/jeanene_runolfsson", - "label": "Finwë" - }, - { - "href": "http://smith-kihn.test/carita.stehr", - "label": "Ivorwen" - }, - { - "href": "http://romaguera.example/adrianne.hills", - "label": "Olo Proudfoot" - }, - { - "href": "http://klein-shanahan.example/rory.wilderman", - "label": "Vorondil" - }, - { - "href": "http://oreilly.example/marlon", - "label": "Radbug" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "3536a3a6-3fb6-4855-ae63-9b673e403e35", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "2a9b6f35-7092-438c-ba36-bed492f7fd0c", - "ref_id": "xccdf_org.ssgproject.content_rule_61b0ea963a378ba5b291bff2713cc6b0", - "title": "Tempora deserunt minima mollitia.", - "rationale": "Repudiandae ipsa quia. Veniam magnam et. Odit incidunt sed.", - "description": "Inventore vel voluptatem. Qui in velit. Iusto nulla itaque.", - "severity": "medium", - "precedence": 8710, - "identifier": { - "href": "http://howell.example/trenton", - "label": "Belegund" - }, - "references": [ - { - "href": "http://donnelly.test/dimple_crona", - "label": "Salvia Brandybuck" - }, - { - "href": "http://lindgren.example/delana.huel", - "label": "Polo Baggins" - }, - { - "href": "http://hills-mertz.example/hester_ullrich", - "label": "Éothéod" - }, - { - "href": "http://ullrich-kessler.example/kasey.murphy", - "label": "Belemir" - }, - { - "href": "http://gutkowski.test/shellie.gottlieb", - "label": "Wiseman Gamwich" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "24e1e6f2-a037-4974-b67d-39881f02ed96", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "2bc5f14f-8a54-4b89-b417-ed979cea46b6", - "ref_id": "xccdf_org.ssgproject.content_rule_976e7b0632ae2ee7ffb765dc1b356617", - "title": "Qui recusandae sunt quisquam.", - "rationale": "Magni eum quis. Sint sint omnis. Iste exercitationem et.", - "description": "Ut voluptate et. Vel illum quia. Quis porro provident.", - "severity": "high", - "precedence": 7865, - "identifier": { - "href": "http://koelpin-terry.test/ulrike", - "label": "Dúnhere" - }, - "references": [ - { - "href": "http://stoltenberg.example/geneva", - "label": "Dís" - }, - { - "href": "http://schroeder.test/cecilia", - "label": "Aravir" - }, - { - "href": "http://erdman.example/lacey", - "label": "Ulbar" - }, - { - "href": "http://block.example/shonda_bednar", - "label": "Bowman Cotton" - }, - { - "href": "http://mayer.example/alex", - "label": "Eärendil" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "5d33afcc-71cd-480b-b9ed-1a24d9e0e637", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "2ffe7f90-dd27-4de6-bd2d-04ccf138e012", - "ref_id": "xccdf_org.ssgproject.content_rule_7dca3d418413402982ed59a9ac96bf40", - "title": "Quis nisi consequatur placeat.", - "rationale": "Culpa eligendi aut. Mollitia id eum. Ut inventore dolore.", - "description": "Quidem dolores odio. Inventore pariatur non. Veniam ut sit.", - "severity": "low", - "precedence": 6044, - "identifier": { - "href": "http://mckenzie.test/elanor", - "label": "Bregolas" - }, - "references": [ - { - "href": "http://hayes.example/rafaela_leuschke", - "label": "Walda" - }, - { - "href": "http://bosco.example/nicolle.mcdermott", - "label": "Erkenbrand" - }, - { - "href": "http://weissnat.example/branda.tillman", - "label": "Soronto" - }, - { - "href": "http://leuschke.test/jack", - "label": "Grimbold" - }, - { - "href": "http://bins.test/weldon", - "label": "Eluréd" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "14af3d52-5baf-4730-b2e8-22467a2df5fa", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "376d5204-7533-41db-9910-50701de50dfc", - "ref_id": "xccdf_org.ssgproject.content_rule_e09e9a59b000bb0d6c3fb7f229e9de83", - "title": "Iste quaerat et aut.", - "rationale": "Repudiandae similique non. Consequatur qui dolor. Quia maxime repellendus.", - "description": "Voluptates odio autem. Aspernatur voluptatem repellendus. Ea non et.", - "severity": "medium", - "precedence": 4847, - "identifier": { - "href": "http://heathcote-williamson.test/maximo", - "label": "Nazgûl" - }, - "references": [ - { - "href": "http://murazik.example/horacio.stanton", - "label": "Ungoliant" - }, - { - "href": "http://smith-kunde.example/claudio.wuckert", - "label": "Bifur" - }, - { - "href": "http://collins-collins.test/clarita", - "label": "Glóredhel" - }, - { - "href": "http://schinner-dubuque.example/chad", - "label": "Soronto" - }, - { - "href": "http://bogisich.test/marlon", - "label": "Magor" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "ef6686ec-c274-41fc-94d8-2ad55ac7b773", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "37da77a2-f4ff-4505-aa1b-27d095480308", - "ref_id": "xccdf_org.ssgproject.content_rule_c9cbc3a549215ec61ede3740f9919d24", - "title": "Cupiditate quaerat deleniti quod.", - "rationale": "Accusantium qui sunt. Nihil odio esse. Minima dolorem fugit.", - "description": "Aut ea ipsam. Amet ut veritatis. Nesciunt qui explicabo.", - "severity": "medium", - "precedence": 2908, - "identifier": { - "href": "http://fadel.example/erik_trantow", - "label": "Bill Ferny" - }, - "references": [ - { - "href": "http://ratke.test/evan", - "label": "Hildigard Took" - }, - { - "href": "http://sauer-howell.test/miguel", - "label": "Nina Lightfoot" - }, - { - "href": "http://altenwerth.example/lieselotte_hodkiewicz", - "label": "Voronwë" - }, - { - "href": "http://huel-bernhard.example/prudence", - "label": "Borthand" - }, - { - "href": "http://padberg.test/latarsha", - "label": "Zimrahin" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "8aa7c763-ebf1-4302-88a9-a903b340a6c9", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "587dbd14-952d-4399-acee-0340f838499b", - "ref_id": "xccdf_org.ssgproject.content_rule_eb1fd246499b86652ab0692931cc5ac4", - "title": "Ad omnis et sint.", - "rationale": "Optio ut laboriosam. Dicta eos voluptas. Aut quo dolore.", - "description": "Magnam ex corrupti. Consequatur deserunt in. Eum ab est.", - "severity": "high", - "precedence": 4212, - "identifier": { - "href": "http://bernier.test/daisy_bechtelar", - "label": "Farin" - }, - "references": [ - { - "href": "http://hauck.example/brendon_nitzsche", - "label": "Dírhael" - }, - { - "href": "http://emard.example/natashia_oconnell", - "label": "Daisy Baggins" - }, - { - "href": "http://bruen.test/carla.haag", - "label": "Éothain" - }, - { - "href": "http://brakus-collier.example/jacquelyne", - "label": "Ornendil" - }, - { - "href": "http://ankunding.test/danette", - "label": "Eöl" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "20988eac-3c47-4a01-bf67-54f6990c0416", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "5c3a04c7-eb8a-4d4e-a41b-2cbcae42262a", - "ref_id": "xccdf_org.ssgproject.content_rule_321fe7106b50e2e15cfac22a9ad78166", - "title": "Quos corporis iste expedita.", - "rationale": "At reiciendis explicabo. Vel dicta iure. Commodi animi quia.", - "description": "Ea est vitae. Iure recusandae dolor. Placeat ut et.", - "severity": "medium", - "precedence": 2814, - "identifier": { - "href": "http://boyle.example/van", - "label": "Chica Chubb" - }, - "references": [ - { - "href": "http://schaden.test/harry", - "label": "Witch-king" - }, - { - "href": "http://bahringer.example/adella_kautzer", - "label": "Erling" - }, - { - "href": "http://willms.test/emory.bashirian", - "label": "Barach" - }, - { - "href": "http://ortiz.test/charisse", - "label": "Eärnil" - }, - { - "href": "http://ondricka-bins.example/kellee", - "label": "Nár" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "fa04fef4-3374-442b-b395-01f50ab0cd7b", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "6b6bb222-334e-4dc4-bd8e-f42571698ad3", - "ref_id": "xccdf_org.ssgproject.content_rule_d022c5a511f702e24afcc18dc90d5fbd", - "title": "Officia vel aliquid et.", - "rationale": "Vero itaque ipsa. Consequuntur consequatur aperiam. Neque doloribus cumque.", - "description": "Perferendis asperiores quia. Laboriosam incidunt consectetur. Rerum blanditiis quia.", - "severity": "low", - "precedence": 4782, - "identifier": { - "href": "http://trantow-klocko.test/saul.conroy", - "label": "Dagnir" - }, - "references": [ - { - "href": "http://swift.example/jerry", - "label": "Ruby Bolger" - }, - { - "href": "http://schimmel.example/lewis.rippin", - "label": "Amrothos" - }, - { - "href": "http://emard.test/juan", - "label": "Arador" - }, - { - "href": "http://murray-marquardt.test/minna", - "label": "Írimë" - }, - { - "href": "http://carter.example/harry", - "label": "Tar-Telperiën" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "cc965289-fb4c-4a1a-81c2-4358c976db19", - "type": "rule", - "remediation_issue_id": null - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/04b5c8d4-2f95-4285-92c4-a69e249fa05e/profiles/de795edd-73d8-4dde-9e8b-c925a3e8f203/rules?limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/04b5c8d4-2f95-4285-92c4-a69e249fa05e/profiles/de795edd-73d8-4dde-9e8b-c925a3e8f203/rules?limit=10&offset=20", - "next": "/api/compliance/v2/security_guides/04b5c8d4-2f95-4285-92c4-a69e249fa05e/profiles/de795edd-73d8-4dde-9e8b-c925a3e8f203/rules?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Rules sorted by \"precedence:asc\"": { - "value": { - "data": [ - { - "id": "40c12d9c-607d-446a-ad20-6122a6e278b8", - "ref_id": "xccdf_org.ssgproject.content_rule_6da422958aa4c62ddd43f47c9f5ac2ea", - "title": "Et dolores voluptatibus facere.", - "rationale": "Ipsa maiores eveniet. Rerum porro ullam. Ut et rem.", - "description": "Exercitationem explicabo voluptas. Libero reiciendis a. Veritatis nihil perferendis.", - "severity": "high", - "precedence": 654, - "identifier": { - "href": "http://oberbrunner.test/boyd", - "label": "Fram" - }, - "references": [ - { - "href": "http://huels-walter.example/odis.becker", - "label": "Landroval" - }, - { - "href": "http://wuckert.example/guadalupe", - "label": "Bandobras Took" - }, - { - "href": "http://schowalter.test/sanford.fisher", - "label": "Bolg" - }, - { - "href": "http://hills-rath.test/anastasia", - "label": "Melilot Brandybuck" - }, - { - "href": "http://von.example/bridgette.hansen", - "label": "Gundolpho Bolger" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "1caba462-a4f9-4d13-8bee-02fe2739b15b", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "37d3a23b-4096-4362-bfb8-179b0d29dcb2", - "ref_id": "xccdf_org.ssgproject.content_rule_998fb878c5978a1b923220c85220f515", - "title": "Adipisci quasi nihil aliquid.", - "rationale": "Excepturi id amet. Dolorem est labore. Molestiae in id.", - "description": "Voluptates quam amet. Harum et quia. Doloribus ab quisquam.", - "severity": "low", - "precedence": 756, - "identifier": { - "href": "http://pfannerstill.example/victor", - "label": "Finduilas" - }, - "references": [ - { - "href": "http://hirthe.example/rolanda_gorczany", - "label": "Eglantine Banks" - }, - { - "href": "http://lind.test/myles", - "label": "Cemendur" - }, - { - "href": "http://glover-sauer.test/mellisa_towne", - "label": "Iago Grubb" - }, - { - "href": "http://ritchie.example/philip.renner", - "label": "Fëanor" - }, - { - "href": "http://boyer.example/sherron_sporer", - "label": "Folcwine" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "9ae8e4a5-bd78-4a2b-b3ca-fbe035876cfd", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "2ca29178-3610-4a43-87c7-27542360f316", - "ref_id": "xccdf_org.ssgproject.content_rule_59df190a5e645bc55c7a71e26c6fd5c0", - "title": "Non corrupti nemo commodi.", - "rationale": "Soluta et voluptatem. Ratione sed et. Est rerum fuga.", - "description": "Aut aut inventore. Voluptatem tempora aut. Commodi non at.", - "severity": "high", - "precedence": 1552, - "identifier": { - "href": "http://prohaska.example/kathe_kemmer", - "label": "Moro Burrows" - }, - "references": [ - { - "href": "http://oconner.example/aliza", - "label": "Elendil" - }, - { - "href": "http://raynor-roberts.example/elliott.baumbach", - "label": "Dáin" - }, - { - "href": "http://effertz-fritsch.test/kelly_mayert", - "label": "Gildor" - }, - { - "href": "http://wehner.example/shantae_kilback", - "label": "Yávien" - }, - { - "href": "http://wisoky-crona.example/ezra", - "label": "Adamanta Chubb" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "568051b9-a310-46f0-8945-74cb6d5501a7", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "a7db8787-7e35-4bbf-9639-aba32442ff0b", - "ref_id": "xccdf_org.ssgproject.content_rule_42a71bc1318e2e81ac38f7cff2e83fdb", - "title": "Possimus consequuntur quos et.", - "rationale": "Facilis molestias est. Nihil ducimus aut. Et perferendis aut.", - "description": "Enim architecto sequi. Consequuntur voluptas voluptate. Dolorem non sapiente.", - "severity": "low", - "precedence": 2265, - "identifier": { - "href": "http://hudson.test/lanelle.feil", - "label": "Aravir" - }, - "references": [ - { - "href": "http://vandervort.example/marlon.emard", - "label": "Rowlie Appledore" - }, - { - "href": "http://mayer.example/tressie.denesik", - "label": "Dinodas Brandybuck" - }, - { - "href": "http://anderson.test/edith", - "label": "Elfstan Fairbairn" - }, - { - "href": "http://klocko-wisoky.test/solomon_robel", - "label": "Draugluin" - }, - { - "href": "http://denesik.example/leonard.armstrong", - "label": "Pott the Mayor" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "5af63cea-3204-482f-8927-2a9f8fc1c6a2", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "625554d5-fae7-494a-9a74-050959e237d1", - "ref_id": "xccdf_org.ssgproject.content_rule_f897b00fcae539d5a1430b38d8675fc7", - "title": "Culpa et ipsum accusantium.", - "rationale": "Animi facere id. Alias dolorem itaque. Velit dolor fuga.", - "description": "Quia ut qui. Numquam quo itaque. Dolor provident totam.", - "severity": "high", - "precedence": 2553, - "identifier": { - "href": "http://bergstrom-paucek.test/danita.sipes", - "label": "Poppy Chubb-Baggins" - }, - "references": [ - { - "href": "http://okuneva.test/billie", - "label": "Duilin" - }, - { - "href": "http://larkin-jakubowski.test/deshawn.abernathy", - "label": "Marach" - }, - { - "href": "http://stoltenberg.example/lavonne.mann", - "label": "Gilraen" - }, - { - "href": "http://rippin.example/willow.nitzsche", - "label": "Dorlas" - }, - { - "href": "http://blick.example/annamarie", - "label": "Aerin" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "0a12ce67-ae0a-41b4-9f55-8caef05969f7", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "a98c1f55-6a15-4688-b4a4-1b5e4a3e3713", - "ref_id": "xccdf_org.ssgproject.content_rule_168b4f854904100bc9892475691643ac", - "title": "Explicabo ad ducimus rem.", - "rationale": "Exercitationem necessitatibus corrupti. Enim similique odio. Vel voluptatibus et.", - "description": "Sed nemo aliquid. Velit quis dolor. Et velit dolor.", - "severity": "medium", - "precedence": 2827, - "identifier": { - "href": "http://tromp-koelpin.example/roselyn", - "label": "Avranc" - }, - "references": [ - { - "href": "http://ankunding-emmerich.test/nickolas", - "label": "Witch-king" - }, - { - "href": "http://schamberger-jacobson.example/deane", - "label": "Caliondo" - }, - { - "href": "http://gottlieb-hand.test/zack", - "label": "Pimpernel Took" - }, - { - "href": "http://mcclure.test/olivia", - "label": "Balin" - }, - { - "href": "http://harris-mertz.example/donnie.hermann", - "label": "Theobald Bolger" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "a0297f9e-5acd-433d-95f5-9fec0616fd8e", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "9c3de1f8-0491-417f-87ae-248bf54508ac", - "ref_id": "xccdf_org.ssgproject.content_rule_7eae8731e79186caef0718c03d3bcbf7", - "title": "Tempora praesentium facere sit.", - "rationale": "Repudiandae ex ea. Optio fugiat nobis. Corrupti perspiciatis quisquam.", - "description": "Labore rerum sed. Et inventore voluptatibus. Eaque nostrum temporibus.", - "severity": "low", - "precedence": 2934, - "identifier": { - "href": "http://jacobson-schumm.test/lesley_heidenreich", - "label": "Baldor" - }, - "references": [ - { - "href": "http://bauch-hammes.example/bea", - "label": "Déor" - }, - { - "href": "http://mitchell-torphy.example/roger", - "label": "Ragnir" - }, - { - "href": "http://hudson.test/irena", - "label": "Bodo Proudfoot" - }, - { - "href": "http://runolfsson-hermiston.example/page", - "label": "Madoc Brandybuck" - }, - { - "href": "http://tromp.test/nettie_schiller", - "label": "Goldilocks Gardner" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "2593b9dd-8712-49f3-9252-24ee16b9b9b9", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "362ac6dc-807c-4174-9416-b1e6bc044f24", - "ref_id": "xccdf_org.ssgproject.content_rule_ef2193e951fcf79946ea8095939ed5d8", - "title": "Earum blanditiis illo enim.", - "rationale": "Est quidem reprehenderit. Vitae distinctio esse. Beatae optio repudiandae.", - "description": "Eum fugiat ex. Labore illum et. Et quisquam cum.", - "severity": "medium", - "precedence": 3145, - "identifier": { - "href": "http://ohara.example/amos", - "label": "Hirwen" - }, - "references": [ - { - "href": "http://batz.test/earl.fahey", - "label": "Celeborn" - }, - { - "href": "http://stark.test/jesica", - "label": "Gollum" - }, - { - "href": "http://rutherford-keebler.test/judith.schoen", - "label": "Estella Bolger" - }, - { - "href": "http://cruickshank.test/charleen", - "label": "Huor" - }, - { - "href": "http://gorczany-maggio.example/christian", - "label": "Merry Gardner" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "55ff5b54-68a5-4021-b6fc-5fe56b315748", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "8ef84698-1ca3-40c4-996d-d6e8671cbc75", - "ref_id": "xccdf_org.ssgproject.content_rule_1880df384dd9c20c2c92239a2703a1ee", - "title": "Aperiam autem repellendus aut.", - "rationale": "Eveniet dolorem nihil. Nam tenetur omnis. Alias quisquam ut.", - "description": "Id omnis dolores. Cum et eligendi. Voluptatem rem praesentium.", - "severity": "medium", - "precedence": 3543, - "identifier": { - "href": "http://daugherty-beer.test/edmund_howe", - "label": "Elendur" - }, - "references": [ - { - "href": "http://bruen.test/jerold_stroman", - "label": "Ebor" - }, - { - "href": "http://reinger-medhurst.test/mireya_okeefe", - "label": "Mithrellas" - }, - { - "href": "http://stiedemann.test/esta.marvin", - "label": "Gruffo Boffin" - }, - { - "href": "http://runolfsson-konopelski.test/mendy_fritsch", - "label": "Peony Baggins" - }, - { - "href": "http://nader-cartwright.example/ike.hudson", - "label": "Mahtan" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "24a5c05a-98d0-4130-9610-6956639b1093", - "type": "rule", - "remediation_issue_id": null - }, - { - "id": "7bdbc7f8-7c0c-4f6a-ab5d-a801e93917d5", - "ref_id": "xccdf_org.ssgproject.content_rule_24d93c2c13d6f56a2a065a7c62dcf551", - "title": "Eos corporis voluptatem aspernatur.", - "rationale": "Ratione dolor quis. Aut mollitia est. Quam iure accusantium.", - "description": "Ducimus asperiores nobis. Sint fugiat et. Et est rem.", - "severity": "high", - "precedence": 3883, - "identifier": { - "href": "http://nienow.example/carlos_bode", - "label": "Eöl" - }, - "references": [ - { - "href": "http://tremblay.example/ted", - "label": "Balin" - }, - { - "href": "http://marquardt-paucek.test/olin.hudson", - "label": "Vinitharya" - }, - { - "href": "http://luettgen.test/greta", - "label": "Thingol" - }, - { - "href": "http://brekke.test/tomika", - "label": "Hareth" - }, - { - "href": "http://parisian-lang.test/karolyn", - "label": "Frerin" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "d7117cff-c148-496c-b4d8-a4faafebb23b", - "type": "rule", - "remediation_issue_id": null - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "precedence" - }, - "links": { - "first": "/api/compliance/v2/security_guides/22e4ed36-c32b-42fc-b191-327449a62c1e/profiles/4bf88cfc-3a46-4654-b5b9-bf942c42d2ab/rules?limit=10&offset=0&sort_by=precedence", - "last": "/api/compliance/v2/security_guides/22e4ed36-c32b-42fc-b191-327449a62c1e/profiles/4bf88cfc-3a46-4654-b5b9-bf942c42d2ab/rules?limit=10&offset=20&sort_by=precedence", - "next": "/api/compliance/v2/security_guides/22e4ed36-c32b-42fc-b191-327449a62c1e/profiles/4bf88cfc-3a46-4654-b5b9-bf942c42d2ab/rules?limit=10&offset=10&sort_by=precedence" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/rule" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/profiles/{profile_id}/rules/{rule_id}": { - "get": { - "summary": "Request a Rule assigned to a Profile", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "profile_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "rule_id", - "in": "path", - "required": true, - "description": "UUID or a ref_id with '.' characters replaced with '-'", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a specific security guide rule for a specific profile.", - "operationId": "ProfileRule", - "responses": { - "200": { - "description": "Returns a Rule assigned to a Profile", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Rule": { - "value": { - "data": { - "id": "4769dae7-d51b-48b1-8846-8908f50b2ce4", - "ref_id": "xccdf_org.ssgproject.content_rule_44a30b12e134809c42eddb92dc9449d0", - "title": "Aut neque dolorum ullam.", - "rationale": "Iusto facilis ipsum. Assumenda architecto consequatur. Quaerat est dolor.", - "description": "Sunt quibusdam occaecati. Et omnis modi. Nostrum consequatur ab.", - "severity": "low", - "precedence": 6447, - "identifier": { - "href": "http://okeefe.example/jonna_bernhard", - "label": "Éothain" - }, - "references": [ - { - "href": "http://russel-russel.test/geraldo", - "label": "Madril" - }, - { - "href": "http://armstrong-cole.example/evita_hettinger", - "label": "Ar-Gimilzôr" - }, - { - "href": "http://ward-goldner.test/josefina.prosacco", - "label": "Khamûl" - }, - { - "href": "http://deckow-marquardt.example/maragret", - "label": "Galadhon" - }, - { - "href": "http://marks-goyette.example/michael_oberbrunner", - "label": "Ar-Adûnakhôr" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "b3ed2616-d377-4846-8f10-7458fa5bd3bd", - "type": "rule", - "remediation_issue_id": null - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/rule" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Rule": { - "value": { - "errors": [ - "V2::Rule not found with ID 1ca5626d-d3f4-48b3-ba42-cce804567171" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/policies/{policy_id}/tailorings/{tailoring_id}/rules": { - "get": { - "summary": "Request Rules assigned to a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "severity", - "precedence", - "remediation_available", - "title:asc", - "title:desc", - "severity:asc", - "severity:desc", - "precedence:asc", - "precedence:desc", - "remediation_available:asc", - "remediation_available:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Rules are searchable using attributes `title`, `severity`, `remediation_available`, and `rule_group_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Retrieve a list of rules relating to specific tailorings.", - "operationId": "TailoringRules", - "responses": { - "200": { - "description": "Lists Rules assigned to a Tailoring", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Rules": { - "value": { - "data": [ - { - "id": "8c9df336-6aca-4a4d-90aa-b053ce099a7c", - "ref_id": "xccdf_org.ssgproject.content_rule_3084058bfc63bb682353689baa7d6615", - "title": "Vel ipsam eius eum.", - "rationale": "Assumenda pariatur ducimus. Eum sed enim. Ex quibusdam laboriosam.", - "description": "Ipsam nisi nobis. Voluptatem omnis in. Eum saepe voluptas.", - "severity": "medium", - "precedence": 5707, - "identifier": { - "href": "http://schoen-dickens.test/dalia", - "label": "Rorimac Brandybuck" - }, - "references": [ - { - "href": "http://kuhic.test/rupert", - "label": "Porto Baggins" - }, - { - "href": "http://feest.example/joeann_mcdermott", - "label": "Ted Sandyman" - }, - { - "href": "http://kris.example/aldo_kuvalis", - "label": "Lagduf" - }, - { - "href": "http://swaniawski.example/venetta", - "label": "Sangahyando" - }, - { - "href": "http://dubuque-willms.example/michal_anderson", - "label": "Nellas" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "d230695a-4c35-4913-8689-45f3104be2d1", - "type": "rule" - } - ], - "meta": { - "total": 1, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies/c350856f-f242-4d68-bb5d-ace092fc37d2/tailorings/4f68b6e2-4710-4851-9558-3a35d6c5efa5/rules?limit=10&offset=0", - "last": "/api/compliance/v2/policies/c350856f-f242-4d68-bb5d-ace092fc37d2/tailorings/4f68b6e2-4710-4851-9558-3a35d6c5efa5/rules?limit=10&offset=0" - } - }, - "summary": "", - "description": "" - }, - "List of Rules sorted by \"precedence:asc\"": { - "value": { - "data": [ - { - "id": "88bc6c68-9c81-4a09-97fa-1a894f387917", - "ref_id": "xccdf_org.ssgproject.content_rule_4db41e36b4ccb614c779cffb41be6a3d", - "title": "Odio minima ducimus doloribus.", - "rationale": "Porro soluta totam. Dolores aut rerum. Dolor aut eaque.", - "description": "Ea eum quasi. Ipsum excepturi nobis. Fuga neque et.", - "severity": "high", - "precedence": 7619, - "identifier": { - "href": "http://reynolds-wilkinson.example/bobby_haag", - "label": "Elendil" - }, - "references": [ - { - "href": "http://witting-rau.example/garth.shields", - "label": "Valandur" - }, - { - "href": "http://wintheiser.example/danyel_turner", - "label": "Barach" - }, - { - "href": "http://luettgen-schulist.test/gertude.friesen", - "label": "Gilraen" - }, - { - "href": "http://mohr-will.example/daniella", - "label": "Huor" - }, - { - "href": "http://wunsch.test/kathyrn.mckenzie", - "label": "Arassuil" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "2c65daa1-9036-484b-8fe9-95e4813a02d8", - "type": "rule" - } - ], - "meta": { - "total": 1, - "limit": 10, - "offset": 0, - "sort_by": "precedence" - }, - "links": { - "first": "/api/compliance/v2/policies/c0fc4e1f-10fa-41b7-9543-76bc13aeed75/tailorings/6cc7ccd1-825a-43b6-9854-7e4cea21771b/rules?limit=10&offset=0&sort_by=precedence", - "last": "/api/compliance/v2/policies/c0fc4e1f-10fa-41b7-9543-76bc13aeed75/tailorings/6cc7ccd1-825a-43b6-9854-7e4cea21771b/rules?limit=10&offset=0&sort_by=precedence" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/rule" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "post": { - "summary": "Bulk assign Rules to a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "This feature is exclusively used by the frontend", - "deprecated": true, - "operationId": "AssignRules", - "responses": { - "202": { - "description": "Assigns all specified rules and unassigns the rest", - "content": { - "application/vnd.api+json": { - "examples": { - "List of assigned Rules": { - "value": { - "data": [ - { - "id": "1b91e965-0f86-4cb8-9fd9-a75788da7a6d", - "ref_id": "xccdf_org.ssgproject.content_rule_057ad317b66a646e3e5bbc0841ca9390", - "title": "Doloribus praesentium delectus eligendi.", - "rationale": "Amet non aut. At rerum voluptatibus. Harum illum earum.", - "description": "Est corrupti illo. Nobis expedita totam. At aut iste.", - "severity": "medium", - "precedence": 2172, - "identifier": { - "href": "http://deckow.test/devorah", - "label": "Ferumbras Took" - }, - "references": [ - { - "href": "http://lynch.test/trudy", - "label": "Otho Sackville-Baggins" - }, - { - "href": "http://waters.example/columbus", - "label": "Andreth" - }, - { - "href": "http://auer.example/reuben_buckridge", - "label": "Tar-Calmacil" - }, - { - "href": "http://nolan.example/janna", - "label": "Erchirion" - }, - { - "href": "http://baumbach-huels.example/dale", - "label": "Hugo Bracegirdle" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "6e261f35-df17-4145-9580-1a58e67de934", - "type": "rule" - }, - { - "id": "1ded8a22-bc65-4a25-b224-1401abd8e6fb", - "ref_id": "xccdf_org.ssgproject.content_rule_858c6517f058d46d4f6cbf571e3a270e", - "title": "Suscipit est quia ab.", - "rationale": "Quibusdam quis quidem. Ducimus cupiditate error. Sint eveniet recusandae.", - "description": "Autem harum eum. Corporis delectus similique. Temporibus perspiciatis sed.", - "severity": "medium", - "precedence": 5293, - "identifier": { - "href": "http://hodkiewicz-kuhic.example/gabriel_wyman", - "label": "Halfred Greenhand" - }, - "references": [ - { - "href": "http://satterfield.example/darren.hessel", - "label": "Adalbert Bolger" - }, - { - "href": "http://gislason.test/belva_mann", - "label": "Celebrindor" - }, - { - "href": "http://herman.example/melida_ohara", - "label": "Turambar" - }, - { - "href": "http://roberts-emard.example/maud_doyle", - "label": "Hirgon" - }, - { - "href": "http://denesik-spencer.example/doyle", - "label": "Gildis" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "cdd05f83-6fe1-4edf-9090-389f945149c8", - "type": "rule" - }, - { - "id": "1ecd0508-63c7-41dd-91dc-5b1742108e91", - "ref_id": "xccdf_org.ssgproject.content_rule_6ed5e1b46e779203d80ebcddfb09b313", - "title": "Labore soluta qui omnis.", - "rationale": "Deleniti animi modi. Incidunt sunt ratione. Sunt molestias id.", - "description": "Qui impedit qui. Adipisci recusandae vel. Ut expedita pariatur.", - "severity": "medium", - "precedence": 112, - "identifier": { - "href": "http://wolff.test/dreama_stracke", - "label": "Gléowine" - }, - "references": [ - { - "href": "http://okon.example/reuben", - "label": "Ciryandil" - }, - { - "href": "http://fritsch.test/mose.thompson", - "label": "Glóin" - }, - { - "href": "http://ryan-rohan.test/chadwick", - "label": "Marach" - }, - { - "href": "http://stroman.test/zackary.oberbrunner", - "label": "Rose Gardner" - }, - { - "href": "http://klein.example/rea", - "label": "Orodreth" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "a0be2dab-8157-4024-9547-182a73ebe3e6", - "type": "rule" - }, - { - "id": "3b0e748b-1a04-4743-9ddf-b434f3950de5", - "ref_id": "xccdf_org.ssgproject.content_rule_354a2793b6f113a104d658f0ac4497e3", - "title": "Consequuntur earum autem velit.", - "rationale": "Exercitationem quo molestiae. Quaerat dolorum adipisci. Et autem quo.", - "description": "Et voluptatem non. Qui est ut. Repellendus provident quisquam.", - "severity": "medium", - "precedence": 8245, - "identifier": { - "href": "http://koss-oconner.test/kirby", - "label": "Minardil" - }, - "references": [ - { - "href": "http://rowe.test/robt", - "label": "Hallatan" - }, - { - "href": "http://williamson-koch.example/britt", - "label": "Ar-Sakalthôr" - }, - { - "href": "http://hoeger-gutmann.test/verline.spinka", - "label": "Asgon" - }, - { - "href": "http://lind.example/orville", - "label": "Odo Proudfoot" - }, - { - "href": "http://blanda.test/kendrick", - "label": "Lúthien" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "ba5fdb17-1df5-406a-b451-6a3acd5cf8a1", - "type": "rule" - }, - { - "id": "3ecedd7d-b41f-45c1-b05d-371fd9b5dcae", - "ref_id": "xccdf_org.ssgproject.content_rule_fe9e3caeab1f6cfd329206aae9bc7d7a", - "title": "Praesentium quo nostrum est.", - "rationale": "Excepturi magni omnis. Quam amet cumque. Et at ipsam.", - "description": "Ut sequi id. Illo aut consectetur. Nostrum rerum optio.", - "severity": "high", - "precedence": 2022, - "identifier": { - "href": "http://kertzmann-barton.example/kendall", - "label": "Beldis" - }, - "references": [ - { - "href": "http://parisian-quigley.example/darryl.gulgowski", - "label": "Ciryatur" - }, - { - "href": "http://glover-stamm.test/chang", - "label": "Dior" - }, - { - "href": "http://wolff-mcglynn.test/joe", - "label": "Théoden" - }, - { - "href": "http://wilkinson.example/genaro", - "label": "Freca" - }, - { - "href": "http://parker-dare.test/brent", - "label": "Tanta Hornblower" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "79d094bd-e317-4537-9b99-edf745d560bf", - "type": "rule" - }, - { - "id": "448bfeb5-7623-46ed-83a8-e3a855b57d2f", - "ref_id": "xccdf_org.ssgproject.content_rule_e54f2569a53fcdfdbd90f24798ea9da6", - "title": "Ab quibusdam nihil in.", - "rationale": "Aut molestiae amet. Fugiat velit quam. Molestiae dignissimos eos.", - "description": "Et ut et. Libero nulla ad. Provident in sint.", - "severity": "high", - "precedence": 8607, - "identifier": { - "href": "http://bailey.example/julianna_klein", - "label": "Finwë" - }, - "references": [ - { - "href": "http://okon.test/hoyt_goyette", - "label": "Daisy Gamgee" - }, - { - "href": "http://kozey.example/adam_willms", - "label": "Marach" - }, - { - "href": "http://tillman.example/mervin.oconnell", - "label": "Fosco Baggins" - }, - { - "href": "http://feeney.example/brandon", - "label": "Dwalin" - }, - { - "href": "http://huels-brekke.example/carlo", - "label": "Frerin" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "29480bda-025d-494f-bb39-b656e457f1aa", - "type": "rule" - }, - { - "id": "4a99118e-f866-4116-aae3-f8ac2d39f54f", - "ref_id": "xccdf_org.ssgproject.content_rule_ddb33ef03910942b712518cfee8c43f1", - "title": "Corporis rerum ut dolores.", - "rationale": "Tenetur exercitationem qui. Sunt et minus. Enim est minima.", - "description": "Et nesciunt blanditiis. Fuga suscipit ut. Reiciendis voluptatem eligendi.", - "severity": "high", - "precedence": 1240, - "identifier": { - "href": "http://hilpert-hoppe.test/max", - "label": "Dírhael" - }, - "references": [ - { - "href": "http://walsh.example/kaila.haag", - "label": "Rudibert Bolger" - }, - { - "href": "http://jacobson.example/ashton.kris", - "label": "Quennar" - }, - { - "href": "http://klocko.test/casandra", - "label": "Amlach" - }, - { - "href": "http://lueilwitz-abernathy.test/maira", - "label": "Bard" - }, - { - "href": "http://bode.example/aaron", - "label": "Pervinca Took" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "49d4db5a-222d-4ccb-811c-105dbf06639e", - "type": "rule" - }, - { - "id": "51799ff2-7fbb-48b7-9d6a-6cb50999c2d6", - "ref_id": "xccdf_org.ssgproject.content_rule_b6db05ac1fd6e458270fe69e8251f026", - "title": "Nihil autem deleniti ab.", - "rationale": "Voluptate esse incidunt. Esse dolore est. Numquam velit possimus.", - "description": "Doloribus in unde. Incidunt totam quia. Veritatis adipisci possimus.", - "severity": "medium", - "precedence": 7009, - "identifier": { - "href": "http://satterfield.test/trey_abshire", - "label": "Nienor" - }, - "references": [ - { - "href": "http://frami-roob.test/pasquale.streich", - "label": "Chica Chubb" - }, - { - "href": "http://ankunding.example/oliva_waters", - "label": "Snaga" - }, - { - "href": "http://kreiger.example/caitlyn_renner", - "label": "Fíli" - }, - { - "href": "http://mann.test/don", - "label": "Hending" - }, - { - "href": "http://boyer.test/randal.halvorson", - "label": "Dernhelm" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "357f4779-c7fa-40f9-9e1c-081af3e352d2", - "type": "rule" - }, - { - "id": "5a4a1613-1a6c-40b0-a779-fabd969858c4", - "ref_id": "xccdf_org.ssgproject.content_rule_3f36d14ccd80280b803ce51c82d295ea", - "title": "Animi illo ut in.", - "rationale": "Exercitationem a voluptas. Hic fugiat quo. Beatae sequi nihil.", - "description": "Iure similique at. Quia consectetur explicabo. Ea dolores sit.", - "severity": "medium", - "precedence": 7047, - "identifier": { - "href": "http://koss-hane.example/augustine", - "label": "Othrondir" - }, - "references": [ - { - "href": "http://boyle-rosenbaum.test/hyon", - "label": "Sigismond Took" - }, - { - "href": "http://crona-feil.example/nannette", - "label": "Beorn" - }, - { - "href": "http://hyatt.test/bonny", - "label": "Belen" - }, - { - "href": "http://lemke.test/sandy_dicki", - "label": "Galadriel" - }, - { - "href": "http://greenfelder.test/arnold", - "label": "Elrond" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "690c0d8c-3430-4a4e-8922-537c2be7b544", - "type": "rule" - }, - { - "id": "68ba4df5-8b1f-42cc-80a0-59aef0380cf6", - "ref_id": "xccdf_org.ssgproject.content_rule_45565b485ab21dcaf54bab248cf84afc", - "title": "Ut quia voluptas voluptatem.", - "rationale": "Saepe voluptate quis. Officia deleniti asperiores. Blanditiis consequatur veniam.", - "description": "Eveniet a autem. Ut ut voluptate. In odio ut.", - "severity": "high", - "precedence": 5102, - "identifier": { - "href": "http://blick.test/alvin_streich", - "label": "Wilibald Bolger" - }, - "references": [ - { - "href": "http://ward.example/carter", - "label": "Nimloth of Doriath" - }, - { - "href": "http://johnston.test/paola", - "label": "Goldwine" - }, - { - "href": "http://goyette.example/nathan.mante", - "label": "Wilibald Bolger" - }, - { - "href": "http://brekke-mohr.example/cory", - "label": "Théodwyn" - }, - { - "href": "http://nicolas.example/hobert", - "label": "Berylla Boffin" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "ff6985df-ef7d-4981-a2f0-6cd5d079e541", - "type": "rule" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies/41dd1a93-2784-4bd3-a148-9dabb9d89a0d/tailorings/a4ad7bde-bdd0-4f4d-8aee-42105266631e/rules?limit=10&offset=0", - "last": "/api/compliance/v2/policies/41dd1a93-2784-4bd3-a148-9dabb9d89a0d/tailorings/a4ad7bde-bdd0-4f4d-8aee-42105266631e/rules?limit=10&offset=20", - "next": "/api/compliance/v2/policies/41dd1a93-2784-4bd3-a148-9dabb9d89a0d/tailorings/a4ad7bde-bdd0-4f4d-8aee-42105266631e/rules?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/rule" - } - } - } - } - } - } - } - } - } - }, - "requestBody": { - "content": { - "application/vnd.api+json": { - "schema": { - "type": "object", - "properties": { - "ids": { - "type": "array", - "items": { - "type": "string" - } - } - } - } - } - } - } - } - }, - "/policies/{policy_id}/tailorings/{tailoring_id}/rules/{rule_id}": { - "patch": { - "summary": "Assign a Rule to a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "rule_id", - "in": "path", - "required": true, - "description": "UUID or a ref_id with '.' characters replaced with '-'", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Add a rule to a specific tailoring.", - "operationId": "AssignRule", - "responses": { - "202": { - "description": "Assigns a Rule to a Tailoring", - "content": { - "application/vnd.api+json": { - "examples": { - "Assigns a Rule to a Tailoring": { - "value": { - "data": { - "id": "2688b651-ed1e-419d-a106-0ae43aefeace", - "ref_id": "xccdf_org.ssgproject.content_rule_62007b6bd3cc202262d3f5466c2f9d5f", - "title": "Veritatis in eligendi voluptatem.", - "rationale": "Et ab provident. Quis vel libero. Sunt voluptatum aperiam.", - "description": "Aut qui officiis. Ab ut beatae. Ipsum perspiciatis enim.", - "severity": "low", - "precedence": 732, - "identifier": { - "href": "http://white.test/aldo", - "label": "Hathol" - }, - "references": [ - { - "href": "http://davis-ondricka.example/rosario_maggio", - "label": "Landroval" - }, - { - "href": "http://robel.test/karl", - "label": "Eluréd" - }, - { - "href": "http://powlowski.example/hyman", - "label": "Polo Baggins" - }, - { - "href": "http://hayes.test/ciera_daniel", - "label": "Vardamir" - }, - { - "href": "http://dickens.example/glen_nicolas", - "label": "Théodred" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "83f83188-f2fe-4a97-9a97-4aa72224f451", - "type": "rule" - } - }, - "summary": "", - "description": "" - } - } - } - } - }, - "404": { - "description": "Returns with Not found", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns with Not found": { - "value": { - "errors": [ - "V2::Rule not found with ID 08ce7f0a-aa37-4454-b3f2-6d51d905ecf7" - ] - }, - "summary": "", - "description": "" - } - } - } - } - } - } - }, - "delete": { - "summary": "Unassign a Rule from a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "rule_id", - "in": "path", - "required": true, - "description": "UUID or a ref_id with '.' characters replaced with '-'", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Use this to remove a rule from your tailoring.", - "operationId": "UnassignRule", - "responses": { - "202": { - "description": "Unassigns a Rule from a Tailoring", - "content": { - "application/vnd.api+json": { - "examples": { - "Unassigns a Rule from a Tailoring": { - "value": { - "data": { - "id": "1c21b25d-7e6f-47e0-b0d8-e15e4c3e3c9c", - "ref_id": "xccdf_org.ssgproject.content_rule_8cbe493da1038097f410e4554be8acc8", - "title": "Tenetur saepe voluptatem optio.", - "rationale": "Earum quia non. Dolor nihil hic. Aspernatur sint aut.", - "description": "Reprehenderit ducimus esse. Optio repellat dolor. Ut omnis et.", - "severity": "high", - "precedence": 3999, - "identifier": { - "href": "http://reichert.example/katia", - "label": "Gwaihir" - }, - "references": [ - { - "href": "http://thompson-parker.example/felipe_abbott", - "label": "Holfast Gardner" - }, - { - "href": "http://hessel.test/tamika.hoeger", - "label": "Borthand" - }, - { - "href": "http://lind.example/jeffry_runolfsson", - "label": "Malvegil" - }, - { - "href": "http://christiansen.test/brenna", - "label": "Túrin" - }, - { - "href": "http://parker.example/hai", - "label": "Saradas Brandybuck" - } - ], - "value_checks": null, - "remediation_available": false, - "rule_group_id": "9264e63c-edb2-4cfe-9322-85e909e214b8", - "type": "rule" - } - }, - "summary": "", - "description": "" - } - } - } - } - }, - "404": { - "description": "Returns with Not found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when unassigning a non-existing Rule": { - "value": { - "errors": [ - "V2::Rule not found with ID 78f9e071-9b7d-49f6-9f23-5a8cb32fb5b7" - ] - }, - "summary": "", - "description": "" - } - } - } - } - } - } - } - }, - "/security_guides": { - "get": { - "summary": "Request Security Guides", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "version", - "os_major_version", - "title:asc", - "title:desc", - "version:asc", - "version:desc", - "os_major_version:asc", - "os_major_version:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Security Guides are searchable using attributes `title`, `version`, `ref_id`, `os_major_version`, `profile_ref_id`, and `supported_profile`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a list of all SCAP security guides.", - "operationId": "SecurityGuides", - "responses": { - "200": { - "description": "Lists Security Guides", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Security Guides": { - "value": { - "data": [ - { - "id": "05162585-b31b-405d-ae0b-165c2c3201d7", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Quo non deserunt neque.", - "version": "100.83.8", - "description": "Voluptatem iste quae. Reiciendis debitis fugit. Delectus ea omnis.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "096f669e-736b-435c-a27a-871bbb0f8e50", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Rerum laboriosam nostrum quidem.", - "version": "100.83.15", - "description": "Esse a vero. Eligendi et modi. Ut ut tempora.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "0aab5284-f62e-4c57-88ac-ead4e6859e98", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Dolor voluptatem at facere.", - "version": "100.82.43", - "description": "Magnam sapiente dolores. Et sint et. Incidunt iste voluptas.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "141952be-f49b-48c3-85d9-b6e331cd4d48", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Iusto totam nemo reprehenderit.", - "version": "100.83.16", - "description": "Numquam voluptatem hic. Modi earum itaque. Autem magni et.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "210ad79f-1969-43fe-8280-abda48bc49db", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Ex est eius sunt.", - "version": "100.83.1", - "description": "Ipsum consectetur doloremque. Rerum quo autem. Perferendis eos reiciendis.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "26a73ee6-644b-4d01-ac6d-43f03ba621e0", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Rem ipsum necessitatibus ea.", - "version": "100.83.3", - "description": "Numquam inventore ad. Occaecati harum veritatis. Quis atque aliquam.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "2a966333-ce03-4046-8b7a-808672fedd9b", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Tempore voluptate et voluptatibus.", - "version": "100.82.44", - "description": "Nesciunt enim iusto. Nam iure sit. Nulla tenetur omnis.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "3aa4cbeb-445e-406d-80ee-45cfb3aafd0a", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Quidem quam velit sunt.", - "version": "100.83.10", - "description": "Sit et tempore. Magnam aliquam eum. Atque cumque quis.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "42febb18-2f7f-4dfd-a8d4-4aae65490d61", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Delectus modi ut officiis.", - "version": "100.83.6", - "description": "Atque hic excepturi. Libero quia id. Velit et aut.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "4efc0ac0-c807-4f27-bd93-a7c93e074629", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Est explicabo nulla quis.", - "version": "100.83.12", - "description": "Sit pariatur qui. Culpa suscipit enim. Accusamus saepe iusto.", - "os_major_version": 7, - "type": "security_guide" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides?limit=10&offset=0", - "last": "/api/compliance/v2/security_guides?limit=10&offset=20", - "next": "/api/compliance/v2/security_guides?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Security Guides sorted by \"os_major_version:asc\"": { - "value": { - "data": [ - { - "id": "00466a3e-ed93-4c06-b6ca-ddfcbbd22aa1", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Aliquid earum sed rerum.", - "version": "100.83.30", - "description": "Qui hic voluptates. Sit doloremque est. Possimus dolore expedita.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "0863ce26-a85d-40aa-a633-b693011bc662", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Nisi voluptas sapiente perspiciatis.", - "version": "100.83.37", - "description": "Et voluptas voluptatem. Provident soluta id. Autem dignissimos quia.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "165fccf8-4c3e-4d4c-9098-4224cc03b852", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Non ut quia quia.", - "version": "100.83.36", - "description": "Dolore et beatae. Omnis et ipsum. Optio eligendi nihil.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "1a1075ca-d908-4b14-a992-26114f82eadc", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Velit aut temporibus assumenda.", - "version": "100.83.29", - "description": "Qui voluptate veniam. Sit temporibus magnam. Ut fuga in.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "1a720e9a-d36e-4102-8779-aae4c73f1e44", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Quos reprehenderit alias esse.", - "version": "100.83.41", - "description": "In quam culpa. Illo veniam iure. Voluptatem explicabo vel.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "212052fc-4c5e-40b1-a68f-80849ce38419", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Dolores ad velit ea.", - "version": "100.83.28", - "description": "Omnis fugit quod. Doloremque esse fuga. Ad animi molestiae.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "22b5794c-61c8-4bd4-8500-efae4991ff6f", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Esse vel autem odio.", - "version": "100.83.39", - "description": "Animi qui corrupti. Architecto aliquam ratione. Quaerat et et.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "260706f4-62f8-4eae-8f72-5c1f7c509049", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Voluptas soluta quia et.", - "version": "100.83.18", - "description": "Voluptatum nihil ab. Quaerat rerum aut. Iste est optio.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "28e01b81-95bc-459f-bd73-59c14ae3db61", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Omnis aut non quod.", - "version": "100.83.27", - "description": "Temporibus non blanditiis. Vel ut doloremque. Sunt quae error.", - "os_major_version": 7, - "type": "security_guide" - }, - { - "id": "2a168238-e390-48b0-bc62-ea4c76a17ebe", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Officia ab occaecati nostrum.", - "version": "100.83.24", - "description": "Quas accusantium odit. Ea et quia. Reiciendis doloremque numquam.", - "os_major_version": 7, - "type": "security_guide" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "os_major_version" - }, - "links": { - "first": "/api/compliance/v2/security_guides?limit=10&offset=0&sort_by=os_major_version", - "last": "/api/compliance/v2/security_guides?limit=10&offset=20&sort_by=os_major_version", - "next": "/api/compliance/v2/security_guides?limit=10&offset=10&sort_by=os_major_version" - } - }, - "summary": "", - "description": "" - }, - "List of Security Guides filtered by \"(os_major_version=8)\"": { - "value": { - "data": [], - "meta": { - "total": 0, - "filter": "(os_major_version=8)", - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides?filter=%28os_major_version%3D8%29&limit=10&offset=0", - "last": "/api/compliance/v2/security_guides?filter=%28os_major_version%3D8%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/security_guide" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/os_versions": { - "get": { - "summary": "Request the list of available OS versions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Systems are searchable using attributes `display_name`, `os_version`, `os_major_version`, `os_minor_version`, `assigned_or_scanned`, `never_reported`, `group_name`, `policies`, and `profile_ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "This feature is exclusively used by the frontend", - "operationId": "SecurityGuidesOS", - "deprecated": true, - "responses": { - "200": { - "description": "Lists available OS versions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of available OS versions": { - "value": [ - 7 - ], - "summary": "", - "description": "" - } - }, - "schema": { - "type": "array", - "items": { - "type": "integer" - } - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}": { - "get": { - "summary": "Request a Security Guide", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a specific security guide.", - "operationId": "SecurityGuide", - "responses": { - "200": { - "description": "Returns a Security Guide", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Security Guide": { - "value": { - "data": { - "id": "b33c9b6f-05c8-4d5f-9375-b4b6aeb8cb0b", - "ref_id": "xccdf_org.ssgproject.content_benchmark_RHEL-7", - "title": "Accusantium quos pariatur commodi.", - "version": "100.85.43", - "description": "Ut nostrum facere. Enim eveniet aut. Doloremque eaque sit.", - "os_major_version": 7, - "type": "security_guide" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/security_guide" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Security Guide": { - "value": { - "errors": [ - "V2::SecurityGuide not found with ID 4c33859a-7c16-441b-a1fc-a03fcde22a64" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/rule_tree": { - "get": { - "summary": "Request the Rule Tree of a Security Guide", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Returns rule tree of a security guide.", - "operationId": "SecurityGuideRuleTree", - "deprecated": true, - "responses": { - "200": { - "description": "Returns the Rule Tree of a Security Guide", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns the Rule Tree of a Security Guide": { - "value": [ - { - "id": "22835aef-1555-4312-9377-dae4fe8cf5d3", - "type": "rule_group", - "children": [ - { - "id": "c1d16875-b002-49f0-ad6e-df073ffd5e99", - "type": "rule" - } - ] - }, - { - "id": "b32e54a2-8231-4215-9124-23ef1d35da1b", - "type": "rule_group", - "children": [ - { - "id": "078f2766-deb7-4db2-a772-3201638f6c6d", - "type": "rule" - } - ] - }, - { - "id": "b872023e-32cd-4ff4-b415-e99ecb688635", - "type": "rule_group", - "children": [ - { - "id": "3d819a72-a03f-4d2f-a291-85e555ec4578", - "type": "rule" - } - ] - }, - { - "id": "be75c45b-979c-41bb-b41b-970841ac0edd", - "type": "rule_group", - "children": [ - { - "id": "6177ece1-0cfe-43f7-a286-a0e603383775", - "type": "rule" - } - ] - }, - { - "id": "6d6e43af-2b0a-445c-8c38-235ba38d0f4e", - "type": "rule_group", - "children": [ - { - "id": "986dc4e2-181c-49cd-bb55-21d947020fa1", - "type": "rule" - } - ] - }, - { - "id": "8e50ba96-dd9b-458d-9e01-53d2334e5da1", - "type": "rule_group", - "children": [ - { - "id": "a7118c36-e709-404b-ac8a-cc2de69b2d4a", - "type": "rule" - } - ] - }, - { - "id": "1bb040b6-00c8-4652-8e7a-1f24567deb31", - "type": "rule_group", - "children": [ - { - "id": "262fe46d-b6a3-48d0-99fd-b3da4f7dbc4e", - "type": "rule" - } - ] - }, - { - "id": "703fae9d-f169-490e-a7de-191b56b02d3d", - "type": "rule_group", - "children": [ - { - "id": "52f3c806-263d-4b27-bce9-ce5747c3f5d4", - "type": "rule" - } - ] - }, - { - "id": "267834f8-26a2-441a-a8bd-35a77837ccae", - "type": "rule_group", - "children": [ - { - "id": "8fa56c64-f63a-43a5-8198-2a38be046365", - "type": "rule" - } - ] - }, - { - "id": "f5815895-927d-4411-90a8-15ffa6739188", - "type": "rule_group", - "children": [ - { - "id": "c061a498-1d57-4190-af7e-e604b1e070bb", - "type": "rule" - } - ] - } - ], - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/rule_tree" - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Security Guide": { - "value": { - "errors": [ - "V2::SecurityGuide not found with ID 4d9bb6a2-377f-4b0f-acbd-37c43f1a740f" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/supported_profiles": { - "get": { - "summary": "Request Supported Profiles", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "os_major_version", - "os_minor_versions", - "title:asc", - "title:desc", - "os_major_version:asc", - "os_major_version:desc", - "os_minor_versions:asc", - "os_minor_versions:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Supported Profiles are searchable using attributes `os_major_version`, `title`, and `ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve the list of profiles supported by particular RHEL versions.", - "operationId": "SupportedProfiles", - "responses": { - "200": { - "description": "Lists Supported Profiles", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Supported Profiles": { - "value": { - "data": [ - { - "id": "835e1843-22f4-4bac-b26e-3fce575f7f20", - "title": "Voluptatem eos expedita est.", - "description": "Quis natus sapiente. Et eligendi quia. Repellat ut est.", - "ref_id": "xccdf_org.ssgproject.content_profile_426bab394c8c3179e64b8d7c9df706d6", - "security_guide_id": "3b526888-4f54-456e-8e99-d5182a878909", - "security_guide_version": "100.86.22", - "os_major_version": 7, - "os_minor_versions": [ - 3, - 2, - 1 - ], - "type": "supported_profile" - } - ], - "meta": { - "total": 1, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/supported_profiles?limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/supported_profiles?limit=10&offset=0" - } - }, - "summary": "", - "description": "" - }, - "List of Supported Profiles sorted by \"os_major_version:asc\"": { - "value": { - "data": [ - { - "id": "5274b515-4a06-4a32-943c-54900d101992", - "title": "Aliquam quis ut qui.", - "description": "Ratione et in. Sint aut et. Consequatur officiis optio.", - "ref_id": "xccdf_org.ssgproject.content_profile_d394f4d9c14161d2c3f55b62353b402f", - "security_guide_id": "902a78c9-c9b8-47d4-b1c5-b6a46f65997f", - "security_guide_version": "100.86.23", - "os_major_version": 7, - "os_minor_versions": [ - 3, - 2, - 1 - ], - "type": "supported_profile" - } - ], - "meta": { - "total": 1, - "limit": 10, - "offset": 0, - "sort_by": "os_major_version" - }, - "links": { - "first": "/api/compliance/v2/security_guides/supported_profiles?limit=10&offset=0&sort_by=os_major_version", - "last": "/api/compliance/v2/security_guides/supported_profiles?limit=10&offset=0&sort_by=os_major_version" - } - }, - "summary": "", - "description": "" - }, - "List of Supported Profiles filtered by \"(os_major_version=8)\"": { - "value": { - "data": [], - "meta": { - "total": 0, - "filter": "(os_major_version=8)", - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/supported_profiles?filter=%28os_major_version%3D8%29&limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/supported_profiles?filter=%28os_major_version%3D8%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/supported_profile" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/systems": { - "get": { - "summary": "Request Systems", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "tags", - "in": "query", - "required": false, - "description": "An array of tags to narrow down the search results. In case the value contains symbols used for separators (`/` or `=`), they need to be encoded.<br>e.g.: `namespace/key=value`, `insights-client/selinux-config=SELINUX%3Denforcing`", - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "display_name", - "os_major_version", - "os_minor_version", - "os_version", - "groups", - "display_name:asc", - "display_name:desc", - "os_major_version:asc", - "os_major_version:desc", - "os_minor_version:asc", - "os_minor_version:desc", - "os_version:asc", - "os_version:desc", - "groups:asc", - "groups:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Systems are searchable using attributes `display_name`, `os_major_version`, `os_minor_version`, `assigned_or_scanned`, `group_name`, `policies`, and `profile_ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Systems" - ], - "description": "List all systems that are accessible when you are logged into your account.", - "operationId": "Systems", - "responses": { - "200": { - "description": "Lists Systems", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Systems": { - "value": { - "data": [ - { - "id": "095406ee-c1fc-4b0c-97b5-042a65da4a15", - "display_name": "gulgowski.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:16.985Z", - "stale_timestamp": "2035-04-17T11:49:16.985Z", - "stale_warning_timestamp": "2035-04-24T11:49:16.985Z", - "updated": "2025-04-17T11:49:16.986Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "primary", - "namespace": "transmitting" - }, - { - "key": "driver", - "value": "virtual", - "namespace": "calculating" - }, - { - "key": "matrix", - "value": "neural", - "namespace": "indexing" - }, - { - "key": "feed", - "value": "1080p", - "namespace": "programming" - }, - { - "key": "feed", - "value": "primary", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:16.985Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "0964e6ba-a1b4-427d-9f47-6d3a618949de", - "display_name": "sporer-hayes.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.027Z", - "stale_timestamp": "2035-04-17T11:49:17.027Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.027Z", - "updated": "2025-04-17T11:49:17.027Z", - "insights_id": null, - "tags": [ - { - "key": "circuit", - "value": "neural", - "namespace": "calculating" - }, - { - "key": "firewall", - "value": "virtual", - "namespace": "quantifying" - }, - { - "key": "capacitor", - "value": "online", - "namespace": "programming" - }, - { - "key": "program", - "value": "multi-byte", - "namespace": "transmitting" - }, - { - "key": "monitor", - "value": "open-source", - "namespace": "overriding" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.027Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "0f3cdb19-06a5-45fd-b08a-b714d5580208", - "display_name": "pacocha.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:16.969Z", - "stale_timestamp": "2035-04-17T11:49:16.969Z", - "stale_warning_timestamp": "2035-04-24T11:49:16.969Z", - "updated": "2025-04-17T11:49:16.969Z", - "insights_id": null, - "tags": [ - { - "key": "pixel", - "value": "solid state", - "namespace": "bypassing" - }, - { - "key": "panel", - "value": "auxiliary", - "namespace": "quantifying" - }, - { - "key": "port", - "value": "multi-byte", - "namespace": "generating" - }, - { - "key": "program", - "value": "primary", - "namespace": "hacking" - }, - { - "key": "bus", - "value": "multi-byte", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:16.969Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "19d69fe7-f16f-453b-98ee-b241016d07eb", - "display_name": "casper-bayer.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.001Z", - "stale_timestamp": "2035-04-17T11:49:17.001Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.001Z", - "updated": "2025-04-17T11:49:17.001Z", - "insights_id": null, - "tags": [ - { - "key": "program", - "value": "digital", - "namespace": "bypassing" - }, - { - "key": "pixel", - "value": "bluetooth", - "namespace": "synthesizing" - }, - { - "key": "interface", - "value": "solid state", - "namespace": "navigating" - }, - { - "key": "feed", - "value": "neural", - "namespace": "connecting" - }, - { - "key": "feed", - "value": "multi-byte", - "namespace": "indexing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.001Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "2857916d-dc11-43fe-b96c-740b12c946b7", - "display_name": "goldner.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.004Z", - "stale_timestamp": "2035-04-17T11:49:17.004Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.004Z", - "updated": "2025-04-17T11:49:17.004Z", - "insights_id": null, - "tags": [ - { - "key": "protocol", - "value": "open-source", - "namespace": "transmitting" - }, - { - "key": "system", - "value": "bluetooth", - "namespace": "compressing" - }, - { - "key": "sensor", - "value": "bluetooth", - "namespace": "backing up" - }, - { - "key": "program", - "value": "open-source", - "namespace": "calculating" - }, - { - "key": "application", - "value": "digital", - "namespace": "hacking" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.004Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "29e611b3-330f-443a-8eda-d278adda7cd2", - "display_name": "hermiston-rohan.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:16.995Z", - "stale_timestamp": "2035-04-17T11:49:16.995Z", - "stale_warning_timestamp": "2035-04-24T11:49:16.995Z", - "updated": "2025-04-17T11:49:16.996Z", - "insights_id": null, - "tags": [ - { - "key": "capacitor", - "value": "digital", - "namespace": "overriding" - }, - { - "key": "interface", - "value": "mobile", - "namespace": "backing up" - }, - { - "key": "monitor", - "value": "back-end", - "namespace": "programming" - }, - { - "key": "matrix", - "value": "mobile", - "namespace": "overriding" - }, - { - "key": "capacitor", - "value": "auxiliary", - "namespace": "backing up" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:16.995Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "324c4943-4ea4-4bd6-8d54-f9ca3eb46d33", - "display_name": "kiehn.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:16.971Z", - "stale_timestamp": "2035-04-17T11:49:16.971Z", - "stale_warning_timestamp": "2035-04-24T11:49:16.971Z", - "updated": "2025-04-17T11:49:16.971Z", - "insights_id": null, - "tags": [ - { - "key": "port", - "value": "cross-platform", - "namespace": "backing up" - }, - { - "key": "microchip", - "value": "redundant", - "namespace": "backing up" - }, - { - "key": "pixel", - "value": "solid state", - "namespace": "indexing" - }, - { - "key": "monitor", - "value": "haptic", - "namespace": "copying" - }, - { - "key": "bus", - "value": "digital", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:16.971Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "39226c5e-9941-4713-8975-d032e522de91", - "display_name": "bogan.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:16.973Z", - "stale_timestamp": "2035-04-17T11:49:16.973Z", - "stale_warning_timestamp": "2035-04-24T11:49:16.973Z", - "updated": "2025-04-17T11:49:16.973Z", - "insights_id": null, - "tags": [ - { - "key": "driver", - "value": "1080p", - "namespace": "programming" - }, - { - "key": "microchip", - "value": "bluetooth", - "namespace": "calculating" - }, - { - "key": "array", - "value": "auxiliary", - "namespace": "backing up" - }, - { - "key": "circuit", - "value": "cross-platform", - "namespace": "compressing" - }, - { - "key": "array", - "value": "redundant", - "namespace": "calculating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:16.973Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "40c1ac56-c687-4fd8-b474-f15485ab0510", - "display_name": "littel.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.017Z", - "stale_timestamp": "2035-04-17T11:49:17.017Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.017Z", - "updated": "2025-04-17T11:49:17.017Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "online", - "namespace": "calculating" - }, - { - "key": "application", - "value": "1080p", - "namespace": "indexing" - }, - { - "key": "interface", - "value": "back-end", - "namespace": "backing up" - }, - { - "key": "matrix", - "value": "mobile", - "namespace": "connecting" - }, - { - "key": "interface", - "value": "optical", - "namespace": "programming" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.017Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "41006059-00ce-40c5-98ab-4667976c0d4d", - "display_name": "graham.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.015Z", - "stale_timestamp": "2035-04-17T11:49:17.015Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.015Z", - "updated": "2025-04-17T11:49:17.015Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "mobile", - "namespace": "compressing" - }, - { - "key": "card", - "value": "digital", - "namespace": "calculating" - }, - { - "key": "system", - "value": "open-source", - "namespace": "calculating" - }, - { - "key": "bandwidth", - "value": "primary", - "namespace": "parsing" - }, - { - "key": "port", - "value": "wireless", - "namespace": "indexing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.015Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/systems?limit=10&offset=0", - "last": "/api/compliance/v2/systems?limit=10&offset=20", - "next": "/api/compliance/v2/systems?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Systems sorted by \"os_major_version:asc\"": { - "value": { - "data": [ - { - "id": "010b0778-50f5-4f2e-80fd-079f45a1b3bc", - "display_name": "batz.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.092Z", - "stale_timestamp": "2035-04-17T11:49:17.092Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.092Z", - "updated": "2025-04-17T11:49:17.092Z", - "insights_id": null, - "tags": [ - { - "key": "application", - "value": "open-source", - "namespace": "synthesizing" - }, - { - "key": "firewall", - "value": "optical", - "namespace": "connecting" - }, - { - "key": "bandwidth", - "value": "optical", - "namespace": "navigating" - }, - { - "key": "panel", - "value": "optical", - "namespace": "hacking" - }, - { - "key": "bus", - "value": "redundant", - "namespace": "quantifying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.092Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "017c23c7-277f-456c-98d9-b47dcc59caf5", - "display_name": "howell-casper.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.059Z", - "stale_timestamp": "2035-04-17T11:49:17.059Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.059Z", - "updated": "2025-04-17T11:49:17.059Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "neural", - "namespace": "copying" - }, - { - "key": "card", - "value": "open-source", - "namespace": "connecting" - }, - { - "key": "driver", - "value": "online", - "namespace": "hacking" - }, - { - "key": "feed", - "value": "1080p", - "namespace": "transmitting" - }, - { - "key": "microchip", - "value": "solid state", - "namespace": "compressing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.059Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "22037ff7-ba34-410f-93c4-1f2ed2f41dd3", - "display_name": "witting.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.097Z", - "stale_timestamp": "2035-04-17T11:49:17.097Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.097Z", - "updated": "2025-04-17T11:49:17.097Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "open-source", - "namespace": "navigating" - }, - { - "key": "pixel", - "value": "virtual", - "namespace": "connecting" - }, - { - "key": "port", - "value": "back-end", - "namespace": "parsing" - }, - { - "key": "interface", - "value": "mobile", - "namespace": "calculating" - }, - { - "key": "monitor", - "value": "optical", - "namespace": "calculating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.097Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "2439fd61-b8cd-4439-aeeb-af24078e1aa7", - "display_name": "nienow.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.073Z", - "stale_timestamp": "2035-04-17T11:49:17.073Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.073Z", - "updated": "2025-04-17T11:49:17.073Z", - "insights_id": null, - "tags": [ - { - "key": "port", - "value": "bluetooth", - "namespace": "connecting" - }, - { - "key": "transmitter", - "value": "solid state", - "namespace": "parsing" - }, - { - "key": "pixel", - "value": "mobile", - "namespace": "connecting" - }, - { - "key": "pixel", - "value": "primary", - "namespace": "programming" - }, - { - "key": "application", - "value": "haptic", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.073Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "280685c4-3cbe-4c51-9975-4e56d083eb77", - "display_name": "gleichner-fisher.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.068Z", - "stale_timestamp": "2035-04-17T11:49:17.068Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.068Z", - "updated": "2025-04-17T11:49:17.068Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "online", - "namespace": "compressing" - }, - { - "key": "sensor", - "value": "multi-byte", - "namespace": "hacking" - }, - { - "key": "matrix", - "value": "haptic", - "namespace": "parsing" - }, - { - "key": "card", - "value": "cross-platform", - "namespace": "navigating" - }, - { - "key": "pixel", - "value": "virtual", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.068Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "2a9c4042-44ed-4caf-ab66-de8c24cf0b22", - "display_name": "jacobson.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.094Z", - "stale_timestamp": "2035-04-17T11:49:17.094Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.094Z", - "updated": "2025-04-17T11:49:17.094Z", - "insights_id": null, - "tags": [ - { - "key": "panel", - "value": "digital", - "namespace": "connecting" - }, - { - "key": "circuit", - "value": "bluetooth", - "namespace": "programming" - }, - { - "key": "microchip", - "value": "bluetooth", - "namespace": "compressing" - }, - { - "key": "protocol", - "value": "mobile", - "namespace": "copying" - }, - { - "key": "sensor", - "value": "primary", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.094Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "3486ae2f-8490-4c02-ba73-34b628bdbfcf", - "display_name": "hirthe.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.060Z", - "stale_timestamp": "2035-04-17T11:49:17.060Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.060Z", - "updated": "2025-04-17T11:49:17.060Z", - "insights_id": null, - "tags": [ - { - "key": "card", - "value": "neural", - "namespace": "connecting" - }, - { - "key": "bandwidth", - "value": "back-end", - "namespace": "copying" - }, - { - "key": "pixel", - "value": "1080p", - "namespace": "parsing" - }, - { - "key": "monitor", - "value": "virtual", - "namespace": "hacking" - }, - { - "key": "transmitter", - "value": "online", - "namespace": "copying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.060Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "3b94888f-2cf5-47f9-80c4-d90d54f033e0", - "display_name": "reichert-wilderman.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.080Z", - "stale_timestamp": "2035-04-17T11:49:17.080Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.080Z", - "updated": "2025-04-17T11:49:17.080Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "auxiliary", - "namespace": "calculating" - }, - { - "key": "port", - "value": "auxiliary", - "namespace": "parsing" - }, - { - "key": "firewall", - "value": "solid state", - "namespace": "copying" - }, - { - "key": "circuit", - "value": "neural", - "namespace": "compressing" - }, - { - "key": "panel", - "value": "open-source", - "namespace": "transmitting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.080Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "4c0ad47a-40dc-4b2f-a7a1-ae2cbf70c7ec", - "display_name": "goyette.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.057Z", - "stale_timestamp": "2035-04-17T11:49:17.057Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.057Z", - "updated": "2025-04-17T11:49:17.057Z", - "insights_id": null, - "tags": [ - { - "key": "card", - "value": "primary", - "namespace": "overriding" - }, - { - "key": "bus", - "value": "virtual", - "namespace": "overriding" - }, - { - "key": "panel", - "value": "online", - "namespace": "compressing" - }, - { - "key": "transmitter", - "value": "open-source", - "namespace": "calculating" - }, - { - "key": "panel", - "value": "open-source", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.057Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "5908eeea-8e3c-4648-9893-e8b8314fc0ad", - "display_name": "sawayn.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.077Z", - "stale_timestamp": "2035-04-17T11:49:17.077Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.077Z", - "updated": "2025-04-17T11:49:17.077Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "redundant", - "namespace": "synthesizing" - }, - { - "key": "matrix", - "value": "mobile", - "namespace": "programming" - }, - { - "key": "application", - "value": "primary", - "namespace": "synthesizing" - }, - { - "key": "matrix", - "value": "back-end", - "namespace": "navigating" - }, - { - "key": "feed", - "value": "multi-byte", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.077Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0, - "sort_by": "os_major_version" - }, - "links": { - "first": "/api/compliance/v2/systems?limit=10&offset=0&sort_by=os_major_version", - "last": "/api/compliance/v2/systems?limit=10&offset=20&sort_by=os_major_version", - "next": "/api/compliance/v2/systems?limit=10&offset=10&sort_by=os_major_version" - } - }, - "summary": "", - "description": "" - }, - "List of Systems filtered by \"(os_major_version=8)\"": { - "value": { - "data": [ - { - "id": "027ebfd3-efd1-4b09-a6f4-a75ed5b6be3d", - "display_name": "wuckert-ankunding.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.164Z", - "stale_timestamp": "2035-04-17T11:49:17.164Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.164Z", - "updated": "2025-04-17T11:49:17.164Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "mobile", - "namespace": "calculating" - }, - { - "key": "panel", - "value": "haptic", - "namespace": "copying" - }, - { - "key": "sensor", - "value": "online", - "namespace": "compressing" - }, - { - "key": "bandwidth", - "value": "multi-byte", - "namespace": "programming" - }, - { - "key": "program", - "value": "online", - "namespace": "transmitting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.164Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "0e308c38-f22f-49a3-9a1d-550e65f148d8", - "display_name": "donnelly-beier.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.124Z", - "stale_timestamp": "2035-04-17T11:49:17.124Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.124Z", - "updated": "2025-04-17T11:49:17.124Z", - "insights_id": null, - "tags": [ - { - "key": "program", - "value": "haptic", - "namespace": "generating" - }, - { - "key": "application", - "value": "bluetooth", - "namespace": "compressing" - }, - { - "key": "interface", - "value": "1080p", - "namespace": "backing up" - }, - { - "key": "array", - "value": "virtual", - "namespace": "compressing" - }, - { - "key": "alarm", - "value": "1080p", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.124Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "0f8ea7b2-20e3-4c5a-953b-991110fcf922", - "display_name": "waelchi.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.156Z", - "stale_timestamp": "2035-04-17T11:49:17.156Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.156Z", - "updated": "2025-04-17T11:49:17.156Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "redundant", - "namespace": "synthesizing" - }, - { - "key": "circuit", - "value": "optical", - "namespace": "bypassing" - }, - { - "key": "bandwidth", - "value": "1080p", - "namespace": "hacking" - }, - { - "key": "port", - "value": "1080p", - "namespace": "indexing" - }, - { - "key": "pixel", - "value": "cross-platform", - "namespace": "copying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.156Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "369ebf30-2d70-4a4d-8a6b-266aec43b695", - "display_name": "hayes.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.153Z", - "stale_timestamp": "2035-04-17T11:49:17.153Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.153Z", - "updated": "2025-04-17T11:49:17.153Z", - "insights_id": null, - "tags": [ - { - "key": "port", - "value": "digital", - "namespace": "compressing" - }, - { - "key": "alarm", - "value": "1080p", - "namespace": "compressing" - }, - { - "key": "port", - "value": "1080p", - "namespace": "compressing" - }, - { - "key": "monitor", - "value": "primary", - "namespace": "programming" - }, - { - "key": "card", - "value": "optical", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.153Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "3e4424ac-7763-41db-a029-e3119e6fae8a", - "display_name": "jones-mohr.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.135Z", - "stale_timestamp": "2035-04-17T11:49:17.135Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.135Z", - "updated": "2025-04-17T11:49:17.135Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "auxiliary", - "namespace": "copying" - }, - { - "key": "monitor", - "value": "mobile", - "namespace": "calculating" - }, - { - "key": "sensor", - "value": "1080p", - "namespace": "backing up" - }, - { - "key": "feed", - "value": "optical", - "namespace": "bypassing" - }, - { - "key": "card", - "value": "digital", - "namespace": "backing up" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.135Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "428ba845-6ccb-4bce-b4b7-8b85cad4bea3", - "display_name": "prohaska.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.167Z", - "stale_timestamp": "2035-04-17T11:49:17.167Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.167Z", - "updated": "2025-04-17T11:49:17.167Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "mobile", - "namespace": "connecting" - }, - { - "key": "pixel", - "value": "primary", - "namespace": "calculating" - }, - { - "key": "driver", - "value": "virtual", - "namespace": "quantifying" - }, - { - "key": "interface", - "value": "cross-platform", - "namespace": "calculating" - }, - { - "key": "system", - "value": "online", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.167Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "4315153c-7434-4ad5-94f4-fd33cef72476", - "display_name": "price.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.144Z", - "stale_timestamp": "2035-04-17T11:49:17.144Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.144Z", - "updated": "2025-04-17T11:49:17.144Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "solid state", - "namespace": "indexing" - }, - { - "key": "driver", - "value": "auxiliary", - "namespace": "parsing" - }, - { - "key": "capacitor", - "value": "back-end", - "namespace": "compressing" - }, - { - "key": "panel", - "value": "bluetooth", - "namespace": "transmitting" - }, - { - "key": "panel", - "value": "wireless", - "namespace": "programming" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.144Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "5476cbcd-2969-4c88-9e3b-011e4c1e9927", - "display_name": "walker.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.139Z", - "stale_timestamp": "2035-04-17T11:49:17.139Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.139Z", - "updated": "2025-04-17T11:49:17.139Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "back-end", - "namespace": "connecting" - }, - { - "key": "firewall", - "value": "back-end", - "namespace": "parsing" - }, - { - "key": "circuit", - "value": "optical", - "namespace": "programming" - }, - { - "key": "microchip", - "value": "wireless", - "namespace": "parsing" - }, - { - "key": "bus", - "value": "back-end", - "namespace": "bypassing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.139Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "5548df50-286c-49f1-bbaa-db9e57a17cc7", - "display_name": "lind.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.169Z", - "stale_timestamp": "2035-04-17T11:49:17.169Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.169Z", - "updated": "2025-04-17T11:49:17.169Z", - "insights_id": null, - "tags": [ - { - "key": "alarm", - "value": "neural", - "namespace": "indexing" - }, - { - "key": "transmitter", - "value": "1080p", - "namespace": "overriding" - }, - { - "key": "program", - "value": "bluetooth", - "namespace": "overriding" - }, - { - "key": "firewall", - "value": "1080p", - "namespace": "calculating" - }, - { - "key": "bus", - "value": "1080p", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.169Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - }, - { - "id": "5634e65c-02a9-4050-8331-799ff7619a5f", - "display_name": "morissette-stoltenberg.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.141Z", - "stale_timestamp": "2035-04-17T11:49:17.141Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.141Z", - "updated": "2025-04-17T11:49:17.141Z", - "insights_id": null, - "tags": [ - { - "key": "circuit", - "value": "optical", - "namespace": "transmitting" - }, - { - "key": "feed", - "value": "mobile", - "namespace": "calculating" - }, - { - "key": "panel", - "value": "cross-platform", - "namespace": "indexing" - }, - { - "key": "circuit", - "value": "primary", - "namespace": "connecting" - }, - { - "key": "bandwidth", - "value": "back-end", - "namespace": "transmitting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.141Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - } - ], - "meta": { - "total": 25, - "filter": "(os_major_version=8)", - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/systems?filter=%28os_major_version%3D8%29&limit=10&offset=0", - "last": "/api/compliance/v2/systems?filter=%28os_major_version%3D8%29&limit=10&offset=20", - "next": "/api/compliance/v2/systems?filter=%28os_major_version%3D8%29&limit=10&offset=10" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/systems/os_versions": { - "get": { - "summary": "Request the list of available OS versions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Systems are searchable using attributes `display_name`, `os_version`, `os_major_version`, `os_minor_version`, `assigned_or_scanned`, `never_reported`, `group_name`, `policies`, and `profile_ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Systems" - ], - "description": "This feature is exclusively used by the frontend.", - "operationId": "SystemsOS", - "deprecated": true, - "responses": { - "200": { - "description": "Lists available OS versions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of available OS versions": { - "value": [ - "8.0" - ], - "summary": "", - "description": "" - } - }, - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - } - } - } - } - } - }, - "/systems/{system_id}": { - "get": { - "summary": "Request a System", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "system_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Systems" - ], - "description": "Get information about one specific system.", - "operationId": "System", - "responses": { - "200": { - "description": "Returns a System", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a System": { - "value": { - "data": { - "id": "1b214511-b569-4cfa-8feb-8b8073e4d77d", - "display_name": "cormier.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.520Z", - "stale_timestamp": "2035-04-17T11:49:17.520Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.520Z", - "updated": "2025-04-17T11:49:17.520Z", - "insights_id": null, - "tags": [ - { - "key": "feed", - "value": "1080p", - "namespace": "backing up" - }, - { - "key": "protocol", - "value": "haptic", - "namespace": "connecting" - }, - { - "key": "feed", - "value": "open-source", - "namespace": "hacking" - }, - { - "key": "firewall", - "value": "solid state", - "namespace": "bypassing" - }, - { - "key": "program", - "value": "haptic", - "namespace": "overriding" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.520Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [] - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing System": { - "value": { - "errors": [ - "V2::System not found with ID 2caa6742-2cdd-4247-a0dd-b0422a28fe6e" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/policies/{policy_id}/systems": { - "get": { - "summary": "Request Systems assigned to a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "tags", - "in": "query", - "required": false, - "description": "An array of tags to narrow down the search results. In case the value contains symbols used for separators (`/` or `=`), they need to be encoded.<br>e.g.: `namespace/key=value`, `insights-client/selinux-config=SELINUX%3Denforcing`", - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "display_name", - "os_minor_version", - "os_version", - "groups", - "display_name:asc", - "display_name:desc", - "os_minor_version:asc", - "os_minor_version:desc", - "os_version:asc", - "os_version:desc", - "groups:asc", - "groups:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Systems are searchable using attributes `display_name`, `os_minor_version`, and `group_name`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Retrieve all of the systems assigned to a specific policy.", - "operationId": "PolicySystems", - "responses": { - "200": { - "description": "Lists Systems assigned to a Policy", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Systems": { - "value": { - "data": [ - { - "id": "00b0ebe8-4784-455a-aa84-cd2d0be93b26", - "display_name": "mueller.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.672Z", - "stale_timestamp": "2035-04-17T11:49:17.672Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.672Z", - "updated": "2025-04-17T11:49:17.672Z", - "insights_id": null, - "tags": [ - { - "key": "circuit", - "value": "digital", - "namespace": "copying" - }, - { - "key": "interface", - "value": "cross-platform", - "namespace": "copying" - }, - { - "key": "pixel", - "value": "haptic", - "namespace": "synthesizing" - }, - { - "key": "program", - "value": "optical", - "namespace": "backing up" - }, - { - "key": "microchip", - "value": "bluetooth", - "namespace": "copying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.672Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "0c2e1075-8559-425b-bd7a-a22f9c66f9d0", - "display_name": "schinner.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.596Z", - "stale_timestamp": "2035-04-17T11:49:17.596Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.596Z", - "updated": "2025-04-17T11:49:17.596Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "online", - "namespace": "bypassing" - }, - { - "key": "program", - "value": "virtual", - "namespace": "transmitting" - }, - { - "key": "bus", - "value": "back-end", - "namespace": "synthesizing" - }, - { - "key": "transmitter", - "value": "mobile", - "namespace": "quantifying" - }, - { - "key": "transmitter", - "value": "bluetooth", - "namespace": "navigating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.596Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "160d3c0e-85dd-4f4a-b6b7-4cda7afc413b", - "display_name": "gottlieb-dubuque.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.757Z", - "stale_timestamp": "2035-04-17T11:49:17.757Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.757Z", - "updated": "2025-04-17T11:49:17.757Z", - "insights_id": null, - "tags": [ - { - "key": "panel", - "value": "primary", - "namespace": "parsing" - }, - { - "key": "monitor", - "value": "neural", - "namespace": "hacking" - }, - { - "key": "sensor", - "value": "online", - "namespace": "overriding" - }, - { - "key": "system", - "value": "redundant", - "namespace": "calculating" - }, - { - "key": "circuit", - "value": "multi-byte", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.757Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "259fd8f6-e193-45a3-b7b1-2309ff60bcc6", - "display_name": "wisoky.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.607Z", - "stale_timestamp": "2035-04-17T11:49:17.607Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.607Z", - "updated": "2025-04-17T11:49:17.607Z", - "insights_id": null, - "tags": [ - { - "key": "panel", - "value": "wireless", - "namespace": "backing up" - }, - { - "key": "sensor", - "value": "haptic", - "namespace": "hacking" - }, - { - "key": "hard drive", - "value": "wireless", - "namespace": "calculating" - }, - { - "key": "circuit", - "value": "back-end", - "namespace": "copying" - }, - { - "key": "pixel", - "value": "haptic", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.607Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "2cd0f854-8115-4171-b8b7-707fd7f0e974", - "display_name": "zieme.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.557Z", - "stale_timestamp": "2035-04-17T11:49:17.557Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.557Z", - "updated": "2025-04-17T11:49:17.557Z", - "insights_id": null, - "tags": [ - { - "key": "bandwidth", - "value": "mobile", - "namespace": "compressing" - }, - { - "key": "bus", - "value": "wireless", - "namespace": "compressing" - }, - { - "key": "pixel", - "value": "multi-byte", - "namespace": "indexing" - }, - { - "key": "circuit", - "value": "auxiliary", - "namespace": "hacking" - }, - { - "key": "program", - "value": "neural", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.557Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "2fec6942-5f98-4aea-af2d-5c74401febd6", - "display_name": "connelly.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.745Z", - "stale_timestamp": "2035-04-17T11:49:17.745Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.745Z", - "updated": "2025-04-17T11:49:17.746Z", - "insights_id": null, - "tags": [ - { - "key": "pixel", - "value": "open-source", - "namespace": "copying" - }, - { - "key": "protocol", - "value": "primary", - "namespace": "generating" - }, - { - "key": "bus", - "value": "online", - "namespace": "quantifying" - }, - { - "key": "sensor", - "value": "auxiliary", - "namespace": "calculating" - }, - { - "key": "panel", - "value": "digital", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.745Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "427a6c96-ce60-476c-9e21-6b8745a35c48", - "display_name": "volkman.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.714Z", - "stale_timestamp": "2035-04-17T11:49:17.714Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.714Z", - "updated": "2025-04-17T11:49:17.714Z", - "insights_id": null, - "tags": [ - { - "key": "alarm", - "value": "primary", - "namespace": "backing up" - }, - { - "key": "array", - "value": "redundant", - "namespace": "quantifying" - }, - { - "key": "sensor", - "value": "back-end", - "namespace": "indexing" - }, - { - "key": "sensor", - "value": "neural", - "namespace": "transmitting" - }, - { - "key": "port", - "value": "redundant", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.714Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "44f15598-a0aa-4e1f-a727-336a76107ff4", - "display_name": "kulas-schaden.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.725Z", - "stale_timestamp": "2035-04-17T11:49:17.725Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.725Z", - "updated": "2025-04-17T11:49:17.725Z", - "insights_id": null, - "tags": [ - { - "key": "matrix", - "value": "haptic", - "namespace": "copying" - }, - { - "key": "port", - "value": "1080p", - "namespace": "programming" - }, - { - "key": "program", - "value": "haptic", - "namespace": "generating" - }, - { - "key": "feed", - "value": "wireless", - "namespace": "calculating" - }, - { - "key": "driver", - "value": "cross-platform", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.725Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "475b347e-b280-4017-bd0b-c383c15ffa8f", - "display_name": "king.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.767Z", - "stale_timestamp": "2035-04-17T11:49:17.767Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.767Z", - "updated": "2025-04-17T11:49:17.767Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "mobile", - "namespace": "generating" - }, - { - "key": "matrix", - "value": "wireless", - "namespace": "calculating" - }, - { - "key": "panel", - "value": "open-source", - "namespace": "transmitting" - }, - { - "key": "system", - "value": "primary", - "namespace": "programming" - }, - { - "key": "transmitter", - "value": "mobile", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.767Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "48b2b4ba-710b-4586-a251-40f1693becc1", - "display_name": "hessel.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.788Z", - "stale_timestamp": "2035-04-17T11:49:17.788Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.788Z", - "updated": "2025-04-17T11:49:17.788Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "open-source", - "namespace": "hacking" - }, - { - "key": "driver", - "value": "back-end", - "namespace": "connecting" - }, - { - "key": "panel", - "value": "mobile", - "namespace": "backing up" - }, - { - "key": "circuit", - "value": "digital", - "namespace": "compressing" - }, - { - "key": "monitor", - "value": "neural", - "namespace": "transmitting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.788Z", - "os_major_version": 8, - "os_minor_version": 0 - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies/90a7be96-12c3-430d-a7ea-2a3d4a9c110e/systems?limit=10&offset=0", - "last": "/api/compliance/v2/policies/90a7be96-12c3-430d-a7ea-2a3d4a9c110e/systems?limit=10&offset=20", - "next": "/api/compliance/v2/policies/90a7be96-12c3-430d-a7ea-2a3d4a9c110e/systems?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Systems sorted by \"os_minor_version:asc\"": { - "value": { - "data": [ - { - "id": "04c833be-e1ff-4302-bc63-9b0301a60691", - "display_name": "rodriguez-jakubowski.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.991Z", - "stale_timestamp": "2035-04-17T11:49:17.991Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.991Z", - "updated": "2025-04-17T11:49:17.991Z", - "insights_id": null, - "tags": [ - { - "key": "capacitor", - "value": "online", - "namespace": "indexing" - }, - { - "key": "pixel", - "value": "redundant", - "namespace": "bypassing" - }, - { - "key": "pixel", - "value": "digital", - "namespace": "generating" - }, - { - "key": "protocol", - "value": "optical", - "namespace": "connecting" - }, - { - "key": "interface", - "value": "digital", - "namespace": "hacking" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.991Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "1ec805eb-2e9e-4147-b7a7-4e3aeb850ec7", - "display_name": "daugherty.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.954Z", - "stale_timestamp": "2035-04-17T11:49:17.954Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.954Z", - "updated": "2025-04-17T11:49:17.954Z", - "insights_id": null, - "tags": [ - { - "key": "circuit", - "value": "neural", - "namespace": "transmitting" - }, - { - "key": "alarm", - "value": "solid state", - "namespace": "copying" - }, - { - "key": "transmitter", - "value": "back-end", - "namespace": "navigating" - }, - { - "key": "pixel", - "value": "neural", - "namespace": "hacking" - }, - { - "key": "interface", - "value": "1080p", - "namespace": "calculating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.954Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "29034aad-9a59-457d-97b0-346d84484700", - "display_name": "bartell.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.927Z", - "stale_timestamp": "2035-04-17T11:49:17.927Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.927Z", - "updated": "2025-04-17T11:49:17.927Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "cross-platform", - "namespace": "synthesizing" - }, - { - "key": "circuit", - "value": "bluetooth", - "namespace": "compressing" - }, - { - "key": "firewall", - "value": "primary", - "namespace": "parsing" - }, - { - "key": "system", - "value": "optical", - "namespace": "hacking" - }, - { - "key": "feed", - "value": "virtual", - "namespace": "indexing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.927Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "36a81342-baba-47ce-a459-bc4b64c2057a", - "display_name": "mohr.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.033Z", - "stale_timestamp": "2035-04-17T11:49:18.033Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.033Z", - "updated": "2025-04-17T11:49:18.033Z", - "insights_id": null, - "tags": [ - { - "key": "matrix", - "value": "haptic", - "namespace": "parsing" - }, - { - "key": "matrix", - "value": "multi-byte", - "namespace": "parsing" - }, - { - "key": "transmitter", - "value": "bluetooth", - "namespace": "programming" - }, - { - "key": "alarm", - "value": "mobile", - "namespace": "navigating" - }, - { - "key": "microchip", - "value": "haptic", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.033Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "40387b9a-a817-445a-a564-9845cd8ac756", - "display_name": "grimes-bahringer.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.095Z", - "stale_timestamp": "2035-04-17T11:49:18.095Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.095Z", - "updated": "2025-04-17T11:49:18.095Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "1080p", - "namespace": "backing up" - }, - { - "key": "circuit", - "value": "multi-byte", - "namespace": "copying" - }, - { - "key": "pixel", - "value": "optical", - "namespace": "calculating" - }, - { - "key": "system", - "value": "redundant", - "namespace": "indexing" - }, - { - "key": "port", - "value": "virtual", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.095Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "4622115a-64c7-4d95-8ba5-510b94c34fa2", - "display_name": "hessel.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:17.966Z", - "stale_timestamp": "2035-04-17T11:49:17.966Z", - "stale_warning_timestamp": "2035-04-24T11:49:17.966Z", - "updated": "2025-04-17T11:49:17.966Z", - "insights_id": null, - "tags": [ - { - "key": "system", - "value": "digital", - "namespace": "synthesizing" - }, - { - "key": "firewall", - "value": "cross-platform", - "namespace": "calculating" - }, - { - "key": "matrix", - "value": "solid state", - "namespace": "quantifying" - }, - { - "key": "circuit", - "value": "solid state", - "namespace": "hacking" - }, - { - "key": "hard drive", - "value": "virtual", - "namespace": "transmitting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:17.966Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "4b807915-a574-460f-a516-befe6b028226", - "display_name": "veum-runte.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.086Z", - "stale_timestamp": "2035-04-17T11:49:18.086Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.086Z", - "updated": "2025-04-17T11:49:18.086Z", - "insights_id": null, - "tags": [ - { - "key": "pixel", - "value": "digital", - "namespace": "quantifying" - }, - { - "key": "card", - "value": "bluetooth", - "namespace": "connecting" - }, - { - "key": "matrix", - "value": "wireless", - "namespace": "generating" - }, - { - "key": "bus", - "value": "optical", - "namespace": "parsing" - }, - { - "key": "feed", - "value": "wireless", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.086Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "4eb35c85-b385-419d-96ca-3c38b59250af", - "display_name": "bode.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.075Z", - "stale_timestamp": "2035-04-17T11:49:18.075Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.075Z", - "updated": "2025-04-17T11:49:18.075Z", - "insights_id": null, - "tags": [ - { - "key": "monitor", - "value": "virtual", - "namespace": "copying" - }, - { - "key": "panel", - "value": "primary", - "namespace": "transmitting" - }, - { - "key": "monitor", - "value": "haptic", - "namespace": "transmitting" - }, - { - "key": "monitor", - "value": "mobile", - "namespace": "synthesizing" - }, - { - "key": "card", - "value": "optical", - "namespace": "transmitting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.075Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "565b403c-a5da-4861-a921-6512c42741bd", - "display_name": "schimmel-hartmann.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.001Z", - "stale_timestamp": "2035-04-17T11:49:18.001Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.001Z", - "updated": "2025-04-17T11:49:18.001Z", - "insights_id": null, - "tags": [ - { - "key": "interface", - "value": "cross-platform", - "namespace": "parsing" - }, - { - "key": "firewall", - "value": "wireless", - "namespace": "synthesizing" - }, - { - "key": "system", - "value": "neural", - "namespace": "synthesizing" - }, - { - "key": "capacitor", - "value": "haptic", - "namespace": "overriding" - }, - { - "key": "protocol", - "value": "primary", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.001Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "5ca9840f-6c10-4b1c-8db0-d40f97bf4742", - "display_name": "larson-prohaska.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.135Z", - "stale_timestamp": "2035-04-17T11:49:18.135Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.135Z", - "updated": "2025-04-17T11:49:18.136Z", - "insights_id": null, - "tags": [ - { - "key": "port", - "value": "digital", - "namespace": "calculating" - }, - { - "key": "application", - "value": "digital", - "namespace": "navigating" - }, - { - "key": "interface", - "value": "open-source", - "namespace": "calculating" - }, - { - "key": "port", - "value": "1080p", - "namespace": "navigating" - }, - { - "key": "monitor", - "value": "open-source", - "namespace": "hacking" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.135Z", - "os_major_version": 8, - "os_minor_version": 0 - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0, - "sort_by": "os_minor_version" - }, - "links": { - "first": "/api/compliance/v2/policies/7e31f6ab-b24e-403e-aac4-5f1dbf2c9cdd/systems?limit=10&offset=0&sort_by=os_minor_version", - "last": "/api/compliance/v2/policies/7e31f6ab-b24e-403e-aac4-5f1dbf2c9cdd/systems?limit=10&offset=20&sort_by=os_minor_version", - "next": "/api/compliance/v2/policies/7e31f6ab-b24e-403e-aac4-5f1dbf2c9cdd/systems?limit=10&offset=10&sort_by=os_minor_version" - } - }, - "summary": "", - "description": "" - }, - "List of Systems filtered by \"(os_minor_version=0)\"": { - "value": { - "data": [ - { - "id": "0bcbe1fa-886d-4d15-8bee-dbed68f648fc", - "display_name": "ullrich-ritchie.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.211Z", - "stale_timestamp": "2035-04-17T11:49:18.211Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.211Z", - "updated": "2025-04-17T11:49:18.211Z", - "insights_id": null, - "tags": [ - { - "key": "protocol", - "value": "open-source", - "namespace": "calculating" - }, - { - "key": "matrix", - "value": "neural", - "namespace": "hacking" - }, - { - "key": "bus", - "value": "multi-byte", - "namespace": "calculating" - }, - { - "key": "capacitor", - "value": "multi-byte", - "namespace": "connecting" - }, - { - "key": "circuit", - "value": "optical", - "namespace": "bypassing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.211Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "13b2593c-3b11-48f9-8d07-e8c7c81a5902", - "display_name": "altenwerth-farrell.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.333Z", - "stale_timestamp": "2035-04-17T11:49:18.333Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.333Z", - "updated": "2025-04-17T11:49:18.333Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "wireless", - "namespace": "bypassing" - }, - { - "key": "circuit", - "value": "bluetooth", - "namespace": "copying" - }, - { - "key": "transmitter", - "value": "virtual", - "namespace": "parsing" - }, - { - "key": "microchip", - "value": "open-source", - "namespace": "transmitting" - }, - { - "key": "driver", - "value": "multi-byte", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.333Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "20f39def-147f-4439-ab2d-655877978323", - "display_name": "quigley.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.293Z", - "stale_timestamp": "2035-04-17T11:49:18.293Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.293Z", - "updated": "2025-04-17T11:49:18.293Z", - "insights_id": null, - "tags": [ - { - "key": "capacitor", - "value": "redundant", - "namespace": "transmitting" - }, - { - "key": "application", - "value": "cross-platform", - "namespace": "calculating" - }, - { - "key": "feed", - "value": "cross-platform", - "namespace": "parsing" - }, - { - "key": "bandwidth", - "value": "virtual", - "namespace": "calculating" - }, - { - "key": "interface", - "value": "open-source", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.293Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "422d3837-9ac7-4f6b-80a2-db0ffb629a12", - "display_name": "murray.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.401Z", - "stale_timestamp": "2035-04-17T11:49:18.401Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.401Z", - "updated": "2025-04-17T11:49:18.401Z", - "insights_id": null, - "tags": [ - { - "key": "port", - "value": "1080p", - "namespace": "connecting" - }, - { - "key": "firewall", - "value": "multi-byte", - "namespace": "indexing" - }, - { - "key": "transmitter", - "value": "solid state", - "namespace": "copying" - }, - { - "key": "protocol", - "value": "auxiliary", - "namespace": "copying" - }, - { - "key": "system", - "value": "multi-byte", - "namespace": "programming" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.401Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "43269bf8-14b9-49cb-99e1-aa0b09407bfe", - "display_name": "conroy-hauck.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.433Z", - "stale_timestamp": "2035-04-17T11:49:18.433Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.433Z", - "updated": "2025-04-17T11:49:18.433Z", - "insights_id": null, - "tags": [ - { - "key": "bus", - "value": "mobile", - "namespace": "copying" - }, - { - "key": "monitor", - "value": "auxiliary", - "namespace": "connecting" - }, - { - "key": "circuit", - "value": "cross-platform", - "namespace": "generating" - }, - { - "key": "protocol", - "value": "wireless", - "namespace": "connecting" - }, - { - "key": "panel", - "value": "multi-byte", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.433Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "461bed03-bbb9-4b33-940d-23bebc3863f7", - "display_name": "lueilwitz.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.363Z", - "stale_timestamp": "2035-04-17T11:49:18.363Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.363Z", - "updated": "2025-04-17T11:49:18.363Z", - "insights_id": null, - "tags": [ - { - "key": "pixel", - "value": "solid state", - "namespace": "generating" - }, - { - "key": "transmitter", - "value": "redundant", - "namespace": "overriding" - }, - { - "key": "firewall", - "value": "back-end", - "namespace": "bypassing" - }, - { - "key": "firewall", - "value": "redundant", - "namespace": "indexing" - }, - { - "key": "system", - "value": "back-end", - "namespace": "hacking" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.363Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "4930e30b-8728-4083-b503-df83e942b209", - "display_name": "gutkowski.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.185Z", - "stale_timestamp": "2035-04-17T11:49:18.185Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.185Z", - "updated": "2025-04-17T11:49:18.185Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "redundant", - "namespace": "transmitting" - }, - { - "key": "interface", - "value": "primary", - "namespace": "compressing" - }, - { - "key": "panel", - "value": "solid state", - "namespace": "backing up" - }, - { - "key": "monitor", - "value": "mobile", - "namespace": "generating" - }, - { - "key": "monitor", - "value": "solid state", - "namespace": "calculating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.185Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "5acff4fc-d626-4c4b-8774-03c97c8bb926", - "display_name": "murazik-kihn.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.444Z", - "stale_timestamp": "2035-04-17T11:49:18.444Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.444Z", - "updated": "2025-04-17T11:49:18.444Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "multi-byte", - "namespace": "parsing" - }, - { - "key": "driver", - "value": "auxiliary", - "namespace": "quantifying" - }, - { - "key": "circuit", - "value": "mobile", - "namespace": "navigating" - }, - { - "key": "card", - "value": "haptic", - "namespace": "hacking" - }, - { - "key": "protocol", - "value": "1080p", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.444Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "928f30a8-414b-4306-92a3-10032369bfb6", - "display_name": "stamm.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.312Z", - "stale_timestamp": "2035-04-17T11:49:18.312Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.312Z", - "updated": "2025-04-17T11:49:18.312Z", - "insights_id": null, - "tags": [ - { - "key": "bandwidth", - "value": "auxiliary", - "namespace": "transmitting" - }, - { - "key": "capacitor", - "value": "wireless", - "namespace": "generating" - }, - { - "key": "monitor", - "value": "open-source", - "namespace": "bypassing" - }, - { - "key": "sensor", - "value": "virtual", - "namespace": "calculating" - }, - { - "key": "capacitor", - "value": "optical", - "namespace": "quantifying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.312Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "94fbe75a-f03f-49b7-8d64-10d326c138bf", - "display_name": "hand.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:18.303Z", - "stale_timestamp": "2035-04-17T11:49:18.303Z", - "stale_warning_timestamp": "2035-04-24T11:49:18.303Z", - "updated": "2025-04-17T11:49:18.303Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "1080p", - "namespace": "copying" - }, - { - "key": "capacitor", - "value": "redundant", - "namespace": "indexing" - }, - { - "key": "panel", - "value": "redundant", - "namespace": "connecting" - }, - { - "key": "monitor", - "value": "neural", - "namespace": "calculating" - }, - { - "key": "bus", - "value": "back-end", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:18.303Z", - "os_major_version": 8, - "os_minor_version": 0 - } - ], - "meta": { - "total": 25, - "filter": "(os_minor_version=0)", - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies/ad6deb96-eaf8-432d-a67a-e2250a6e8764/systems?filter=%28os_minor_version%3D0%29&limit=10&offset=0", - "last": "/api/compliance/v2/policies/ad6deb96-eaf8-432d-a67a-e2250a6e8764/systems?filter=%28os_minor_version%3D0%29&limit=10&offset=20", - "next": "/api/compliance/v2/policies/ad6deb96-eaf8-432d-a67a-e2250a6e8764/systems?filter=%28os_minor_version%3D0%29&limit=10&offset=10" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "post": { - "summary": "Bulk assign Systems to a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "This feature is exclusively used by the frontend", - "deprecated": true, - "operationId": "AssignSystems", - "responses": { - "202": { - "description": "Assigns all specified systems and unassigns the rest", - "content": { - "application/vnd.api+json": { - "examples": { - "List of assigned Systems": { - "value": { - "data": [ - { - "id": "0228f5d8-6c91-4f55-ad47-ff170ea9aa0e", - "display_name": "turcotte.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.436Z", - "stale_timestamp": "2035-04-17T11:49:19.436Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.436Z", - "updated": "2025-04-17T11:49:19.436Z", - "insights_id": null, - "tags": [ - { - "key": "panel", - "value": "wireless", - "namespace": "connecting" - }, - { - "key": "capacitor", - "value": "multi-byte", - "namespace": "indexing" - }, - { - "key": "pixel", - "value": "cross-platform", - "namespace": "navigating" - }, - { - "key": "interface", - "value": "redundant", - "namespace": "hacking" - }, - { - "key": "system", - "value": "haptic", - "namespace": "backing up" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.436Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "0f051989-b696-48e7-a239-c22c640b98ac", - "display_name": "hirthe.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.447Z", - "stale_timestamp": "2035-04-17T11:49:19.447Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.447Z", - "updated": "2025-04-17T11:49:19.447Z", - "insights_id": null, - "tags": [ - { - "key": "interface", - "value": "primary", - "namespace": "hacking" - }, - { - "key": "hard drive", - "value": "solid state", - "namespace": "navigating" - }, - { - "key": "panel", - "value": "mobile", - "namespace": "bypassing" - }, - { - "key": "alarm", - "value": "solid state", - "namespace": "synthesizing" - }, - { - "key": "driver", - "value": "neural", - "namespace": "quantifying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.447Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "1dc4a86e-52ae-4228-b32f-692e696f974b", - "display_name": "goodwin-romaguera.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.442Z", - "stale_timestamp": "2035-04-17T11:49:19.442Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.442Z", - "updated": "2025-04-17T11:49:19.442Z", - "insights_id": null, - "tags": [ - { - "key": "feed", - "value": "cross-platform", - "namespace": "backing up" - }, - { - "key": "panel", - "value": "wireless", - "namespace": "navigating" - }, - { - "key": "circuit", - "value": "redundant", - "namespace": "backing up" - }, - { - "key": "hard drive", - "value": "back-end", - "namespace": "quantifying" - }, - { - "key": "capacitor", - "value": "optical", - "namespace": "copying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.442Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "2420b443-ea84-48e4-a058-622cb5aee1f0", - "display_name": "cole-williamson.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.459Z", - "stale_timestamp": "2035-04-17T11:49:19.459Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.459Z", - "updated": "2025-04-17T11:49:19.459Z", - "insights_id": null, - "tags": [ - { - "key": "monitor", - "value": "open-source", - "namespace": "overriding" - }, - { - "key": "monitor", - "value": "haptic", - "namespace": "generating" - }, - { - "key": "panel", - "value": "back-end", - "namespace": "parsing" - }, - { - "key": "monitor", - "value": "bluetooth", - "namespace": "connecting" - }, - { - "key": "port", - "value": "wireless", - "namespace": "synthesizing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.459Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "26de9105-8ddb-4cfa-bbb2-3863594058bb", - "display_name": "morar.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.460Z", - "stale_timestamp": "2035-04-17T11:49:19.460Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.460Z", - "updated": "2025-04-17T11:49:19.460Z", - "insights_id": null, - "tags": [ - { - "key": "monitor", - "value": "optical", - "namespace": "calculating" - }, - { - "key": "circuit", - "value": "multi-byte", - "namespace": "indexing" - }, - { - "key": "application", - "value": "haptic", - "namespace": "synthesizing" - }, - { - "key": "firewall", - "value": "auxiliary", - "namespace": "compressing" - }, - { - "key": "bus", - "value": "auxiliary", - "namespace": "compressing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.460Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "45c3d12d-983a-48df-b419-1c8ef50b4540", - "display_name": "fahey.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.456Z", - "stale_timestamp": "2035-04-17T11:49:19.456Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.456Z", - "updated": "2025-04-17T11:49:19.456Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "mobile", - "namespace": "connecting" - }, - { - "key": "bus", - "value": "primary", - "namespace": "programming" - }, - { - "key": "sensor", - "value": "redundant", - "namespace": "compressing" - }, - { - "key": "pixel", - "value": "wireless", - "namespace": "copying" - }, - { - "key": "matrix", - "value": "wireless", - "namespace": "quantifying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.456Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "4a465a58-c47e-481b-8251-9c1fefc9b89c", - "display_name": "stamm.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.457Z", - "stale_timestamp": "2035-04-17T11:49:19.457Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.457Z", - "updated": "2025-04-17T11:49:19.457Z", - "insights_id": null, - "tags": [ - { - "key": "monitor", - "value": "back-end", - "namespace": "transmitting" - }, - { - "key": "card", - "value": "optical", - "namespace": "calculating" - }, - { - "key": "card", - "value": "virtual", - "namespace": "quantifying" - }, - { - "key": "monitor", - "value": "back-end", - "namespace": "indexing" - }, - { - "key": "transmitter", - "value": "online", - "namespace": "programming" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.457Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "4f202d7c-c552-4f89-97c0-931077adefe2", - "display_name": "rau-mitchell.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.462Z", - "stale_timestamp": "2035-04-17T11:49:19.462Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.462Z", - "updated": "2025-04-17T11:49:19.462Z", - "insights_id": null, - "tags": [ - { - "key": "panel", - "value": "bluetooth", - "namespace": "overriding" - }, - { - "key": "capacitor", - "value": "multi-byte", - "namespace": "programming" - }, - { - "key": "system", - "value": "wireless", - "namespace": "quantifying" - }, - { - "key": "port", - "value": "haptic", - "namespace": "indexing" - }, - { - "key": "sensor", - "value": "primary", - "namespace": "copying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.462Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "53281be1-2596-4434-a63b-c64ddd139b0e", - "display_name": "maggio-hamill.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.434Z", - "stale_timestamp": "2035-04-17T11:49:19.434Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.434Z", - "updated": "2025-04-17T11:49:19.434Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "haptic", - "namespace": "hacking" - }, - { - "key": "interface", - "value": "wireless", - "namespace": "programming" - }, - { - "key": "application", - "value": "mobile", - "namespace": "quantifying" - }, - { - "key": "transmitter", - "value": "online", - "namespace": "calculating" - }, - { - "key": "firewall", - "value": "redundant", - "namespace": "bypassing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.434Z", - "os_major_version": 8, - "os_minor_version": 0 - }, - { - "id": "55bff9c6-ab8a-47de-a9c7-e677ac8acc38", - "display_name": "will.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.432Z", - "stale_timestamp": "2035-04-17T11:49:19.432Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.432Z", - "updated": "2025-04-17T11:49:19.432Z", - "insights_id": null, - "tags": [ - { - "key": "protocol", - "value": "1080p", - "namespace": "calculating" - }, - { - "key": "bus", - "value": "wireless", - "namespace": "calculating" - }, - { - "key": "protocol", - "value": "haptic", - "namespace": "backing up" - }, - { - "key": "microchip", - "value": "back-end", - "namespace": "parsing" - }, - { - "key": "bandwidth", - "value": "cross-platform", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.432Z", - "os_major_version": 8, - "os_minor_version": 0 - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies/aba5be64-ae18-4344-a5ae-8dedd795dc6b/systems?limit=10&offset=0", - "last": "/api/compliance/v2/policies/aba5be64-ae18-4344-a5ae-8dedd795dc6b/systems?limit=10&offset=20", - "next": "/api/compliance/v2/policies/aba5be64-ae18-4344-a5ae-8dedd795dc6b/systems?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - } - } - }, - "requestBody": { - "content": { - "application/vnd.api+json": { - "schema": { - "type": "object", - "properties": { - "ids": { - "type": "array", - "items": { - "type": "string", - "examples": [ - "565220d4-0a0e-424b-ae75-b48fc0e528a4" - ] - } - } - } - } - } - } - } - } - }, - "/policies/{policy_id}/systems/os_versions": { - "get": { - "summary": "Request the list of available OS versions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Systems are searchable using attributes `display_name`, `os_version`, `os_major_version`, `os_minor_version`, `assigned_or_scanned`, `never_reported`, `group_name`, `policies`, and `profile_ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Systems" - ], - "description": "This feature is exclusively used by the frontend", - "operationId": "PolicySystemsOS", - "deprecated": true, - "responses": { - "200": { - "description": "Lists available OS versions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of available OS versions": { - "value": [ - "8.0" - ], - "summary": "", - "description": "" - } - }, - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - } - } - } - } - } - }, - "/policies/{policy_id}/systems/{system_id}": { - "patch": { - "summary": "Assign a System to a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "system_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Assign a specific system to a specific policy.", - "operationId": "AssignSystem", - "responses": { - "202": { - "description": "Assigns a System to a Policy", - "content": { - "application/vnd.api+json": { - "examples": { - "Assigns a System to a Policy": { - "value": { - "data": { - "id": "a08e7c76-6046-49cf-99ae-7d40e6e8cf8b", - "display_name": "ruecker.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.791Z", - "stale_timestamp": "2035-04-17T11:49:19.791Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.791Z", - "updated": "2025-04-17T11:49:19.791Z", - "insights_id": null, - "tags": [ - { - "key": "interface", - "value": "open-source", - "namespace": "backing up" - }, - { - "key": "transmitter", - "value": "back-end", - "namespace": "indexing" - }, - { - "key": "alarm", - "value": "back-end", - "namespace": "transmitting" - }, - { - "key": "array", - "value": "haptic", - "namespace": "synthesizing" - }, - { - "key": "monitor", - "value": "online", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.791Z", - "os_major_version": 8, - "os_minor_version": 0 - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Assigns a System to a Policy": { - "value": { - "errors": [ - "V2::System not found with ID a29428bc-2405-4513-9c80-c569aa93dffb" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "delete": { - "summary": "Unassign a System from a Policy", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "system_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Remove a specific system from a specific policy.", - "operationId": "UnassignSystem", - "responses": { - "202": { - "description": "Unassigns a System from a Policy", - "content": { - "application/vnd.api+json": { - "examples": { - "Unassigns a System from a Policy": { - "value": { - "data": { - "id": "210f27db-3a51-4b33-9965-8b3f3ee53c19", - "display_name": "jakubowski.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:19.861Z", - "stale_timestamp": "2035-04-17T11:49:19.861Z", - "stale_warning_timestamp": "2035-04-24T11:49:19.861Z", - "updated": "2025-04-17T11:49:19.861Z", - "insights_id": null, - "tags": [ - { - "key": "panel", - "value": "mobile", - "namespace": "overriding" - }, - { - "key": "feed", - "value": "1080p", - "namespace": "compressing" - }, - { - "key": "protocol", - "value": "virtual", - "namespace": "bypassing" - }, - { - "key": "array", - "value": "bluetooth", - "namespace": "synthesizing" - }, - { - "key": "sensor", - "value": "virtual", - "namespace": "compressing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:19.861Z", - "os_major_version": 8, - "os_minor_version": 0 - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when unassigning a non-existing System": { - "value": { - "errors": [ - "V2::System not found with ID 9bf5cfd2-0d81-49b8-81b1-b4a537bcfce7" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/reports/{report_id}/systems": { - "get": { - "summary": "Request Systems assigned to a Report", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "tags", - "in": "query", - "required": false, - "description": "An array of tags to narrow down the search results. In case the value contains symbols used for separators (`/` or `=`), they need to be encoded.<br>e.g.: `namespace/key=value`, `insights-client/selinux-config=SELINUX%3Denforcing`", - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "display_name", - "os_minor_version", - "os_version", - "groups", - "display_name:asc", - "display_name:desc", - "os_minor_version:asc", - "os_minor_version:desc", - "os_version:asc", - "os_version:desc", - "groups:asc", - "groups:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Systems are searchable using attributes `display_name`, `os_minor_version`, `never_reported`, and `group_name`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve all of the systems for a specific report.", - "operationId": "ReportSystems", - "responses": { - "200": { - "description": "Lists Systems assigned to a Report", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Systems": { - "value": { - "data": [ - { - "id": "07d5071c-93fc-4cb0-bf93-971bd3b8ba60", - "display_name": "stoltenberg-mitchell.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.307Z", - "stale_timestamp": "2035-04-17T11:49:20.307Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.307Z", - "updated": "2025-04-17T11:49:20.307Z", - "insights_id": null, - "tags": [ - { - "key": "card", - "value": "wireless", - "namespace": "connecting" - }, - { - "key": "panel", - "value": "neural", - "namespace": "transmitting" - }, - { - "key": "pixel", - "value": "bluetooth", - "namespace": "hacking" - }, - { - "key": "firewall", - "value": "mobile", - "namespace": "navigating" - }, - { - "key": "capacitor", - "value": "digital", - "namespace": "navigating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.307Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "0a3203ca-003c-419b-9d66-63b613e11d97", - "display_name": "schamberger.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.287Z", - "stale_timestamp": "2035-04-17T11:49:20.287Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.287Z", - "updated": "2025-04-17T11:49:20.287Z", - "insights_id": null, - "tags": [ - { - "key": "firewall", - "value": "bluetooth", - "namespace": "parsing" - }, - { - "key": "system", - "value": "virtual", - "namespace": "indexing" - }, - { - "key": "matrix", - "value": "cross-platform", - "namespace": "quantifying" - }, - { - "key": "application", - "value": "bluetooth", - "namespace": "generating" - }, - { - "key": "firewall", - "value": "redundant", - "namespace": "indexing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.287Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "10305272-6038-4277-a7cf-db22ea111c6b", - "display_name": "mayer.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.368Z", - "stale_timestamp": "2035-04-17T11:49:20.368Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.368Z", - "updated": "2025-04-17T11:49:20.368Z", - "insights_id": null, - "tags": [ - { - "key": "transmitter", - "value": "primary", - "namespace": "connecting" - }, - { - "key": "protocol", - "value": "solid state", - "namespace": "programming" - }, - { - "key": "pixel", - "value": "back-end", - "namespace": "connecting" - }, - { - "key": "feed", - "value": "primary", - "namespace": "bypassing" - }, - { - "key": "bandwidth", - "value": "neural", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.368Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "13045e5f-ccaa-4721-8488-938802281621", - "display_name": "dietrich-crona.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.500Z", - "stale_timestamp": "2035-04-17T11:49:20.500Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.500Z", - "updated": "2025-04-17T11:49:20.500Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "open-source", - "namespace": "quantifying" - }, - { - "key": "card", - "value": "virtual", - "namespace": "generating" - }, - { - "key": "firewall", - "value": "bluetooth", - "namespace": "parsing" - }, - { - "key": "application", - "value": "solid state", - "namespace": "quantifying" - }, - { - "key": "pixel", - "value": "primary", - "namespace": "backing up" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.500Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "2cf24058-09e4-4c03-a5a4-39965276666c", - "display_name": "abshire.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.479Z", - "stale_timestamp": "2035-04-17T11:49:20.479Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.479Z", - "updated": "2025-04-17T11:49:20.479Z", - "insights_id": null, - "tags": [ - { - "key": "protocol", - "value": "neural", - "namespace": "compressing" - }, - { - "key": "driver", - "value": "primary", - "namespace": "generating" - }, - { - "key": "application", - "value": "back-end", - "namespace": "bypassing" - }, - { - "key": "interface", - "value": "haptic", - "namespace": "overriding" - }, - { - "key": "card", - "value": "cross-platform", - "namespace": "calculating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.479Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "3fe0f282-3a62-4851-a686-68e761be241d", - "display_name": "marquardt.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.246Z", - "stale_timestamp": "2035-04-17T11:49:20.246Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.246Z", - "updated": "2025-04-17T11:49:20.246Z", - "insights_id": null, - "tags": [ - { - "key": "port", - "value": "1080p", - "namespace": "overriding" - }, - { - "key": "driver", - "value": "virtual", - "namespace": "hacking" - }, - { - "key": "panel", - "value": "optical", - "namespace": "calculating" - }, - { - "key": "monitor", - "value": "cross-platform", - "namespace": "indexing" - }, - { - "key": "sensor", - "value": "online", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.246Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "528cc4b6-fc67-42ec-844b-557e26e3edcd", - "display_name": "labadie-waters.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.418Z", - "stale_timestamp": "2035-04-17T11:49:20.418Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.418Z", - "updated": "2025-04-17T11:49:20.418Z", - "insights_id": null, - "tags": [ - { - "key": "transmitter", - "value": "cross-platform", - "namespace": "overriding" - }, - { - "key": "system", - "value": "primary", - "namespace": "parsing" - }, - { - "key": "program", - "value": "bluetooth", - "namespace": "overriding" - }, - { - "key": "application", - "value": "auxiliary", - "namespace": "compressing" - }, - { - "key": "hard drive", - "value": "auxiliary", - "namespace": "overriding" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.418Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "58605dc6-8da7-498e-b4ed-910727493969", - "display_name": "huels-ernser.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.337Z", - "stale_timestamp": "2035-04-17T11:49:20.337Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.337Z", - "updated": "2025-04-17T11:49:20.337Z", - "insights_id": null, - "tags": [ - { - "key": "protocol", - "value": "1080p", - "namespace": "copying" - }, - { - "key": "card", - "value": "redundant", - "namespace": "programming" - }, - { - "key": "card", - "value": "wireless", - "namespace": "navigating" - }, - { - "key": "circuit", - "value": "redundant", - "namespace": "connecting" - }, - { - "key": "interface", - "value": "haptic", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.337Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "660ace40-8d0e-433d-b608-dd368547ffc6", - "display_name": "goodwin-marvin.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.490Z", - "stale_timestamp": "2035-04-17T11:49:20.490Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.490Z", - "updated": "2025-04-17T11:49:20.490Z", - "insights_id": null, - "tags": [ - { - "key": "circuit", - "value": "virtual", - "namespace": "programming" - }, - { - "key": "microchip", - "value": "solid state", - "namespace": "navigating" - }, - { - "key": "capacitor", - "value": "cross-platform", - "namespace": "hacking" - }, - { - "key": "matrix", - "value": "haptic", - "namespace": "backing up" - }, - { - "key": "driver", - "value": "multi-byte", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.490Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - }, - { - "id": "6bca070f-edf1-48e6-aaa1-f3ab40547a5a", - "display_name": "will.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.469Z", - "stale_timestamp": "2035-04-17T11:49:20.469Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.469Z", - "updated": "2025-04-17T11:49:20.469Z", - "insights_id": null, - "tags": [ - { - "key": "hard drive", - "value": "open-source", - "namespace": "connecting" - }, - { - "key": "driver", - "value": "online", - "namespace": "quantifying" - }, - { - "key": "bus", - "value": "online", - "namespace": "bypassing" - }, - { - "key": "driver", - "value": "mobile", - "namespace": "indexing" - }, - { - "key": "microchip", - "value": "online", - "namespace": "hacking" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.469Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "3a132f22-cee9-431c-9312-52be86f0f2b5", - "title": "Placeat consequatur in maiores." - } - ] - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/reports/3a132f22-cee9-431c-9312-52be86f0f2b5/systems?limit=10&offset=0", - "last": "/api/compliance/v2/reports/3a132f22-cee9-431c-9312-52be86f0f2b5/systems?limit=10&offset=20", - "next": "/api/compliance/v2/reports/3a132f22-cee9-431c-9312-52be86f0f2b5/systems?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Systems sorted by \"os_minor_version:asc\"": { - "value": { - "data": [ - { - "id": "23c858e8-d89e-4d80-8c14-eb44e30cfac1", - "display_name": "roob.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.998Z", - "stale_timestamp": "2035-04-17T11:49:20.998Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.998Z", - "updated": "2025-04-17T11:49:20.998Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "haptic", - "namespace": "synthesizing" - }, - { - "key": "microchip", - "value": "mobile", - "namespace": "parsing" - }, - { - "key": "sensor", - "value": "back-end", - "namespace": "programming" - }, - { - "key": "array", - "value": "haptic", - "namespace": "hacking" - }, - { - "key": "application", - "value": "wireless", - "namespace": "bypassing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.998Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "3baf6701-03d8-4855-9c6a-8e4885a1d70f", - "display_name": "barton.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.074Z", - "stale_timestamp": "2035-04-17T11:49:21.074Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.074Z", - "updated": "2025-04-17T11:49:21.074Z", - "insights_id": null, - "tags": [ - { - "key": "application", - "value": "redundant", - "namespace": "programming" - }, - { - "key": "capacitor", - "value": "primary", - "namespace": "calculating" - }, - { - "key": "circuit", - "value": "bluetooth", - "namespace": "bypassing" - }, - { - "key": "interface", - "value": "wireless", - "namespace": "navigating" - }, - { - "key": "panel", - "value": "virtual", - "namespace": "overriding" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.074Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "3e7028b4-a0cb-4280-a0ca-2992541d6737", - "display_name": "turcotte.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.092Z", - "stale_timestamp": "2035-04-17T11:49:21.092Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.092Z", - "updated": "2025-04-17T11:49:21.092Z", - "insights_id": null, - "tags": [ - { - "key": "hard drive", - "value": "online", - "namespace": "bypassing" - }, - { - "key": "firewall", - "value": "multi-byte", - "namespace": "synthesizing" - }, - { - "key": "firewall", - "value": "redundant", - "namespace": "calculating" - }, - { - "key": "system", - "value": "cross-platform", - "namespace": "synthesizing" - }, - { - "key": "alarm", - "value": "cross-platform", - "namespace": "quantifying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.092Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "425c7cc9-31f1-4c44-ac65-435dc7f32f11", - "display_name": "gislason.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.056Z", - "stale_timestamp": "2035-04-17T11:49:21.056Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.056Z", - "updated": "2025-04-17T11:49:21.056Z", - "insights_id": null, - "tags": [ - { - "key": "interface", - "value": "mobile", - "namespace": "quantifying" - }, - { - "key": "pixel", - "value": "back-end", - "namespace": "overriding" - }, - { - "key": "bus", - "value": "open-source", - "namespace": "connecting" - }, - { - "key": "port", - "value": "online", - "namespace": "connecting" - }, - { - "key": "protocol", - "value": "digital", - "namespace": "calculating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.056Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "44094191-c7af-41bb-8564-f6796687fed3", - "display_name": "keebler.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.045Z", - "stale_timestamp": "2035-04-17T11:49:21.045Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.045Z", - "updated": "2025-04-17T11:49:21.045Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "wireless", - "namespace": "overriding" - }, - { - "key": "bus", - "value": "multi-byte", - "namespace": "transmitting" - }, - { - "key": "system", - "value": "digital", - "namespace": "hacking" - }, - { - "key": "alarm", - "value": "optical", - "namespace": "bypassing" - }, - { - "key": "hard drive", - "value": "optical", - "namespace": "parsing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.045Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "4f5996f9-9855-4e72-94b4-2ab0ddce2ef1", - "display_name": "jacobson.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.142Z", - "stale_timestamp": "2035-04-17T11:49:21.142Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.142Z", - "updated": "2025-04-17T11:49:21.142Z", - "insights_id": null, - "tags": [ - { - "key": "panel", - "value": "back-end", - "namespace": "programming" - }, - { - "key": "bandwidth", - "value": "solid state", - "namespace": "programming" - }, - { - "key": "program", - "value": "haptic", - "namespace": "compressing" - }, - { - "key": "program", - "value": "wireless", - "namespace": "copying" - }, - { - "key": "feed", - "value": "online", - "namespace": "calculating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.142Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "561b5192-dd81-4657-9230-d023e549d122", - "display_name": "roob.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.036Z", - "stale_timestamp": "2035-04-17T11:49:21.036Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.036Z", - "updated": "2025-04-17T11:49:21.036Z", - "insights_id": null, - "tags": [ - { - "key": "protocol", - "value": "1080p", - "namespace": "programming" - }, - { - "key": "interface", - "value": "redundant", - "namespace": "transmitting" - }, - { - "key": "protocol", - "value": "multi-byte", - "namespace": "connecting" - }, - { - "key": "transmitter", - "value": "solid state", - "namespace": "synthesizing" - }, - { - "key": "panel", - "value": "digital", - "namespace": "bypassing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.036Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "5ddfa11e-1583-4ea0-997d-09ceb85fec5e", - "display_name": "auer.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.152Z", - "stale_timestamp": "2035-04-17T11:49:21.152Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.152Z", - "updated": "2025-04-17T11:49:21.152Z", - "insights_id": null, - "tags": [ - { - "key": "transmitter", - "value": "neural", - "namespace": "programming" - }, - { - "key": "circuit", - "value": "primary", - "namespace": "copying" - }, - { - "key": "bandwidth", - "value": "1080p", - "namespace": "hacking" - }, - { - "key": "matrix", - "value": "primary", - "namespace": "indexing" - }, - { - "key": "monitor", - "value": "virtual", - "namespace": "bypassing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.152Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "60d4a6f2-3ddc-4eee-9eb6-47a51356e6e1", - "display_name": "pfeffer.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.989Z", - "stale_timestamp": "2035-04-17T11:49:20.989Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.989Z", - "updated": "2025-04-17T11:49:20.989Z", - "insights_id": null, - "tags": [ - { - "key": "transmitter", - "value": "cross-platform", - "namespace": "navigating" - }, - { - "key": "bandwidth", - "value": "back-end", - "namespace": "bypassing" - }, - { - "key": "sensor", - "value": "bluetooth", - "namespace": "synthesizing" - }, - { - "key": "bus", - "value": "multi-byte", - "namespace": "generating" - }, - { - "key": "system", - "value": "neural", - "namespace": "hacking" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.989Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - }, - { - "id": "71a957c0-ef33-4314-bd83-33a283cca843", - "display_name": "frami.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:20.969Z", - "stale_timestamp": "2035-04-17T11:49:20.969Z", - "stale_warning_timestamp": "2035-04-24T11:49:20.969Z", - "updated": "2025-04-17T11:49:20.969Z", - "insights_id": null, - "tags": [ - { - "key": "port", - "value": "optical", - "namespace": "programming" - }, - { - "key": "interface", - "value": "haptic", - "namespace": "copying" - }, - { - "key": "hard drive", - "value": "haptic", - "namespace": "transmitting" - }, - { - "key": "hard drive", - "value": "mobile", - "namespace": "calculating" - }, - { - "key": "array", - "value": "cross-platform", - "namespace": "overriding" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:20.969Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "e812cc1e-8961-4232-aa1e-75d7204fe70f", - "title": "Et provident hic natus." - } - ] - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0, - "sort_by": "os_minor_version" - }, - "links": { - "first": "/api/compliance/v2/reports/e812cc1e-8961-4232-aa1e-75d7204fe70f/systems?limit=10&offset=0&sort_by=os_minor_version", - "last": "/api/compliance/v2/reports/e812cc1e-8961-4232-aa1e-75d7204fe70f/systems?limit=10&offset=20&sort_by=os_minor_version", - "next": "/api/compliance/v2/reports/e812cc1e-8961-4232-aa1e-75d7204fe70f/systems?limit=10&offset=10&sort_by=os_minor_version" - } - }, - "summary": "", - "description": "" - }, - "List of Systems filtered by \"(os_minor_version=0)\"": { - "value": { - "data": [ - { - "id": "05312f8b-3402-4599-b64d-9342d8807e82", - "display_name": "stiedemann-nolan.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.663Z", - "stale_timestamp": "2035-04-17T11:49:21.663Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.663Z", - "updated": "2025-04-17T11:49:21.663Z", - "insights_id": null, - "tags": [ - { - "key": "alarm", - "value": "primary", - "namespace": "connecting" - }, - { - "key": "bandwidth", - "value": "virtual", - "namespace": "programming" - }, - { - "key": "array", - "value": "digital", - "namespace": "bypassing" - }, - { - "key": "circuit", - "value": "online", - "namespace": "overriding" - }, - { - "key": "bandwidth", - "value": "multi-byte", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.663Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "0d9e6920-7ee4-43af-9e2d-b5338f41916f", - "display_name": "pfeffer.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.711Z", - "stale_timestamp": "2035-04-17T11:49:21.711Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.711Z", - "updated": "2025-04-17T11:49:21.711Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "wireless", - "namespace": "connecting" - }, - { - "key": "transmitter", - "value": "auxiliary", - "namespace": "quantifying" - }, - { - "key": "application", - "value": "cross-platform", - "namespace": "synthesizing" - }, - { - "key": "bandwidth", - "value": "bluetooth", - "namespace": "transmitting" - }, - { - "key": "circuit", - "value": "online", - "namespace": "navigating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.711Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "0dbbbbae-e3da-4533-9198-7f15484180cd", - "display_name": "runte.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.653Z", - "stale_timestamp": "2035-04-17T11:49:21.653Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.653Z", - "updated": "2025-04-17T11:49:21.653Z", - "insights_id": null, - "tags": [ - { - "key": "monitor", - "value": "bluetooth", - "namespace": "programming" - }, - { - "key": "transmitter", - "value": "solid state", - "namespace": "generating" - }, - { - "key": "alarm", - "value": "virtual", - "namespace": "programming" - }, - { - "key": "driver", - "value": "bluetooth", - "namespace": "quantifying" - }, - { - "key": "panel", - "value": "multi-byte", - "namespace": "bypassing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.653Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "373e8824-fbc2-4694-85f8-7de77731f61b", - "display_name": "windler.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.643Z", - "stale_timestamp": "2035-04-17T11:49:21.643Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.643Z", - "updated": "2025-04-17T11:49:21.643Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "neural", - "namespace": "generating" - }, - { - "key": "circuit", - "value": "mobile", - "namespace": "calculating" - }, - { - "key": "matrix", - "value": "bluetooth", - "namespace": "backing up" - }, - { - "key": "transmitter", - "value": "cross-platform", - "namespace": "calculating" - }, - { - "key": "pixel", - "value": "wireless", - "namespace": "quantifying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.643Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "3a0c34ba-72a9-43fb-bf4c-6a345dd7d72e", - "display_name": "connelly.test", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.580Z", - "stale_timestamp": "2035-04-17T11:49:21.580Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.580Z", - "updated": "2025-04-17T11:49:21.581Z", - "insights_id": null, - "tags": [ - { - "key": "sensor", - "value": "1080p", - "namespace": "overriding" - }, - { - "key": "panel", - "value": "online", - "namespace": "copying" - }, - { - "key": "pixel", - "value": "back-end", - "namespace": "copying" - }, - { - "key": "transmitter", - "value": "redundant", - "namespace": "connecting" - }, - { - "key": "card", - "value": "neural", - "namespace": "compressing" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.580Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "3bdfa7ce-c1cb-42f0-9529-874d6193991e", - "display_name": "stanton.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.793Z", - "stale_timestamp": "2035-04-17T11:49:21.793Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.793Z", - "updated": "2025-04-17T11:49:21.793Z", - "insights_id": null, - "tags": [ - { - "key": "matrix", - "value": "bluetooth", - "namespace": "programming" - }, - { - "key": "circuit", - "value": "virtual", - "namespace": "synthesizing" - }, - { - "key": "monitor", - "value": "optical", - "namespace": "navigating" - }, - { - "key": "monitor", - "value": "online", - "namespace": "compressing" - }, - { - "key": "monitor", - "value": "bluetooth", - "namespace": "navigating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.793Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "44f86917-db1c-47a0-b7b1-667026248ced", - "display_name": "bayer-reynolds.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.558Z", - "stale_timestamp": "2035-04-17T11:49:21.558Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.558Z", - "updated": "2025-04-17T11:49:21.558Z", - "insights_id": null, - "tags": [ - { - "key": "microchip", - "value": "mobile", - "namespace": "quantifying" - }, - { - "key": "driver", - "value": "bluetooth", - "namespace": "calculating" - }, - { - "key": "circuit", - "value": "solid state", - "namespace": "connecting" - }, - { - "key": "capacitor", - "value": "auxiliary", - "namespace": "calculating" - }, - { - "key": "sensor", - "value": "mobile", - "namespace": "connecting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.558Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "53c7fe23-c2f4-4354-b5bd-fe47567dae33", - "display_name": "tremblay-bogan.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.673Z", - "stale_timestamp": "2035-04-17T11:49:21.673Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.673Z", - "updated": "2025-04-17T11:49:21.673Z", - "insights_id": null, - "tags": [ - { - "key": "array", - "value": "optical", - "namespace": "generating" - }, - { - "key": "monitor", - "value": "wireless", - "namespace": "navigating" - }, - { - "key": "interface", - "value": "solid state", - "namespace": "parsing" - }, - { - "key": "alarm", - "value": "primary", - "namespace": "navigating" - }, - { - "key": "array", - "value": "auxiliary", - "namespace": "quantifying" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.673Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "58f5b724-26d7-4172-b64a-52c0aedd9d0f", - "display_name": "mann-leuschke.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.683Z", - "stale_timestamp": "2035-04-17T11:49:21.683Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.683Z", - "updated": "2025-04-17T11:49:21.683Z", - "insights_id": null, - "tags": [ - { - "key": "program", - "value": "optical", - "namespace": "navigating" - }, - { - "key": "transmitter", - "value": "multi-byte", - "namespace": "transmitting" - }, - { - "key": "bandwidth", - "value": "back-end", - "namespace": "connecting" - }, - { - "key": "firewall", - "value": "bluetooth", - "namespace": "synthesizing" - }, - { - "key": "firewall", - "value": "digital", - "namespace": "transmitting" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.683Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - }, - { - "id": "5b9fbe75-8e9a-49dc-849f-5662590d18f8", - "display_name": "price.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:21.771Z", - "stale_timestamp": "2035-04-17T11:49:21.771Z", - "stale_warning_timestamp": "2035-04-24T11:49:21.771Z", - "updated": "2025-04-17T11:49:21.771Z", - "insights_id": null, - "tags": [ - { - "key": "protocol", - "value": "back-end", - "namespace": "transmitting" - }, - { - "key": "array", - "value": "wireless", - "namespace": "quantifying" - }, - { - "key": "circuit", - "value": "redundant", - "namespace": "calculating" - }, - { - "key": "monitor", - "value": "virtual", - "namespace": "synthesizing" - }, - { - "key": "pixel", - "value": "optical", - "namespace": "hacking" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:21.771Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "4017f0d3-f8f8-46b6-8ba6-80c5d3866772", - "title": "Fugiat quo tempore ullam." - } - ] - } - ], - "meta": { - "total": 25, - "filter": "(os_minor_version=0)", - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/reports/4017f0d3-f8f8-46b6-8ba6-80c5d3866772/systems?filter=%28os_minor_version%3D0%29&limit=10&offset=0", - "last": "/api/compliance/v2/reports/4017f0d3-f8f8-46b6-8ba6-80c5d3866772/systems?filter=%28os_minor_version%3D0%29&limit=10&offset=20", - "next": "/api/compliance/v2/reports/4017f0d3-f8f8-46b6-8ba6-80c5d3866772/systems?filter=%28os_minor_version%3D0%29&limit=10&offset=10" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/reports/{report_id}/systems/os_versions": { - "get": { - "summary": "Request the list of available OS versions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Systems are searchable using attributes `display_name`, `os_version`, `os_major_version`, `os_minor_version`, `assigned_or_scanned`, `never_reported`, `group_name`, `policies`, and `profile_ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Systems" - ], - "description": "This feature is exclusively used by the frontend", - "operationId": "ReportSystemsOS", - "deprecated": true, - "responses": { - "200": { - "description": "Lists available OS versions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of available OS versions": { - "value": [ - "8.0" - ], - "summary": "", - "description": "" - } - }, - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - } - } - } - } - } - }, - "/reports/{report_id}/systems/{system_id}": { - "get": { - "summary": "Request a System", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "system_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve a specific system from a specific report.", - "operationId": "ReportSystem", - "responses": { - "200": { - "description": "Returns a System under a Report", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a System under a Report": { - "value": { - "data": { - "id": "d3ae7cc2-f9e1-4657-9354-1bad7cc57cec", - "display_name": "dibbert-smitham.example", - "groups": [], - "culled_timestamp": "2035-05-01T11:49:24.136Z", - "stale_timestamp": "2035-04-17T11:49:24.136Z", - "stale_warning_timestamp": "2035-04-24T11:49:24.136Z", - "updated": "2025-04-17T11:49:24.136Z", - "insights_id": null, - "tags": [ - { - "key": "driver", - "value": "auxiliary", - "namespace": "indexing" - }, - { - "key": "matrix", - "value": "primary", - "namespace": "transmitting" - }, - { - "key": "system", - "value": "1080p", - "namespace": "indexing" - }, - { - "key": "sensor", - "value": "1080p", - "namespace": "indexing" - }, - { - "key": "bandwidth", - "value": "digital", - "namespace": "generating" - } - ], - "type": "system", - "last_check_in": "2035-04-25T11:49:24.136Z", - "os_major_version": 8, - "os_minor_version": 0, - "policies": [ - { - "id": "c71a0ebc-513b-4181-bd57-a0cf2f7042c4", - "title": "Rem quam officiis ut." - } - ] - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing System": { - "value": { - "errors": [ - "V2::System not found with ID e9553558-9064-4d25-b613-e32ddd076cd0" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/policies/{policy_id}/tailorings": { - "get": { - "summary": "Request Tailorings", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "os_minor_version", - "os_minor_version:asc", - "os_minor_version:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Tailorings are searchable using attributes `os_minor_version`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Retrieve a list of all tailorings.", - "operationId": "Tailorings", - "responses": { - "200": { - "description": "Lists Tailorings", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Tailorings": { - "value": { - "data": [ - { - "id": "02b710bd-746d-40f6-b9cb-c8a000dd592a", - "profile_id": "119853c5-7893-4149-9970-84c6884cbf3f", - "os_minor_version": 2, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "736a0eae-3eb2-4c9c-b5e1-7a7038d2a7ed", - "security_guide_version": "100.96.22" - }, - { - "id": "063364f6-161d-452a-9413-635e71a3909d", - "profile_id": "8bd5b376-a810-4cd7-8b4f-508f8291c135", - "os_minor_version": 10, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "b031c24e-42e0-4a4f-85d2-29049c2faae1", - "security_guide_version": "100.96.30" - }, - { - "id": "0b34aec0-d2c9-4b0b-9b01-768c70a82bec", - "profile_id": "6cc15abe-4b11-4db4-bf44-45ec843e6262", - "os_minor_version": 7, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "fdb7140c-b1c1-48bb-96c2-b6bde9887da5", - "security_guide_version": "100.96.27" - }, - { - "id": "17486379-b1f6-4b40-a8cf-8a03df40d1a3", - "profile_id": "b0b5571c-4de2-4d70-9e1a-32e3425fc576", - "os_minor_version": 6, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "43b0feca-f2ef-4299-b2c6-8e6dbc1e8bc0", - "security_guide_version": "100.96.26" - }, - { - "id": "19ae8bfb-b7ae-4b84-8fc0-27e734eb96ef", - "profile_id": "4a6c7063-b080-46a0-be7b-cee5e202b4bd", - "os_minor_version": 3, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "3ac3b2f9-1084-4f82-9136-a5622a4faa54", - "security_guide_version": "100.96.23" - }, - { - "id": "23ade012-9c40-4b6d-9286-fbc0c952e823", - "profile_id": "26431292-3f2a-48ad-b3a9-d6a7eae0455d", - "os_minor_version": 12, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "d927fd11-de88-4e8b-bb59-cc631c7032b7", - "security_guide_version": "100.96.32" - }, - { - "id": "25a5f011-f444-4970-8f25-1d73b7fb3a67", - "profile_id": "2eb0489d-4de0-40f8-af9a-9ae634e206f8", - "os_minor_version": 1, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "5827fa3f-762c-44cd-96fe-f5c825c74630", - "security_guide_version": "100.96.21" - }, - { - "id": "340a02cb-bee4-4d61-b75e-acee92ec999d", - "profile_id": "2cbba1e5-1b3d-4349-ac24-c4f3beffe1a2", - "os_minor_version": 15, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "dcb01c0f-ebf4-4027-8717-13b448a66f22", - "security_guide_version": "100.96.35" - }, - { - "id": "41da9a4e-b9a3-439d-98cc-ebac225b9564", - "profile_id": "f0634158-7ca6-4791-a9d0-0748ba11691e", - "os_minor_version": 9, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "2ab1cec4-abc1-4a99-9707-66e3456bce0b", - "security_guide_version": "100.96.29" - }, - { - "id": "48d79b76-8ed8-44a9-abd4-a95e60e0c1c1", - "profile_id": "ec16d9ee-1bd6-4fb7-8d6b-1e920081115a", - "os_minor_version": 13, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "2b24e482-2824-4532-8f0e-d4da66a1d160", - "security_guide_version": "100.96.33" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies/43e1c6f8-9d92-46c6-82cd-2a1e32de5120/tailorings?limit=10&offset=0", - "last": "/api/compliance/v2/policies/43e1c6f8-9d92-46c6-82cd-2a1e32de5120/tailorings?limit=10&offset=20", - "next": "/api/compliance/v2/policies/43e1c6f8-9d92-46c6-82cd-2a1e32de5120/tailorings?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Tailorings sorted by \"os_minor_version:asc\"": { - "value": { - "data": [ - { - "id": "c83b5639-12aa-472d-9c43-ad6e32dad199", - "profile_id": "091d3c34-678f-4f40-88f6-e1fa27d2e7d6", - "os_minor_version": 0, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "cc012333-a47d-450d-8195-9e1b4b75974a", - "security_guide_version": "100.96.45" - }, - { - "id": "a6d2e236-ad66-422b-a68f-79fedecb49c0", - "profile_id": "74c98e9f-bccf-40a3-a18b-238af507b0b2", - "os_minor_version": 1, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "2bd4cfd7-9636-4814-bd1d-a3f7e730cf08", - "security_guide_version": "100.96.46" - }, - { - "id": "bb640746-cb4d-44c3-83ca-7f5408fa21e7", - "profile_id": "c0a7b6a2-5352-4c7c-9d02-eecd88598fad", - "os_minor_version": 2, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "2391df51-418d-4180-98b1-b741b6689fb6", - "security_guide_version": "100.96.47" - }, - { - "id": "b94b2cad-2207-490e-b3fe-2c43cde8ded3", - "profile_id": "22471e26-481c-407e-85bb-6527b3eae85f", - "os_minor_version": 3, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "f7d53201-531f-4129-8696-eb08305d0842", - "security_guide_version": "100.96.48" - }, - { - "id": "4b0a9db7-9cdb-4650-a50e-c1a7bcfb0bcc", - "profile_id": "139f3a5c-21c2-44bc-b0c4-35395d0af85e", - "os_minor_version": 4, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "b4ebdb39-640e-40ec-ab86-8fcdaac207d0", - "security_guide_version": "100.96.49" - }, - { - "id": "756038e5-1c8a-4da7-8317-07785640963c", - "profile_id": "05b921a9-6f0d-41b1-a8ea-49af941ede74", - "os_minor_version": 5, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "4f0879f2-941c-4f05-9375-db659ce1a0fe", - "security_guide_version": "100.97.0" - }, - { - "id": "0041d3c6-87cf-4aec-bca9-3aea8fac7bfe", - "profile_id": "4d8ef4e9-6fcf-475a-8be5-3b8ead923bf4", - "os_minor_version": 6, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "15861e94-5b17-4a5a-b1ce-4f38dbd54112", - "security_guide_version": "100.97.1" - }, - { - "id": "53af788b-0663-417d-8b6e-7eaffda45424", - "profile_id": "8d178059-e554-4a11-a5c5-e356fbb00ea0", - "os_minor_version": 7, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "90db5eaa-7f32-48dc-892c-8d61d1fc4dbc", - "security_guide_version": "100.97.2" - }, - { - "id": "610af76a-fc28-43b6-bd0f-16968cba4de0", - "profile_id": "dd7b7558-adcb-4cf3-a0d1-a07cdab06968", - "os_minor_version": 8, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "de65bc1e-601e-4100-9d7f-1529eac7928c", - "security_guide_version": "100.97.3" - }, - { - "id": "039d1e28-d351-46e9-b7ad-3c100abb9602", - "profile_id": "3d1fdcc0-932f-435c-ab76-336df9cc32af", - "os_minor_version": 9, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "5a7704ae-c3ac-4013-ad5f-2a8fbe4c4722", - "security_guide_version": "100.97.4" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "os_minor_version" - }, - "links": { - "first": "/api/compliance/v2/policies/acb098ee-ac97-4e37-a63e-40bece7ce1b1/tailorings?limit=10&offset=0&sort_by=os_minor_version", - "last": "/api/compliance/v2/policies/acb098ee-ac97-4e37-a63e-40bece7ce1b1/tailorings?limit=10&offset=20&sort_by=os_minor_version", - "next": "/api/compliance/v2/policies/acb098ee-ac97-4e37-a63e-40bece7ce1b1/tailorings?limit=10&offset=10&sort_by=os_minor_version" - } - }, - "summary": "", - "description": "" - }, - "List of Tailorings filtered by '(os_minor_version=22)'": { - "value": { - "data": [ - { - "id": "01f03819-c26e-4f55-b83a-dd7a37b4ba7a", - "profile_id": "763969f9-a7f4-44af-9894-3f0d6ce52977", - "os_minor_version": 22, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "979ce9da-0790-4bb8-935c-3381836cd1d7", - "security_guide_version": "100.97.42" - } - ], - "meta": { - "total": 1, - "filter": "(os_minor_version=22)", - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/policies/c8d24264-a043-4d77-b2cd-be9e73c84aa6/tailorings?filter=%28os_minor_version%3D22%29&limit=10&offset=0", - "last": "/api/compliance/v2/policies/c8d24264-a043-4d77-b2cd-be9e73c84aa6/tailorings?filter=%28os_minor_version%3D22%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/tailoring" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "post": { - "summary": "Create a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Create a Tailoring with the provided attributes (for ImageBuilder only)", - "operationId": "CreateTailoring", - "deprecated": true, - "responses": { - "201": { - "description": "Creates a Tailoring", - "content": { - "application/vnd.api+json": { - "examples": { - "Response example": { - "value": { - "data": { - "id": "82a4a052-3e2e-47d5-9ca2-330085bf21ff", - "profile_id": "e6fa39ec-690f-4ec1-950b-51d879eb17bc", - "os_minor_version": 1, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "ebc7120c-44e7-4769-a0b0-dd1a8076ec6c", - "security_guide_version": "100.98.45" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/tailoring" - } - } - } - } - } - } - } - } - }, - "requestBody": { - "content": { - "application/vnd.api+json": { - "schema": { - "$ref": "#/components/schemas/tailoring_create" - } - } - } - } - } - }, - "/policies/{policy_id}/tailorings/{tailoring_id}": { - "get": { - "summary": "Request a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "description": "UUID or OS minor version number", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Retrieve a specific tailoring.", - "operationId": "Tailoring", - "responses": { - "200": { - "description": "Returns a Tailoring", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Tailoring": { - "value": { - "data": { - "id": "51296c4e-df01-4378-9e3a-940af1281c55", - "profile_id": "09ac1a78-f0ce-44db-a00a-7543e4dda2cc", - "os_minor_version": 1, - "value_overrides": {}, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "b6840d89-3eab-4739-8d26-efc55fdaa049", - "security_guide_version": "100.98.46" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/tailoring" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Tailoring": { - "value": { - "errors": [ - "V2::Tailoring not found with ID 09b48253-de16-4740-80bc-74d6601cbf7f" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - }, - "patch": { - "summary": "Update a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "description": "UUID or OS minor version number", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Edit or update an existing tailoring.", - "operationId": "UpdateTailoring", - "responses": { - "202": { - "description": "Updates a Tailoring", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns the updated Tailoring": { - "value": { - "data": { - "id": "d246d700-62df-4175-8d3d-37ea363af80f", - "profile_id": "64751566-f9a7-4dfd-bf28-d33551f2b8da", - "os_minor_version": 1, - "value_overrides": { - "c2d68aa8-fc72-4c5a-9492-c92297f26dc5": "123" - }, - "type": "tailoring", - "os_major_version": 7, - "security_guide_id": "0112b166-5391-40b5-a277-d49bc216e534", - "security_guide_version": "100.98.47" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/tailoring" - } - } - } - } - } - } - } - } - }, - "requestBody": { - "content": { - "application/vnd.api+json": { - "schema": { - "$ref": "#/components/schemas/tailoring" - } - } - } - } - } - }, - "/policies/{policy_id}/tailorings/{tailoring_id}/rule_tree": { - "get": { - "summary": "Request the Rule Tree of a Tailoring", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Returns rule tree of a tailoring.", - "operationId": "TailoringRuleTree", - "deprecated": true, - "responses": { - "200": { - "description": "Returns the Rule Tree of a Tailoring", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns the Rule Tree of a Tailoring": { - "value": [ - { - "id": "c145d4bc-de4e-4f70-92fc-c131b699a462", - "type": "rule_group", - "children": [ - { - "id": "1899da0a-1c6f-4516-bb73-a42825332de4", - "type": "rule" - } - ] - }, - { - "id": "fb6da019-c792-460d-8585-3340e67af609", - "type": "rule_group", - "children": [ - { - "id": "448049d3-b44a-4f62-b386-ec022075b421", - "type": "rule" - } - ] - }, - { - "id": "24e32286-0793-4657-91ec-7691964b0c45", - "type": "rule_group", - "children": [ - { - "id": "c40e1772-474f-4cd9-8042-a7b5ba00443e", - "type": "rule" - } - ] - }, - { - "id": "ef9b62c2-e4b8-4b70-83ef-4acea0420fbc", - "type": "rule_group", - "children": [ - { - "id": "2aff31eb-6edd-4121-a8bc-ec46959bb1d2", - "type": "rule" - } - ] - }, - { - "id": "54edc299-2e67-4fec-822f-0526780e3051", - "type": "rule_group", - "children": [ - { - "id": "5a6c276c-7d34-4f7c-a7a0-734de71c0c70", - "type": "rule" - } - ] - }, - { - "id": "2f2a218d-17af-4218-9fae-f0f515471342", - "type": "rule_group", - "children": [ - { - "id": "85b4fb87-4477-4f1f-a47d-970214bc80c0", - "type": "rule" - } - ] - }, - { - "id": "9a00fdac-86a9-4dd3-899d-18c2a37900c7", - "type": "rule_group", - "children": [ - { - "id": "82404904-5f2d-4f1c-af93-85524296f4da", - "type": "rule" - } - ] - }, - { - "id": "99033993-1934-4c8e-9ba9-5e91c81372df", - "type": "rule_group", - "children": [ - { - "id": "feb695ed-a723-4644-bd96-c7e689cb53ae", - "type": "rule" - } - ] - }, - { - "id": "6eb02c34-5afa-4052-9e39-0d194fe40e96", - "type": "rule_group", - "children": [ - { - "id": "7fff3879-2104-4783-8bde-951b89e50b2f", - "type": "rule" - } - ] - }, - { - "id": "7e9a95e6-934f-447a-9ea1-5b11f8cb6223", - "type": "rule_group", - "children": [ - { - "id": "0aff8b8a-452f-475b-877e-1a5b83bd626a", - "type": "rule" - } - ] - } - ], - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/rule_tree" - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Tailoring": { - "value": { - "errors": [ - "V2::Tailoring not found with ID a6cd5480-54cc-4184-bddb-ef48fc575792" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/policies/{policy_id}/tailorings/{tailoring_id}/tailoring_file.json": { - "get": { - "summary": "Request a Tailoring file", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "tailoring_id", - "in": "path", - "required": true, - "description": "UUID or OS minor version number", - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Policies" - ], - "description": "Retrieve a tailoring file of a specific tailoring.", - "operationId": "TailoringFile", - "responses": { - "200": { - "description": "Returns a Tailoring File", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Tailoring File": { - "value": { - "profiles": [ - { - "id": "xccdf_org.ssgproject.content_profile_4c6d0969f381d405c9fcc0bdccb00fb7", - "title": "Ex placeat in reiciendis.", - "groups": {}, - "rules": {}, - "variables": { - "foo_value_2f0456b1-940e-45ea-87f4-6844a1a5b622": { - "value": "755072" - }, - "foo_value_394ce4f1-5b99-43ae-baf0-fb9f3188d7b9": { - "value": "858842" - } - } - } - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/tailoring_file" - } - } - } - } - } - } - }, - "/reports/{report_id}/test_results": { - "get": { - "summary": "Request Test Results under a Report", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "tags", - "in": "query", - "required": false, - "description": "An array of tags to narrow down the search results. In case the value contains symbols used for separators (`/` or `=`), they need to be encoded.<br>e.g.: `namespace/key=value`, `insights-client/selinux-config=SELINUX%3Denforcing`", - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "display_name", - "security_guide_version", - "groups", - "score", - "end_time", - "failed_rule_count", - "display_name:asc", - "display_name:desc", - "security_guide_version:asc", - "security_guide_version:desc", - "groups:asc", - "groups:desc", - "score:asc", - "score:desc", - "end_time:asc", - "end_time:desc", - "failed_rule_count:asc", - "failed_rule_count:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Test Results are searchable using attributes `score`, `supported`, `system_id`, `display_name`, `os_minor_version`, `security_guide_version`, `compliant`, `group_name`, and `failed_rule_severity`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve all of the test results for a specific report.", - "operationId": "ReportTestResults", - "responses": { - "200": { - "description": "Lists Test Results under a Report", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Test Results": { - "value": { - "data": [ - { - "id": "07150f64-e0f7-4b48-b2f9-66f1ded37ee8", - "end_time": "2025-04-17T11:48:27.792Z", - "failed_rule_count": 0, - "supported": true, - "score": 7.942933803943008, - "type": "test_result", - "display_name": "kuhn.example", - "groups": [], - "tags": [ - { - "key": "matrix", - "value": "solid state", - "namespace": "navigating" - }, - { - "key": "matrix", - "value": "mobile", - "namespace": "synthesizing" - }, - { - "key": "array", - "value": "redundant", - "namespace": "indexing" - }, - { - "key": "port", - "value": "cross-platform", - "namespace": "transmitting" - }, - { - "key": "port", - "value": "back-end", - "namespace": "indexing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "fee61419-7fbc-49c0-8e2b-2ec711074d16", - "security_guide_version": "100.101.18" - }, - { - "id": "32b40af7-9eb9-47c3-93de-e6fe37d2dae1", - "end_time": "2025-04-17T11:48:27.861Z", - "failed_rule_count": 0, - "supported": true, - "score": 85.61426956214434, - "type": "test_result", - "display_name": "gerhold.example", - "groups": [], - "tags": [ - { - "key": "interface", - "value": "open-source", - "namespace": "programming" - }, - { - "key": "sensor", - "value": "digital", - "namespace": "quantifying" - }, - { - "key": "matrix", - "value": "bluetooth", - "namespace": "parsing" - }, - { - "key": "program", - "value": "1080p", - "namespace": "hacking" - }, - { - "key": "protocol", - "value": "neural", - "namespace": "overriding" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "e595c0ed-bc17-4ca2-a2eb-b8371380b3f4", - "security_guide_version": "100.101.18" - }, - { - "id": "36256d2d-4161-44fb-9741-7de96427d935", - "end_time": "2025-04-17T11:48:27.689Z", - "failed_rule_count": 0, - "supported": true, - "score": 4.205883811246036, - "type": "test_result", - "display_name": "boyle-ferry.test", - "groups": [], - "tags": [ - { - "key": "application", - "value": "haptic", - "namespace": "parsing" - }, - { - "key": "bus", - "value": "auxiliary", - "namespace": "backing up" - }, - { - "key": "capacitor", - "value": "optical", - "namespace": "transmitting" - }, - { - "key": "sensor", - "value": "mobile", - "namespace": "overriding" - }, - { - "key": "driver", - "value": "mobile", - "namespace": "transmitting" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "8f028ff4-33d8-4b8b-adea-51858fa3dcf2", - "security_guide_version": "100.101.18" - }, - { - "id": "3a31e93c-6adc-4ee6-ba80-b0cc32e28be9", - "end_time": "2025-04-17T11:48:27.745Z", - "failed_rule_count": 0, - "supported": true, - "score": 68.12744348799109, - "type": "test_result", - "display_name": "breitenberg.test", - "groups": [], - "tags": [ - { - "key": "transmitter", - "value": "online", - "namespace": "compressing" - }, - { - "key": "interface", - "value": "cross-platform", - "namespace": "programming" - }, - { - "key": "firewall", - "value": "open-source", - "namespace": "compressing" - }, - { - "key": "capacitor", - "value": "auxiliary", - "namespace": "calculating" - }, - { - "key": "capacitor", - "value": "optical", - "namespace": "compressing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "dc3e7f0f-3183-44a4-a490-647b93b394e7", - "security_guide_version": "100.101.18" - }, - { - "id": "51f731b4-82ab-4006-8c3a-903e23b19e93", - "end_time": "2025-04-17T11:48:27.667Z", - "failed_rule_count": 0, - "supported": true, - "score": 83.82241590383677, - "type": "test_result", - "display_name": "satterfield.test", - "groups": [], - "tags": [ - { - "key": "card", - "value": "optical", - "namespace": "synthesizing" - }, - { - "key": "driver", - "value": "mobile", - "namespace": "connecting" - }, - { - "key": "system", - "value": "primary", - "namespace": "navigating" - }, - { - "key": "capacitor", - "value": "digital", - "namespace": "copying" - }, - { - "key": "array", - "value": "multi-byte", - "namespace": "compressing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "a795e22c-cb04-4dc4-873a-fc6c9f71fad8", - "security_guide_version": "100.101.18" - }, - { - "id": "5b79b8be-1ef3-4b8c-ad86-bb7af1099378", - "end_time": "2025-04-17T11:48:27.757Z", - "failed_rule_count": 0, - "supported": true, - "score": 8.044548934234419, - "type": "test_result", - "display_name": "treutel.test", - "groups": [], - "tags": [ - { - "key": "program", - "value": "haptic", - "namespace": "copying" - }, - { - "key": "matrix", - "value": "wireless", - "namespace": "programming" - }, - { - "key": "program", - "value": "back-end", - "namespace": "quantifying" - }, - { - "key": "circuit", - "value": "primary", - "namespace": "calculating" - }, - { - "key": "monitor", - "value": "virtual", - "namespace": "navigating" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "fade4033-b4b9-4fb7-98f9-88eb90819b40", - "security_guide_version": "100.101.18" - }, - { - "id": "6463fcb5-22a8-4136-b327-f6c4202ed93f", - "end_time": "2025-04-17T11:48:27.633Z", - "failed_rule_count": 0, - "supported": true, - "score": 28.0152666639477, - "type": "test_result", - "display_name": "kassulke.test", - "groups": [], - "tags": [ - { - "key": "hard drive", - "value": "wireless", - "namespace": "indexing" - }, - { - "key": "sensor", - "value": "1080p", - "namespace": "parsing" - }, - { - "key": "card", - "value": "online", - "namespace": "connecting" - }, - { - "key": "hard drive", - "value": "primary", - "namespace": "indexing" - }, - { - "key": "alarm", - "value": "optical", - "namespace": "programming" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "cd0959d1-7e00-4679-a5d5-146ba9b797ed", - "security_guide_version": "100.101.18" - }, - { - "id": "677325f1-159b-4e7d-a63b-dcd5f308ed37", - "end_time": "2025-04-17T11:48:27.712Z", - "failed_rule_count": 0, - "supported": true, - "score": 66.8254138012402, - "type": "test_result", - "display_name": "fritsch-runolfsson.example", - "groups": [], - "tags": [ - { - "key": "circuit", - "value": "digital", - "namespace": "parsing" - }, - { - "key": "circuit", - "value": "redundant", - "namespace": "navigating" - }, - { - "key": "protocol", - "value": "solid state", - "namespace": "connecting" - }, - { - "key": "panel", - "value": "haptic", - "namespace": "hacking" - }, - { - "key": "bandwidth", - "value": "back-end", - "namespace": "overriding" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "598f9576-b4d1-4cac-988d-78b78ca7caf3", - "security_guide_version": "100.101.18" - }, - { - "id": "7af38fa6-78f7-4acd-95c5-cb85fed1ec43", - "end_time": "2025-04-17T11:48:27.838Z", - "failed_rule_count": 0, - "supported": true, - "score": 47.06889881278796, - "type": "test_result", - "display_name": "lynch.example", - "groups": [], - "tags": [ - { - "key": "alarm", - "value": "auxiliary", - "namespace": "parsing" - }, - { - "key": "bandwidth", - "value": "online", - "namespace": "parsing" - }, - { - "key": "bus", - "value": "digital", - "namespace": "synthesizing" - }, - { - "key": "interface", - "value": "haptic", - "namespace": "navigating" - }, - { - "key": "hard drive", - "value": "wireless", - "namespace": "hacking" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "49a55737-8bf0-4481-8a11-ffc1ee8867fd", - "security_guide_version": "100.101.18" - }, - { - "id": "862ab7d2-1984-460b-8087-d52f14af16b1", - "end_time": "2025-04-17T11:48:27.768Z", - "failed_rule_count": 0, - "supported": true, - "score": 1.771767249737466, - "type": "test_result", - "display_name": "fahey-crist.example", - "groups": [], - "tags": [ - { - "key": "port", - "value": "wireless", - "namespace": "programming" - }, - { - "key": "firewall", - "value": "redundant", - "namespace": "generating" - }, - { - "key": "transmitter", - "value": "back-end", - "namespace": "parsing" - }, - { - "key": "interface", - "value": "cross-platform", - "namespace": "synthesizing" - }, - { - "key": "panel", - "value": "auxiliary", - "namespace": "synthesizing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "1c9f10b9-afba-4751-a1dc-8a383b3a688a", - "security_guide_version": "100.101.18" - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/reports/e3852aa4-7b5c-4769-8504-ee3a43d9b2f7/test_results?limit=10&offset=0", - "last": "/api/compliance/v2/reports/e3852aa4-7b5c-4769-8504-ee3a43d9b2f7/test_results?limit=10&offset=20", - "next": "/api/compliance/v2/reports/e3852aa4-7b5c-4769-8504-ee3a43d9b2f7/test_results?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Test Results sorted by \"score:asc\"": { - "value": { - "data": [ - { - "id": "58a84cc4-d531-4348-a002-685920624539", - "end_time": "2025-04-17T11:48:28.565Z", - "failed_rule_count": 0, - "supported": true, - "score": 0.18418392844598, - "type": "test_result", - "display_name": "ernser-lebsack.test", - "groups": [], - "tags": [ - { - "key": "bus", - "value": "digital", - "namespace": "compressing" - }, - { - "key": "system", - "value": "back-end", - "namespace": "compressing" - }, - { - "key": "bus", - "value": "bluetooth", - "namespace": "transmitting" - }, - { - "key": "pixel", - "value": "digital", - "namespace": "transmitting" - }, - { - "key": "program", - "value": "auxiliary", - "namespace": "quantifying" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "c3327c2b-b97b-4e34-85bc-e1146ccae6ec", - "security_guide_version": "100.102.28" - }, - { - "id": "7fe2d894-914f-47ba-80bc-0475e77053cd", - "end_time": "2025-04-17T11:48:28.428Z", - "failed_rule_count": 0, - "supported": true, - "score": 10.41062429866279, - "type": "test_result", - "display_name": "daugherty-dare.test", - "groups": [], - "tags": [ - { - "key": "monitor", - "value": "bluetooth", - "namespace": "bypassing" - }, - { - "key": "sensor", - "value": "bluetooth", - "namespace": "parsing" - }, - { - "key": "bus", - "value": "optical", - "namespace": "calculating" - }, - { - "key": "feed", - "value": "virtual", - "namespace": "connecting" - }, - { - "key": "system", - "value": "digital", - "namespace": "synthesizing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "3b74ea2f-e6eb-429d-8521-f76a81b3c754", - "security_guide_version": "100.102.28" - }, - { - "id": "f4398c97-92a4-400c-a9c6-a3257330525e", - "end_time": "2025-04-17T11:48:28.541Z", - "failed_rule_count": 0, - "supported": true, - "score": 12.0856908804786, - "type": "test_result", - "display_name": "schneider.test", - "groups": [], - "tags": [ - { - "key": "array", - "value": "redundant", - "namespace": "quantifying" - }, - { - "key": "firewall", - "value": "multi-byte", - "namespace": "generating" - }, - { - "key": "interface", - "value": "primary", - "namespace": "quantifying" - }, - { - "key": "port", - "value": "wireless", - "namespace": "transmitting" - }, - { - "key": "bandwidth", - "value": "wireless", - "namespace": "synthesizing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "83fc3f1a-785f-411d-bee6-d5154436eae7", - "security_guide_version": "100.102.28" - }, - { - "id": "fa4e017f-becc-4a86-8125-1be814a42b58", - "end_time": "2025-04-17T11:48:28.528Z", - "failed_rule_count": 0, - "supported": true, - "score": 14.67878952432154, - "type": "test_result", - "display_name": "botsford.test", - "groups": [], - "tags": [ - { - "key": "matrix", - "value": "wireless", - "namespace": "synthesizing" - }, - { - "key": "system", - "value": "virtual", - "namespace": "quantifying" - }, - { - "key": "sensor", - "value": "mobile", - "namespace": "synthesizing" - }, - { - "key": "panel", - "value": "virtual", - "namespace": "connecting" - }, - { - "key": "driver", - "value": "redundant", - "namespace": "copying" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "97c90349-999f-4de6-82bb-c914296035e4", - "security_guide_version": "100.102.28" - }, - { - "id": "1b8b7b72-9ad7-4ba3-a09b-ca375a586081", - "end_time": "2025-04-17T11:48:28.577Z", - "failed_rule_count": 0, - "supported": true, - "score": 15.16112296320871, - "type": "test_result", - "display_name": "huels.test", - "groups": [], - "tags": [ - { - "key": "protocol", - "value": "open-source", - "namespace": "hacking" - }, - { - "key": "card", - "value": "back-end", - "namespace": "compressing" - }, - { - "key": "feed", - "value": "open-source", - "namespace": "generating" - }, - { - "key": "array", - "value": "neural", - "namespace": "bypassing" - }, - { - "key": "driver", - "value": "optical", - "namespace": "connecting" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "9a371b94-b743-49e4-9711-6f16450eb734", - "security_guide_version": "100.102.28" - }, - { - "id": "b2be27cc-92b9-4320-8479-0146ce129bf5", - "end_time": "2025-04-17T11:48:28.400Z", - "failed_rule_count": 0, - "supported": true, - "score": 19.91511615659336, - "type": "test_result", - "display_name": "streich.example", - "groups": [], - "tags": [ - { - "key": "driver", - "value": "auxiliary", - "namespace": "navigating" - }, - { - "key": "monitor", - "value": "open-source", - "namespace": "parsing" - }, - { - "key": "system", - "value": "online", - "namespace": "synthesizing" - }, - { - "key": "capacitor", - "value": "digital", - "namespace": "connecting" - }, - { - "key": "card", - "value": "bluetooth", - "namespace": "overriding" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "edd4fd65-ffc3-4e78-b6e6-52b4fb9a5bc0", - "security_guide_version": "100.102.28" - }, - { - "id": "7c07bcb0-9557-4c69-a6d4-7918c4163783", - "end_time": "2025-04-17T11:48:28.455Z", - "failed_rule_count": 0, - "supported": true, - "score": 25.2676410138287, - "type": "test_result", - "display_name": "spencer-hoppe.example", - "groups": [], - "tags": [ - { - "key": "matrix", - "value": "redundant", - "namespace": "bypassing" - }, - { - "key": "array", - "value": "digital", - "namespace": "programming" - }, - { - "key": "bandwidth", - "value": "online", - "namespace": "generating" - }, - { - "key": "driver", - "value": "1080p", - "namespace": "generating" - }, - { - "key": "sensor", - "value": "redundant", - "namespace": "compressing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "6af74cd0-12c6-466a-b519-b080fed13c2e", - "security_guide_version": "100.102.28" - }, - { - "id": "e2a5839f-ed5c-49d8-9120-8bfecd43f078", - "end_time": "2025-04-17T11:48:28.478Z", - "failed_rule_count": 0, - "supported": true, - "score": 28.05846665632422, - "type": "test_result", - "display_name": "wilderman.test", - "groups": [], - "tags": [ - { - "key": "feed", - "value": "haptic", - "namespace": "indexing" - }, - { - "key": "panel", - "value": "haptic", - "namespace": "bypassing" - }, - { - "key": "matrix", - "value": "multi-byte", - "namespace": "backing up" - }, - { - "key": "application", - "value": "auxiliary", - "namespace": "programming" - }, - { - "key": "driver", - "value": "mobile", - "namespace": "connecting" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "2c1c2c75-0eeb-4f45-a4d4-5951d4bba8f9", - "security_guide_version": "100.102.28" - }, - { - "id": "4d5a16d4-5592-46b1-8af1-e90e88ef5176", - "end_time": "2025-04-17T11:48:28.491Z", - "failed_rule_count": 0, - "supported": true, - "score": 30.22428256095794, - "type": "test_result", - "display_name": "torp-bauch.example", - "groups": [], - "tags": [ - { - "key": "bus", - "value": "bluetooth", - "namespace": "transmitting" - }, - { - "key": "firewall", - "value": "auxiliary", - "namespace": "backing up" - }, - { - "key": "system", - "value": "primary", - "namespace": "quantifying" - }, - { - "key": "bus", - "value": "open-source", - "namespace": "compressing" - }, - { - "key": "microchip", - "value": "open-source", - "namespace": "copying" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "7c622478-05a3-4e4d-912e-11fb209474cd", - "security_guide_version": "100.102.28" - }, - { - "id": "16871757-5710-4974-b847-ad1d8f40cfa1", - "end_time": "2025-04-17T11:48:28.389Z", - "failed_rule_count": 0, - "supported": true, - "score": 32.53274996235959, - "type": "test_result", - "display_name": "trantow.example", - "groups": [], - "tags": [ - { - "key": "bandwidth", - "value": "multi-byte", - "namespace": "overriding" - }, - { - "key": "card", - "value": "open-source", - "namespace": "backing up" - }, - { - "key": "sensor", - "value": "open-source", - "namespace": "indexing" - }, - { - "key": "monitor", - "value": "neural", - "namespace": "indexing" - }, - { - "key": "pixel", - "value": "auxiliary", - "namespace": "bypassing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "475147e8-5e89-4362-9872-bb7b315d99d2", - "security_guide_version": "100.102.28" - } - ], - "meta": { - "total": 25, - "tags": [], - "limit": 10, - "offset": 0, - "sort_by": "score" - }, - "links": { - "first": "/api/compliance/v2/reports/800cea5c-8aa5-4e43-9446-4f4e188c0a72/test_results?limit=10&offset=0&sort_by=score", - "last": "/api/compliance/v2/reports/800cea5c-8aa5-4e43-9446-4f4e188c0a72/test_results?limit=10&offset=20&sort_by=score", - "next": "/api/compliance/v2/reports/800cea5c-8aa5-4e43-9446-4f4e188c0a72/test_results?limit=10&offset=10&sort_by=score" - } - }, - "summary": "", - "description": "" - }, - "List of Test Results filtered by \"(os_minor_version=8)\"": { - "value": { - "data": [], - "meta": { - "total": 0, - "filter": "(os_minor_version=8)", - "tags": [], - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/reports/d76e0a3b-2d6f-4243-a420-3e15bafdb9ff/test_results?filter=%28os_minor_version%3D8%29&limit=10&offset=0", - "last": "/api/compliance/v2/reports/d76e0a3b-2d6f-4243-a420-3e15bafdb9ff/test_results?filter=%28os_minor_version%3D8%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/test_result" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/reports/{report_id}/test_results/os_versions": { - "get": { - "summary": "Request the list of available OS versions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Test Results are searchable using attributes `score`, `supported`, `system_id`, `display_name`, `os_minor_version`, `security_guide_version`, `compliant`, `group_name`, and `failed_rule_severity`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "This feature is exclusively used by the frontend", - "operationId": "ReportTestResultsOS", - "deprecated": true, - "responses": { - "200": { - "description": "Lists available OS versions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of available OS versions": { - "value": [ - "8.0" - ], - "summary": "", - "description": "" - } - }, - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - } - } - } - } - } - }, - "/reports/{report_id}/test_results/security_guide_versions": { - "get": { - "summary": "Request the list of available Security Guide versions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "This feature is exclusively used by the frontend", - "operationId": "ReportTestResultsSG", - "deprecated": true, - "responses": { - "200": { - "description": "Lists available Security Guide versions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of available Security Guide versions": { - "value": [ - "100.108.20" - ], - "summary": "", - "description": "" - } - }, - "schema": { - "type": "array", - "items": { - "type": "string" - } - } - } - } - } - } - } - }, - "/reports/{report_id}/test_results/{test_result_id}": { - "get": { - "summary": "Request a Test Result", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "test_result_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Reports" - ], - "description": "Retrieve a specific test result for a specific report.", - "operationId": "ReportTestResult", - "responses": { - "200": { - "description": "Returns a Test Result under a Report", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Test Result under a Report": { - "value": { - "data": { - "id": "189f38b6-47df-42d3-bae0-e57714dd95c7", - "end_time": "2025-04-17T11:48:32.949Z", - "failed_rule_count": 0, - "supported": true, - "score": 4.572102569812841, - "type": "test_result", - "display_name": "streich.test", - "groups": [], - "tags": [ - { - "key": "system", - "value": "bluetooth", - "namespace": "navigating" - }, - { - "key": "microchip", - "value": "bluetooth", - "namespace": "synthesizing" - }, - { - "key": "program", - "value": "bluetooth", - "namespace": "overriding" - }, - { - "key": "circuit", - "value": "virtual", - "namespace": "overriding" - }, - { - "key": "card", - "value": "optical", - "namespace": "compressing" - } - ], - "os_major_version": 8, - "os_minor_version": 0, - "compliant": false, - "system_id": "6622b662-c9fd-46eb-a402-55b94481ba1b", - "security_guide_version": "100.109.36" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/system" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Test Result": { - "value": { - "errors": [ - "V2::TestResult not found with ID 159c5527-6232-482f-9a57-9fc93a29e4c7" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/value_definitions": { - "get": { - "summary": "Request Value Definitions", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "limit", - "in": "query", - "required": false, - "description": "Number of items to return per page", - "schema": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10 - } - }, - { - "name": "offset", - "in": "query", - "required": false, - "description": "Offset of first item of paginated response", - "schema": { - "type": "integer", - "minimum": 0, - "default": 0 - } - }, - { - "name": "ids_only", - "in": "query", - "required": false, - "description": "Indicates whether to return only resource IDs.", - "schema": { - "type": "boolean" - } - }, - { - "name": "sort_by", - "in": "query", - "required": false, - "description": "Attribute and direction to sort the items by. Represented by an array of fields with an optional direction (`<key>:asc` or `<key>:desc`).<br><br>If no direction is selected, `<key>:asc` is used by default.", - "schema": { - "type": "array", - "items": { - "enum": [ - "title", - "title:asc", - "title:desc" - ] - } - } - }, - { - "name": "filter", - "in": "query", - "required": false, - "description": "Query string to filter items by their attributes. Compliant with <a href=\"https://github.com/wvanbergen/scoped_search/wiki/Query-language\" target=\"_blank\" title=\"github.com/wvanbergen/scoped_search\">scoped_search query language</a>. However, only `=` or `!=` (resp. `<>`) operators are supported.<br><br>Value Definitions are searchable using attributes `title` and `ref_id`<br><br>(e.g.: `(field_1=something AND field_2!=\"something else\") OR field_3>40`)", - "schema": { - "type": "string" - } - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a list of the fields which can be edited within a profile.", - "operationId": "ValueDefinitions", - "responses": { - "200": { - "description": "Lists Value Definitions", - "content": { - "application/vnd.api+json": { - "examples": { - "List of Value Definitions": { - "value": { - "data": [ - { - "id": "0520716a-ee31-4549-8431-e9d0fe8d7d1b", - "ref_id": "foo_value_800c458f-3b4d-4b92-bc14-59d34010fab4", - "title": "Quidem et accusamus sequi.", - "description": "Dolorem non neque. Et quaerat facilis. Iusto ut ex.", - "value_type": "number", - "default_value": "0.30564241140585313", - "type": "value_definition" - }, - { - "id": "0ebeefaf-862d-47c7-9b2c-e63efc6de835", - "ref_id": "foo_value_db36b895-ea81-4649-a57c-1524194b9f63", - "title": "Ut quia non ex.", - "description": "Magnam atque veritatis. Et rerum placeat. Velit minima ut.", - "value_type": "number", - "default_value": "0.11972968764362624", - "type": "value_definition" - }, - { - "id": "1367a267-fa7d-417f-b2f5-048a765352ef", - "ref_id": "foo_value_ad7cc9c5-c960-49b1-90bc-69284c958aa5", - "title": "Ex in commodi minus.", - "description": "Quidem voluptatem eius. Accusantium vitae est. Rerum aut itaque.", - "value_type": "number", - "default_value": "0.7598861441027798", - "type": "value_definition" - }, - { - "id": "15d754f0-9c0b-4536-9a1f-860f7b41c9c6", - "ref_id": "foo_value_7fd4c50b-5568-45db-9253-cfbcc8a9d42f", - "title": "Id dolor omnis ipsum.", - "description": "Ipsum illum exercitationem. Voluptatem ipsa voluptate. Quo beatae et.", - "value_type": "number", - "default_value": "0.18447449106790792", - "type": "value_definition" - }, - { - "id": "17cb7cbb-221f-436b-9c46-958f8f727708", - "ref_id": "foo_value_bf260328-174d-467a-af69-2d027c25ee05", - "title": "Voluptatibus doloribus qui pariatur.", - "description": "Unde ut quibusdam. Incidunt quia nisi. Vitae harum asperiores.", - "value_type": "number", - "default_value": "0.18627700715206041", - "type": "value_definition" - }, - { - "id": "1ad5157d-a329-4d56-b456-ed98e5813a85", - "ref_id": "foo_value_ba618376-ef4f-45f4-a76b-c4f09bfca36d", - "title": "Omnis cumque odit facilis.", - "description": "Totam doloremque quia. Culpa similique tempore. Amet deserunt est.", - "value_type": "number", - "default_value": "0.3623214604594782", - "type": "value_definition" - }, - { - "id": "21421231-1519-4b02-8ee6-fc4fa5648f10", - "ref_id": "foo_value_bd1c4239-7ede-43dc-826b-144712721e7e", - "title": "Quia neque error blanditiis.", - "description": "Quisquam sequi doloribus. Blanditiis voluptates ad. Quam provident aut.", - "value_type": "number", - "default_value": "0.8578627192053798", - "type": "value_definition" - }, - { - "id": "2bca6bdf-f3e3-4d26-8a1f-9b9a78d57b75", - "ref_id": "foo_value_3a063381-a6be-42f5-bd2b-1398b2e6c002", - "title": "Voluptates officiis et ea.", - "description": "Magni sit voluptates. Natus iusto et. Nisi dolor repellendus.", - "value_type": "number", - "default_value": "0.4442064226635942", - "type": "value_definition" - }, - { - "id": "305ba7d0-9799-4cde-ab7d-b1bd89967bd6", - "ref_id": "foo_value_afb0b435-4ba9-4794-a8db-387dd099e6d2", - "title": "Ut repellendus minus sit.", - "description": "Magnam quas nobis. Rerum facilis ad. Nisi vitae beatae.", - "value_type": "number", - "default_value": "0.7188821353015122", - "type": "value_definition" - }, - { - "id": "44b17131-9c32-4fcd-bfd2-9af577572c25", - "ref_id": "foo_value_346dbf1c-d530-433b-ab4e-37909c26f6a6", - "title": "Magni sit rem ab.", - "description": "Doloremque officia qui. Et ab reiciendis. Tempora et deserunt.", - "value_type": "number", - "default_value": "0.857276471247882", - "type": "value_definition" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/8c945a49-75c3-4dce-8a95-adce1008c6ed/value_definitions?limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/8c945a49-75c3-4dce-8a95-adce1008c6ed/value_definitions?limit=10&offset=20", - "next": "/api/compliance/v2/security_guides/8c945a49-75c3-4dce-8a95-adce1008c6ed/value_definitions?limit=10&offset=10" - } - }, - "summary": "", - "description": "" - }, - "List of Value Definitions sorted by \"title:asc\"": { - "value": { - "data": [ - { - "id": "91d14507-40a8-4bfd-8395-3444ab676f40", - "ref_id": "foo_value_d713c08b-7981-4ade-83bc-bf03886ae21c", - "title": "At non qui non.", - "description": "Natus amet sapiente. Expedita omnis consectetur. Laudantium neque quibusdam.", - "value_type": "number", - "default_value": "0.2285234439975904", - "type": "value_definition" - }, - { - "id": "b1f9e129-8ef3-41e8-bfd0-8ff58dbc7cab", - "ref_id": "foo_value_6c9bf3a9-e377-46d6-8bc4-8a9e62da5aa2", - "title": "Commodi quibusdam dolores quo.", - "description": "Modi et praesentium. Exercitationem fugiat similique. At est aut.", - "value_type": "number", - "default_value": "0.6576561892131595", - "type": "value_definition" - }, - { - "id": "918fab2a-83de-4ecb-a6b1-fc7f8f36b05f", - "ref_id": "foo_value_7dc968bc-4a58-4286-a263-679846713cd9", - "title": "Consequuntur voluptas nostrum accusamus.", - "description": "Vero autem quod. Quis iste officia. Voluptatem ex aliquid.", - "value_type": "number", - "default_value": "0.9535744364447897", - "type": "value_definition" - }, - { - "id": "d8e1a022-dd17-4a74-9a39-28419d330f98", - "ref_id": "foo_value_7d022fb5-0ddd-4fc2-bb05-186834d0c1a2", - "title": "Debitis recusandae qui architecto.", - "description": "In natus iure. Iure ut nisi. Beatae est perferendis.", - "value_type": "number", - "default_value": "0.9539895247499673", - "type": "value_definition" - }, - { - "id": "35b00af9-c4d2-4b20-a711-c1bbb6b0a0de", - "ref_id": "foo_value_11cf3ee9-33ac-4a88-99a6-ab2332f7cbc1", - "title": "Distinctio earum et itaque.", - "description": "Porro sint molestias. Adipisci corrupti velit. Minima suscipit eius.", - "value_type": "number", - "default_value": "0.12355069585734524", - "type": "value_definition" - }, - { - "id": "3ba4e580-53f5-42a1-9381-5f3fbd2632ec", - "ref_id": "foo_value_5b2d6c30-06c3-40a9-9e73-2d865dfe96df", - "title": "Dolor molestiae modi sapiente.", - "description": "Consequatur repellendus mollitia. Perspiciatis tenetur sapiente. Ipsa ullam similique.", - "value_type": "number", - "default_value": "0.7244121372201825", - "type": "value_definition" - }, - { - "id": "6f4a2850-9d69-4f3a-8e2f-1af850d6e6ed", - "ref_id": "foo_value_85c188af-61ff-44f0-9ee0-afc6aae299cf", - "title": "Dolor quas et facilis.", - "description": "In rem voluptates. Quis quod mollitia. Sunt ut magni.", - "value_type": "number", - "default_value": "0.8104222252150413", - "type": "value_definition" - }, - { - "id": "e065bab4-5147-4720-b482-10571955bea8", - "ref_id": "foo_value_2f6dc9a6-489d-4616-a806-d117e2ab2796", - "title": "Dolore ad voluptate iure.", - "description": "Consequatur necessitatibus illum. Sed possimus autem. Minima qui et.", - "value_type": "number", - "default_value": "0.7478943286685453", - "type": "value_definition" - }, - { - "id": "ed440768-69a7-4180-82c0-b1819b010a7a", - "ref_id": "foo_value_05711f3a-b538-4bb6-9e66-1acfaba0b671", - "title": "Dolorem fuga magnam sed.", - "description": "Explicabo vitae et. Adipisci tempora amet. Consequatur unde non.", - "value_type": "number", - "default_value": "0.9600157457034818", - "type": "value_definition" - }, - { - "id": "f83451fb-7c39-4c85-964f-1575b60955cf", - "ref_id": "foo_value_72e4bda6-7c6f-4e73-95f9-ce128a63aab8", - "title": "Earum officia cum et.", - "description": "Sit ipsam enim. Eaque accusamus culpa. Dolor atque itaque.", - "value_type": "number", - "default_value": "0.03731280565415673", - "type": "value_definition" - } - ], - "meta": { - "total": 25, - "limit": 10, - "offset": 0, - "sort_by": "title" - }, - "links": { - "first": "/api/compliance/v2/security_guides/08549b82-399f-4373-91bd-4caf6e105440/value_definitions?limit=10&offset=0&sort_by=title", - "last": "/api/compliance/v2/security_guides/08549b82-399f-4373-91bd-4caf6e105440/value_definitions?limit=10&offset=20&sort_by=title", - "next": "/api/compliance/v2/security_guides/08549b82-399f-4373-91bd-4caf6e105440/value_definitions?limit=10&offset=10&sort_by=title" - } - }, - "summary": "", - "description": "" - }, - "List of Value Definitions filtered by '(title=Fuga natus exercitationem quasi.)'": { - "value": { - "data": [ - { - "id": "09ed409a-8dcb-47f3-be95-0fcafe273ffd", - "ref_id": "foo_value_0c94d000-67a7-4498-8004-49f55fb17668", - "title": "Fuga natus exercitationem quasi.", - "description": "Et eos enim. Recusandae eum quis. Aspernatur vel ipsam.", - "value_type": "number", - "default_value": "0.9432507446868649", - "type": "value_definition" - } - ], - "meta": { - "total": 1, - "filter": "(title=\"Fuga natus exercitationem quasi.\")", - "limit": 10, - "offset": 0 - }, - "links": { - "first": "/api/compliance/v2/security_guides/a5261732-5820-4c03-8f29-57b6d0d7b42e/value_definitions?filter=%28title%3D%22Fuga+natus+exercitationem+quasi.%22%29&limit=10&offset=0", - "last": "/api/compliance/v2/security_guides/a5261732-5820-4c03-8f29-57b6d0d7b42e/value_definitions?filter=%28title%3D%22Fuga+natus+exercitationem+quasi.%22%29&limit=10&offset=0" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "meta": { - "$ref": "#/components/schemas/metadata" - }, - "links": { - "$ref": "#/components/schemas/links" - }, - "data": { - "type": "array", - "items": { - "properties": { - "schema": { - "$ref": "#/components/schemas/value_definition" - } - } - } - } - } - } - } - } - }, - "422": { - "description": "Returns with Unprocessable Content", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when sorting by incorrect parameter": { - "value": { - "errors": [ - "Result cannot be sorted by the 'description' column." - ] - }, - "summary": "", - "description": "" - }, - "Description of an error when requesting higher limit than supported": { - "value": { - "errors": [ - "Invalid parameter: limit must be less than or equal to 100" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - }, - "/security_guides/{security_guide_id}/value_definitions/{value_definition_id}": { - "get": { - "summary": "Request a Value Definition", - "parameters": [ - { - "name": "X-RH-IDENTITY", - "in": "header", - "schema": { - "type": "string" - }, - "description": "For internal use only" - }, - { - "name": "security_guide_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - }, - { - "name": "value_definition_id", - "in": "path", - "required": true, - "schema": { - "type": "string" - } - } - ], - "tags": [ - "Content" - ], - "description": "Retrieve a specific value definition.", - "operationId": "ValueDefinition", - "responses": { - "200": { - "description": "Returns a Value Definition", - "content": { - "application/vnd.api+json": { - "examples": { - "Returns a Value Definition": { - "value": { - "data": { - "id": "a4cb6aca-41bc-448a-9d9f-30768050ca96", - "ref_id": "foo_value_66053736-370d-4de6-a6a8-05fe41e86c2d", - "title": "Id est illum totam.", - "description": "Rerum sunt ex. Aliquid et necessitatibus. At et tempore.", - "value_type": "number", - "default_value": "0.23679280802456693", - "type": "value_definition" - } - }, - "summary": "", - "description": "" - } - }, - "schema": { - "type": "object", - "properties": { - "data": { - "type": "object", - "properties": { - "schema": { - "$ref": "#/components/schemas/value_definition" - } - } - } - } - } - } - } - }, - "404": { - "description": "Returns with Not Found", - "content": { - "application/vnd.api+json": { - "examples": { - "Description of an error when requesting a non-existing Value Definition": { - "value": { - "errors": [ - "V2::ValueDefinition not found with ID 5a8deb38-fa92-44c1-80ca-5f32e7b8793e" - ] - }, - "summary": "", - "description": "" - } - }, - "schema": { - "$ref": "#/components/schemas/errors" - } - } - } - } - } - } - } - }, - "components": { - "schemas": { - "errors": { - "type": "object", - "required": [ - "errors" - ], - "properties": { - "errors": { - "type": "array", - "items": { - "type": "string", - "examples": [ - "V2::SecurityGuide not found with ID a4708198-9d00-4035-bf57-1e7aaad217c5" - ] - } - } - } - }, - "id": { - "type": "string", - "format": "uuid", - "readOnly": true - }, - "links": { - "type": "object", - "properties": { - "first": { - "type": "string", - "format": "uri", - "readOnly": true, - "description": "Link to first page" - }, - "last": { - "type": "string", - "format": "uri", - "readOnly": true, - "description": "Link to last page" - }, - "previous": { - "type": "string", - "format": "uri", - "readOnly": true, - "description": "Link to previous page" - }, - "next": { - "type": "string", - "format": "uri", - "readOnly": true, - "description": "Link to next page" - } - } - }, - "metadata": { - "type": "object", - "properties": { - "total": { - "type": "number", - "examples": [ - 1, - 42, - 770 - ], - "readOnly": true, - "description": "Total number of items" - }, - "limit": { - "type": "number", - "maximum": 100, - "minimum": 1, - "default": 10, - "examples": [ - 10, - 100 - ], - "readOnly": true, - "description": "Number of items returned per page" - }, - "offset": { - "type": "number", - "minimum": 0, - "default": 0, - "examples": [ - 15, - 90 - ], - "readOnly": true, - "description": "Offset of the first item of paginated response" - }, - "sort_by": { - "type": "string", - "examples": [ - "version:asc" - ], - "description": "Attribute and direction the items are sorted by" - }, - "filter": { - "type": "string", - "default": "", - "examples": [ - "title='Standard System Security Profile for Fedora'" - ], - "description": "Query string used to filter items by their attributes" - } - } - }, - "policy": { - "type": "object", - "required": [ - "compliance_threshold", - "profile_id" - ], - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "enum": [ - "policy" - ], - "readOnly": true - }, - "title": { - "type": "string", - "examples": [ - "CIS Red Hat Enterprise Linux 7 Benchmark" - ], - "description": "Short title of the Policy" - }, - "description": { - "type": "string", - "examples": [ - "This profile defines a baseline that aligns to the Center for Internet Security®Red Hat Enterprise Linux 7 Benchmark™, v2.2.0, released 12-27-2017." - ], - "description": "Longer description of the Policy" - }, - "business_objective": { - "type": "string", - "examples": [ - "Guide to the Secure Configuration of Red Hat Enterprise Linux 7" - ], - "description": "The Business Objective associated to the Policy" - }, - "compliance_threshold": { - "type": "number", - "examples": [ - 90 - ], - "maximum": 100, - "minimum": 0, - "description": "The percentage above which the Policy meets compliance requirements" - }, - "profile_id": { - "type": "string", - "format": "uuid", - "writeOnly": true, - "examples": [ - "9c4bccad-eb1f-473f-bd3d-2de6e125f725" - ], - "description": "Identifier of the underlying Profile" - }, - "os_major_version": { - "type": "number", - "minimum": 6, - "examples": [ - 7 - ], - "description": "Major version of the Operating System that the Policy covers", - "readOnly": true - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_profile_pci-dss" - ], - "description": "Identificator of the Profile", - "readOnly": true - }, - "profile_title": { - "type": "string", - "examples": [ - "CIS Red Hat Enterprise Linux 7 Benchmark" - ], - "description": "Title of the associated Policy", - "readOnly": true - }, - "total_system_count": { - "type": "number", - "minium": 0, - "examples": [ - 3 - ], - "description": "The number of Systems assigned to this Policy", - "readOnly": true - } - } - }, - "policy_update": { - "type": "object", - "properties": { - "description": { - "type": "string", - "examples": [ - "This profile defines a baseline that aligns to the Center for Internet Security®Red Hat Enterprise Linux 7 Benchmark™, v2.2.0, released 12-27-2017." - ], - "description": "Longer description of the Policy" - }, - "business_objective": { - "type": "string", - "examples": [ - "Guide to the Secure Configuration of Red Hat Enterprise Linux 7" - ], - "description": "The Business Objective associated to the Policy" - }, - "compliance_threshold": { - "type": "number", - "examples": [ - 90 - ], - "maximum": 100, - "minimum": 0, - "description": "The percentage above which the Policy meets compliance requirements" - } - } - }, - "profile": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "readOnly": true, - "enum": [ - "profile" - ] - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_profile_pci-dss" - ], - "readOnly": true, - "description": "Identificator of the Profile" - }, - "title": { - "type": "string", - "examples": [ - "CIS Red Hat Enterprise Linux 7 Benchmark" - ], - "readOnly": true, - "description": "Short title of the Profile" - }, - "description": { - "type": "string", - "examples": [ - "This profile defines a baseline that aligns to the Center for Internet Security®Red Hat Enterprise Linux 7 Benchmark™, v2.2.0, released 12-27-2017." - ], - "readOnly": true, - "description": "Longer description of the Profile" - }, - "value_overrides": { - "type": "object", - "readOnly": true, - "description": "Pair of keys and values for Value Definition customizations" - } - } - }, - "report": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "enum": [ - "report" - ], - "readOnly": true - }, - "title": { - "type": "string", - "examples": [ - "CIS Red Hat Enterprise Linux 7 Benchmark" - ], - "description": "Short title of the Report", - "readOnly": true - }, - "business_objective": { - "type": "string", - "examples": [ - "Guide to the Secure Configuration of Red Hat Enterprise Linux 7" - ], - "description": "The Business Objective associated to the Policy", - "readOnly": true - }, - "compliance_threshold": { - "type": "number", - "examples": [ - 90 - ], - "maximum": 100, - "minimum": 0, - "description": "The percentage above which the Policy meets compliance requirements", - "readOnly": true - }, - "os_major_version": { - "type": "number", - "minimum": 6, - "examples": [ - 7 - ], - "description": "Major version of the Operating System that the Report covers", - "readOnly": true - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_profile_pci-dss" - ], - "description": "Identificator of the Profile", - "readOnly": true - }, - "profile_title": { - "type": "string", - "examples": [ - "CIS Red Hat Enterprise Linux 7 Benchmark" - ], - "description": "Title of the associated Profile", - "readOnly": true - }, - "percent_compliant": { - "type": "number", - "minimum": 0, - "maximum": 100, - "examples": [ - 68 - ], - "description": "Describes percentage of compliant systems", - "readOnly": true - }, - "assigned_system_count": { - "type": "number", - "minium": 1, - "examples": [ - 42 - ], - "description": "The number of Systems assigned to this Report. Not visible under the Systems endpoint.", - "readOnly": true - }, - "compliant_system_count": { - "type": "number", - "minium": 0, - "examples": [ - 21 - ], - "description": "The number of compliant Systems in this Report. Inconsistent under the Systems endpoint.", - "readOnly": true - }, - "all_systems_exposed": { - "type": "boolean", - "description": "Informs if the user has access to all the Systems under the Report. \\\n Inconsistent under the Systems endpoint.", - "examples": [ - false - ], - "readOnly": true - }, - "unsupported_system_count": { - "type": "number", - "minium": 0, - "examples": [ - 3 - ], - "description": "The number of unsupported Systems in this Report. \\\n Inconsistent under the Systems endpoint.", - "readOnly": true - }, - "reported_system_count": { - "type": "number", - "minium": 0, - "examples": [ - 3 - ], - "description": "The number of Systems in this Report that have Test Results available. \\\n Inconsistent under the Systems endpoint.", - "readOnly": true - } - } - }, - "report_stats": { - "type": "array", - "items": { - "type": "object", - "properties": { - "title": { - "type": "string", - "examples": [ - "Remove tftp" - ], - "readOnly": true, - "description": "Short title of the Rule" - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_rule_package_tftp_removed" - ], - "readOnly": true, - "description": "Identificator of the Rule" - }, - "identifier": { - "type": "object", - "readOnly": true, - "description": "Identifier of the Rule", - "properties": { - "label": { - "type": "string", - "readOnly": true, - "examples": [ - "CCE-80798-2" - ] - }, - "system": { - "type": "string", - "readOnly": true, - "examples": [ - "https://nvd.nist.gov/cce/index.cfm" - ] - } - }, - "examples": [ - "CEE-1234-123" - ] - }, - "severity": { - "type": "string", - "examples": [ - "low" - ], - "readOnly": true, - "description": "The severity of the Rule" - }, - "count": { - "type": "integer", - "examples": [ - 102 - ], - "readOnly": true, - "description": "Number of failures" - } - } - } - }, - "rule": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "readOnly": true, - "enum": [ - "rule" - ] - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_rule_package_tftp_removed" - ], - "readOnly": true, - "description": "Identificator of the Rule" - }, - "rule_group_id": { - "type": "string", - "format": "uuid", - "examples": [ - "cf50fd69-0205-49e8-8e12-c1b2a6291f1d" - ], - "readOnly": true, - "description": "UUID of the parent Rule Group" - }, - "title": { - "type": "string", - "examples": [ - "Remove tftp" - ], - "readOnly": true, - "description": "Short title of the Rule" - }, - "rationale": { - "type": "string", - "examples": [ - "It is recommended that TFTP be remvoed, unless there is a specific need for TFTP (such as a boot server). In that case, use extreme caution when configuring the services." - ], - "readOnly": true, - "description": "Rationale of the Rule" - }, - "description": { - "type": "string", - "examples": [ - "Trivial File Transfer Protocol (TFTP) is a simple file transfer protocol, typically used to automatically transfer configuration or boot files between machines. TFTP does not support authentication and can be easily hacked. The package tftp is a client program that allows for connections to a tftp server." - ], - "readOnly": true, - "description": "Longer description of the Rule" - }, - "precedence": { - "type": "integer", - "examples": [ - 3 - ], - "readOnly": true, - "description": "The original sorting precedence of the Rule in the Security Guide" - }, - "severity": { - "type": "string", - "examples": [ - "low" - ], - "readOnly": true, - "description": "The severity of the Rule" - }, - "identifier": { - "type": "object", - "readOnly": true, - "description": "Identifier of the Rule", - "properties": { - "label": { - "type": "string", - "readOnly": true, - "examples": [ - "CCE-80798-2" - ] - }, - "system": { - "type": "string", - "readOnly": true, - "examples": [ - "https://nvd.nist.gov/cce/index.cfm" - ] - } - }, - "examples": [ - "CEE-1234-123" - ] - }, - "references": { - "type": "array", - "items": { - "type": "object", - "readOnly": true, - "description": "List of Tags assigned to the System", - "properties": { - "label": { - "type": "string", - "readOnly": true, - "examples": [ - "APO01.06" - ] - }, - "href": { - "type": "string", - "readOnly": true, - "examples": [ - "https://www.isaca.org/resources/cobit" - ] - } - } - }, - "readOnly": true, - "description": "Array of the Rule References" - }, - "remediation_available": { - "type": "boolean", - "examples": [ - true, - false - ], - "readOnly": true, - "description": "Whether or not a remediation is available for the given rule." - }, - "remediation_issue_id": { - "type": [ - "string", - "null" - ], - "examples": [ - "ssg:xccdf_org.ssgproject.content_benchmark_RHEL-6|0.1.46|rht-ccp|xccdf_org.ssgproject.content_rule_sshd_disable_rhosts" - ], - "readOnly": true, - "description": "The idenfitier of the remediation associated to this rule, only available under profiles." - } - } - }, - "rule_group": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "readOnly": true, - "enum": [ - "rule_group" - ] - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_group_locking_out_password_attempts" - ], - "readOnly": true, - "description": "Identificator of the Rule Group" - }, - "title": { - "type": "string", - "examples": [ - "Set Lockouts for Failed Password Attempt" - ], - "readOnly": true, - "description": "Short title of the Rule Group" - }, - "rationale": { - "type": "string", - "examples": [ - "By limiting the number of failed logon attempts, the risk of unauthorized system access via user password guessing, otherwise known as brute-forcing, is reduced. Limits are imposed by locking the account." - ], - "readOnly": true, - "description": "Rationale of the Rule Group" - }, - "description": { - "type": "string", - "examples": [ - "The pam_faillock PAM module provides the capability to lock out user accounts after a number of failed login attempts. Its documentation is available in /usr/share/doc/pam-VERSION/txts/README.pam_faillock." - ], - "readOnly": true, - "description": "Longer description of the Rule Group" - }, - "precedence": { - "type": "integer", - "examples": [ - 3 - ], - "readOnly": true, - "description": "The original sorting precedence of the Rule Group in the Security Guide" - } - } - }, - "rule_result": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "readOnly": true, - "enum": [ - "rule" - ] - }, - "result": { - "type": "string", - "enum": [ - "pass", - "fail", - "error", - "unknown", - "fixed", - "notapplicable", - "notchecked", - "informational", - "notselected" - ], - "readOnly": true, - "description": "Status of the Rule Result" - }, - "rule_id": { - "type": "string", - "format": "uuid", - "examples": [ - "ac0475d7-043c-439b-abef-606f02531e10" - ], - "readOnly": true, - "description": "UUID of the affected Rule" - }, - "system_id": { - "type": "string", - "format": "uuid", - "examples": [ - "e6ba5c79-48af-4899-bb1d-964116b58c7a" - ], - "readOnly": true, - "description": "UUID of the affected System" - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_rule_package_tftp_removed" - ], - "readOnly": true, - "description": "Identificator of the Rule" - }, - "rule_group_id": { - "type": "string", - "format": "uuid", - "examples": [ - "cf50fd69-0205-49e8-8e12-c1b2a6291f1d" - ], - "readOnly": true, - "description": "UUID of the parent Rule Group" - }, - "title": { - "type": "string", - "examples": [ - "Remove tftp" - ], - "readOnly": true, - "description": "Short title of the Rule" - }, - "rationale": { - "type": "string", - "examples": [ - "It is recommended that TFTP be remvoed, unless there is a specific need for TFTP (such as a boot server). In that case, use extreme caution when configuring the services." - ], - "readOnly": true, - "description": "Rationale of the Rule" - }, - "description": { - "type": "string", - "examples": [ - "Trivial File Transfer Protocol (TFTP) is a simple file transfer protocol, typically used to automatically transfer configuration or boot files between machines. TFTP does not support authentication and can be easily hacked. The package tftp is a client program that allows for connections to a tftp server." - ], - "readOnly": true, - "description": "Longer description of the Rule" - }, - "precedence": { - "type": "integer", - "examples": [ - 3 - ], - "readOnly": true, - "description": "The original sorting precedence of the Rule in the Security Guide" - }, - "severity": { - "type": "string", - "examples": [ - "low" - ], - "readOnly": true, - "description": "The severity of the Rule" - }, - "remediation_issue_id": { - "type": [ - "string", - "null" - ], - "examples": [ - "ssg:xccdf_org.ssgproject.content_benchmark_RHEL-6|0.1.46|rht-ccp|xccdf_org.ssgproject.content_rule_sshd_disable_rhosts" - ], - "readOnly": true, - "description": "The idenfitier of the remediation associated to this rule, only available under profiles." - } - } - }, - "rule_tree": { - "type": "array", - "items": { - "oneOf": [ - { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "enum": [ - "rule_group" - ] - }, - "children": { - "$ref": "#/components/schemas/rule_tree" - } - } - }, - { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "enum": [ - "rule" - ] - } - } - } - ] - } - }, - "security_guide": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "readOnly": true, - "enum": [ - "security_guide" - ] - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_benchmark_RHEL-7" - ], - "readOnly": true, - "description": "Identificator of the Security Guide" - }, - "title": { - "type": "string", - "examples": [ - "Guide to the Secure Configuration of Red Hat Enterprise Linux 7" - ], - "readOnly": true, - "description": "Short title of the Security Guide" - }, - "version": { - "type": "string", - "examples": [ - "0.1.46" - ], - "readOnly": true, - "description": "Version of the Security Guide" - }, - "description": { - "type": "string", - "examples": [ - "This guide presents a catalog of security-relevant configuration settings for Red Hat Enterprise Linux 7." - ], - "readOnly": true, - "description": "Longer description of the Security Guide" - }, - "os_major_version": { - "type": "number", - "minimum": 6, - "examples": [ - 7 - ], - "readOnly": true, - "description": "Major version of the Operating System that the Security Guide covers" - } - } - }, - "supported_profile": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "readOnly": true, - "enum": [ - "supported_profile" - ] - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_profile_cis" - ], - "readOnly": true, - "description": "Identificator of the latest supported Profile" - }, - "title": { - "type": "string", - "examples": [ - "CIS Red Hat Enterprise Linux 7 Benchmark" - ], - "readOnly": true, - "description": "Short title of the Profile" - }, - "description": { - "type": "string", - "examples": [ - "This profile defines a baseline that aligns to the Center for Internet Security®Red Hat Enterprise Linux 7 Benchmark™, v2.2.0, released 12-27-2017." - ], - "readOnly": true, - "description": "Longer description of the Profile" - }, - "security_guide_id": { - "type": "string", - "format": "uuid", - "examples": [ - "e6ba5c79-48af-4899-bb1d-964116b58c7a" - ], - "readOnly": true, - "description": "UUID of the latest Security Guide supporting this Profile" - }, - "security_guide_version": { - "type": "string", - "examples": [ - "0.1.72" - ], - "readOnly": true, - "description": "Version of the latest Security Guide supporting this Profile" - }, - "os_major_version": { - "type": "number", - "examples": [ - 7 - ], - "readOnly": true, - "description": "Major version of the Operating System that the Profile covers" - }, - "os_minor_versions": { - "type": "array", - "items": { - "type": "number", - "examples": [ - 1 - ] - }, - "readOnly": true, - "description": "List of the supported Operating System minor versions that the Profile covers" - } - } - }, - "system": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "enum": [ - "system" - ], - "readOnly": true - }, - "display_name": { - "type": "string", - "readOnly": true, - "examples": [ - "localhost" - ], - "description": "Display Name of the System" - }, - "groups": { - "type": "array", - "readOnly": true, - "items": { - "type": "object", - "description": "List of Inventory Groups the System belongs to", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "name": { - "type": "string", - "readOnly": true, - "examples": [ - "production" - ] - } - } - } - }, - "culled_timestamp": { - "type": "string", - "readOnly": true, - "examples": [ - "2020-06-04T19:31:55Z" - ] - }, - "last_check_in": { - "type": "string", - "readOnly": true, - "examples": [ - "2020-06-04T19:31:55Z" - ] - }, - "stale_timestamp": { - "type": "string", - "readOnly": true, - "examples": [ - "2020-06-04T19:31:55Z" - ] - }, - "stale_warning_timestamp": { - "type": "string", - "readOnly": true, - "examples": [ - "2020-06-04T19:31:55Z" - ] - }, - "updated": { - "type": "string", - "readOnly": true, - "examples": [ - "2020-06-04T19:31:55Z" - ] - }, - "insights_id": { - "$ref": "#/components/schemas/id" - }, - "tags": { - "type": "array", - "readOnly": true, - "items": { - "type": "object", - "readOnly": true, - "description": "List of Tags assigned to the System", - "properties": { - "namespace": { - "type": "string", - "readOnly": true, - "examples": [ - "insights" - ] - }, - "key": { - "type": "string", - "readOnly": true, - "examples": [ - "environment" - ] - }, - "value": { - "type": "string", - "readOnly": true, - "examples": [ - "production" - ] - } - } - } - }, - "os_major_version": { - "type": "number", - "examples": [ - 7 - ], - "readOnly": true, - "description": "Major version of the Operating System" - }, - "os_minor_version": { - "type": "number", - "examples": [ - 1 - ], - "readOnly": true, - "description": "Minor version of the Operating System" - }, - "policies": { - "type": "array", - "readOnly": true, - "description": "List of Policies assigned to the System, visible only when not listing Systems under a given Policy", - "items": { - "type": "object", - "readOnly": true, - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "title": { - "type": "string", - "readOnly": true, - "examples": [ - "CIS Red Hat Enterprise Linux 7 Benchmark" - ], - "description": "Short title of the Policy" - } - } - } - } - } - }, - "tailoring": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "readOnly": true, - "enum": [ - "tailoring" - ] - }, - "profile_id": { - "type": "string", - "examples": [ - "cde8be06-74bc-4a2d-9e7f-11d30c5ea588" - ], - "readOnly": true, - "description": "Identificator of the Profile from which the Tailoring was cloned" - }, - "security_guide_id": { - "type": "string", - "examples": [ - "8800e1d8-70da-4e62-8cf0-16e8cee784c7" - ], - "readOnly": true, - "description": "Identificator of the Security Guide that contains the parent Profile" - }, - "security_guide_version": { - "type": "string", - "examples": [ - "0.1.210" - ], - "readOnly": true, - "description": "Version of the Security Guide that contains the parent Profile" - }, - "os_major_version": { - "type": "number", - "examples": [ - 7 - ], - "readOnly": true, - "description": "Major version of the Operating System that the Tailoring covers" - }, - "os_minor_version": { - "type": "number", - "examples": [ - 1 - ], - "readOnly": true, - "description": "Minor version of the Operating System that the Tailoring covers" - }, - "value_overrides": { - "type": "object", - "description": "Pair of keys and values for Value Definition customizations", - "examples": [ - { - "f7ed6d40-d519-4033-8e2b-314dcab6f724": "foo", - "9c8bce0b-b9ac-4f1f-b600-9c7708a4e53c": "123", - "39f376e8-29b5-4d7b-95d7-59f057deb74a": "false" - } - ] - } - } - }, - "tailoring_create": { - "type": "object", - "required": [ - "os_minor_version" - ], - "properties": { - "os_minor_version": { - "type": "number", - "examples": [ - 1 - ], - "description": "Minor version of the Operating System that the Tailoring covers" - } - } - }, - "tailoring_file": { - "title": "Tailoring File", - "description": "Defines customizations of rules and variables for a set of profiles", - "type": "object", - "additionalProperties": true, - "properties": { - "profiles": { - "type": "array", - "items": { - "type": "object", - "title": "Profile", - "description": "A new tailored profile with modifications", - "additionalProperties": true, - "anyOf": [ - { - "required": [ - "id", - "base_profile_id" - ] - }, - { - "required": [ - "id", - "title" - ] - } - ], - "properties": { - "id": { - "type": "string", - "description": "New profile identifier, can be same as 'base_profile_id', to 'shadow' the origin" - }, - "base_profile_id": { - "type": "string", - "description": "Original profile identifier, the base for modifications" - }, - "title": { - "type": "string", - "description": "Title for the new profile, inherited from base profile if not given, required if there is no base profile" - }, - "groups": { - "type": "object", - "description": "Group modifications, keys are identifiers", - "additionalProperties": { - "type": "object", - "additionalProperties": true, - "anyOf": [ - { - "required": [ - "evaluate" - ] - } - ], - "properties": { - "evaluate": { - "type": "boolean", - "description": "Includes or excludes a group of rules from evaluation" - } - } - } - }, - "rules": { - "type": "object", - "description": "Rule modifications, keys are identifiers", - "additionalProperties": { - "type": "object", - "additionalProperties": true, - "anyOf": [ - { - "required": [ - "evaluate" - ] - }, - { - "required": [ - "severity" - ] - }, - { - "required": [ - "role" - ] - } - ], - "properties": { - "evaluate": { - "type": "boolean", - "description": "Includes or excludes a rule from evaluation" - }, - "severity": { - "type": "string", - "enum": [ - "unknown", - "info", - "low", - "medium", - "high" - ], - "description": "Overrides severity level of the rule" - }, - "role": { - "type": "string", - "enum": [ - "full", - "unscored", - "unchecked" - ], - "description": "Overrides role of the rule" - } - } - } - }, - "variables": { - "type": "object", - "description": "Variables modifications, keys are identifiers", - "additionalProperties": { - "type": "object", - "additionalProperties": true, - "oneOf": [ - { - "required": [ - "value" - ] - }, - { - "required": [ - "option_id" - ] - } - ], - "properties": { - "value": { - "type": [ - "string", - "integer", - "boolean" - ], - "description": "Directly overrides variable's value with a given value" - }, - "option_id": { - "type": "string", - "description": "Overrides variable's value with a predefined value identified by 'option_id'" - } - } - } - } - } - } - } - } - }, - "test_result": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "enum": [ - "test_result" - ], - "readOnly": true - }, - "display_name": { - "type": "string", - "readOnly": true, - "examples": [ - "localhost" - ], - "description": "Display Name of the System" - }, - "groups": { - "type": "array", - "readOnly": true, - "items": { - "type": "object", - "description": "List of Inventory Groups the System belongs to", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "name": { - "type": "string", - "readOnly": true, - "examples": [ - "production" - ] - } - } - } - }, - "tags": { - "type": "array", - "readOnly": true, - "items": { - "type": "object", - "readOnly": true, - "description": "List of Tags assigned to the System", - "properties": { - "namespace": { - "type": "string", - "readOnly": true, - "examples": [ - "insights" - ] - }, - "key": { - "type": "string", - "readOnly": true, - "examples": [ - "environment" - ] - }, - "value": { - "type": "string", - "readOnly": true, - "examples": [ - "production" - ] - } - } - } - }, - "system_id": { - "type": "string", - "format": "uuid", - "examples": [ - "e6ba5c79-48af-4899-bb1d-964116b58c7a" - ], - "readOnly": true, - "description": "UUID of the underlying System" - }, - "os_major_version": { - "type": "number", - "examples": [ - 7 - ], - "readOnly": true, - "description": "Major version of the Operating System" - }, - "os_minor_version": { - "type": "number", - "examples": [ - 1 - ], - "readOnly": true, - "description": "Minor version of the Operating System" - }, - "compliant": { - "type": [ - "boolean", - "null" - ], - "examples": [ - false, - true - ], - "readOnly": true, - "description": "Whether the Test Result is compliant or not within a given Report." - }, - "score": { - "type": "number", - "examples": [ - 99.99 - ], - "readOnly": true, - "description": "Compliance Score of the System within a given Report." - }, - "supported": { - "type": [ - "boolean", - "null" - ], - "examples": [ - false, - true - ], - "readOnly": true, - "description": "Whether the System is supported or not by a Profile within a given Policy." - }, - "failed_rule_count": { - "type": [ - "integer", - "null" - ], - "examples": [ - 3 - ], - "readOnly": true, - "description": "Number of failures, errors and unknown states for rules in the Test Result." - }, - "end_time": { - "type": "string", - "examples": [ - "2020-06-04T19:31:55Z" - ], - "readOnly": true, - "description": "The date when the System has been reported a Test Result for the last time." - } - } - }, - "value_definition": { - "type": "object", - "properties": { - "id": { - "$ref": "#/components/schemas/id" - }, - "type": { - "type": "string", - "enum": [ - "value_definition" - ] - }, - "ref_id": { - "type": "string", - "examples": [ - "xccdf_org.ssgproject.content_value_var_rekey_limit_size" - ], - "readOnly": true, - "description": "Identificator of the Value Definition" - }, - "title": { - "type": "string", - "examples": [ - "SSH RekeyLimit - size" - ], - "readOnly": true, - "description": "Short title of the Value Definition" - }, - "value_type": { - "type": "string", - "examples": [ - "string" - ], - "readOnly": true, - "description": "Type of the Value Definition" - }, - "description": { - "type": "string", - "examples": [ - "Specify the size component of the rekey limit." - ], - "readOnly": true, - "description": "Longer description of the Value Definition" - }, - "default_value": { - "type": "string", - "examples": [ - "512M" - ], - "readOnly": true, - "description": "Default value of the Value Definition" - } - } - } - } - }, - "tags": [ - { - "name": "Systems" - }, - { - "name": "Content" - }, - { - "name": "Policies" - }, - { - "name": "Reports" - } - ] -} \ No newline at end of file diff --git a/api/schema/composerCloudApi.v2.yaml b/api/schema/composerCloudApi.v2.yaml deleted file mode 100644 index 8a77c548..00000000 --- a/api/schema/composerCloudApi.v2.yaml +++ /dev/null @@ -1,2826 +0,0 @@ ---- -openapi: 3.0.1 -info: - version: '2' - title: OSBuild Composer cloud api - description: Service to build and install images. - license: - name: Apache 2.0 - url: https://www.apache.org/licenses/LICENSE-2.0.html - -servers: -- url: https://api.openshift.com/api/image-builder-composer/v2 - description: Main (production) server -- url: https://api.stage.openshift.com/api/image-builder-composer/v2 - description: Staging server -- url: /api/image-builder-composer/v2 - description: current domain - -paths: - /openapi: - get: - operationId: getOpenapi - summary: Get the openapi spec in json format - security: - - Bearer: [] - responses: - '200': - description: openapi spec in json format - content: - application/json: - schema: - type: object - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /composes/: - get: - operationId: getComposeList - summary: The list of composes - security: - - Bearer: [] - description: |- - Get the list of composes. They may be completed, uploaded, - locally saved, or failed. - responses: - '200': - description: list of composes - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeList' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /composes/{id}: - get: - operationId: getComposeStatus - summary: The status of a compose - security: - - Bearer: [] - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: ID of compose status to get - description: |- - Get the status of a running or completed compose. - This includes whether or not the compose succeeded. - responses: - '200': - description: compose status - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeStatus' - '400': - description: Invalid compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - delete: - operationId: deleteCompose - summary: Delete a compose - security: - - Bearer: [] - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: ID of compose to delete - description: |- - Delete a compose and all of its independent jobs. - responses: - '200': - description: compose delete status - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeDeleteStatus' - '400': - description: Invalid compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - - /composes/{id}/metadata: - get: - operationId: getComposeMetadata - summary: Get the metadata for a compose. - security: - - Bearer: [] - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: 123e4567-e89b-12d3-a456-426655440000 - required: true - description: ID of compose status to get - description: |- - Get the metadata of a finished compose. - The exact information returned depends on the requested image type. - responses: - '200': - description: The metadata for the given compose. - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeMetadata' - '400': - description: Invalid compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '/composes/{id}/logs': - get: - operationId: getComposeLogs - summary: Get logs for a compose. - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: 123e4567-e89b-12d3-a456-426655440000 - required: true - description: ID of compose status to get - description: 'Get the status of a running or finished compose. This includes whether or not it succeeded, and also meta information about the result.' - responses: - '200': - description: The logs for the given compose, in no particular format (though valid JSON). - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeLogs' - '400': - description: Invalid compose id - content: - text/plain: - schema: - type: string - '404': - description: Unknown compose id - content: - text/plain: - schema: - type: string - '/composes/{id}/manifests': - get: - operationId: getComposeManifests - summary: Get the manifests for a compose. - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: 123e4567-e89b-12d3-a456-426655440000 - required: true - description: ID of compose status to get - description: 'Get the manifests of a running or finished compose. Returns one manifest for each image in the request. Each manifest conforms to the format defined at https://www.osbuild.org/man/osbuild-manifest.5' - responses: - '200': - description: The manifest for the given compose. - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeManifests' - '400': - description: Invalid compose id - content: - text/plain: - schema: - type: string - '404': - description: Unknown compose id - content: - text/plain: - schema: - type: string - - '/composes/{id}/sboms': - get: - operationId: getComposeSBOMs - summary: Get the SBOMs for a compose. - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: 123e4567-e89b-12d3-a456-426655440000 - required: true - description: ID of compose for which to get SBOMs - description: |- - Returns a set of SBOM documents for each image in the request. - SBOM documents are in the SPDX format. - responses: - '200': - description: The SBOMs for the given compose. - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeSBOMs' - '400': - description: Invalid compose id - content: - text/plain: - schema: - type: string - '404': - description: Unknown compose id - content: - text/plain: - schema: - type: string - - /composes/{id}/download: - get: - operationId: getComposeDownload - summary: Download the artifact for a compose. - security: - - Bearer: [] - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: 123e4567-e89b-12d3-a456-426655440000 - required: true - description: ID of compose to download - description: |- - Download the artifact of a finished compose. - responses: - '200': - description: The metadata for the given compose. - content: - application/octet-stream: - schema: - type: string - format: binary - '400': - description: Invalid compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /composes/{id}/clone: - post: - operationId: postCloneCompose - summary: Clone an existing compose - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: 123e4567-e89b-12d3-a456-426655440000 - required: true - description: ID of the compose - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/CloneComposeBody' - responses: - '201': - description: The new image is being created - content: - application/json: - schema: - $ref: '#/components/schemas/CloneComposeResponse' - '400': - description: Invalid compose id - content: - text/plain: - schema: - type: string - '404': - description: Unknown compose id - content: - text/plain: - schema: - type: string - - /clones/{id}: - get: - operationId: getCloneStatus - summary: The status of a cloned compose - security: - - Bearer: [] - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: ID of image status to get - description: |- - Get the status of a running or completed image from a compose. - This includes whether or not the image creation succeeded. - responses: - '200': - description: image status - content: - application/json: - schema: - $ref: '#/components/schemas/CloneStatus' - '400': - description: Invalid compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /compose: - post: - operationId: postCompose - summary: Create compose - description: Create a new compose, potentially consisting of several images and upload each to their destinations. - security: - - Bearer: [] - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeRequest' - responses: - '201': - description: Compose has started - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeId' - '400': - description: Invalid compose request - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown compose id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /depsolve/blueprint: - post: - operationId: postDepsolveBlueprint - summary: Depsolve one or more blueprints - security: - - Bearer: [] - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/DepsolveRequest' - responses: - '200': - description: Depsolved package list - content: - application/json: - schema: - $ref: '#/components/schemas/DepsolveResponse' - '400': - description: Invalid depsolve request - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /search/packages: - post: - operationId: postSearchPackages - summary: Search for detailed information on a list of package names - security: - - Bearer: [] - requestBody: - required: true - content: - application/json: - schema: - $ref: '#/components/schemas/SearchPackagesRequest' - responses: - '200': - description: Search response with package details - content: - application/json: - schema: - $ref: '#/components/schemas/SearchPackagesResponse' - '400': - description: Invalid search request - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /distributions: - get: - operationId: getDistributionList - summary: |- - Get all of the supported distribution repository details - security: - - Bearer: [] - responses: - '200': - description: Distribution repositories - content: - application/json: - schema: - $ref: '#/components/schemas/DistributionList' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /errors/{id}: - get: - operationId: getError - summary: Get error description - description: Get an instance of the error specified by id - security: - - Bearer: [] - parameters: - - in: path - name: id - schema: - type: string - example: '13' - required: true - description: ID of the error - responses: - '200': - description: Error description - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown error id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - - /errors: - get: - operationId: getErrorList - summary: Get a list of all possible errors - security: - - Bearer: [] - parameters: - - $ref: '#/components/parameters/page' - - $ref: '#/components/parameters/size' - responses: - '200': - description: A list of errors - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorList' - '401': - description: Auth token is invalid - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '403': - description: Unauthorized to perform operation - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '404': - description: Unknown error id - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - '500': - description: Unexpected error occurred - content: - application/json: - schema: - $ref: '#/components/schemas/Error' - -components: - schemas: - ObjectReference: - type: object - required: - - id - - kind - - href - properties: - id: - type: string - kind: - type: string - href: - type: string - - List: - type: object - properties: - kind: - type: string - page: - type: integer - size: - type: integer - total: - type: integer - required: - - kind - - page - - size - - total - - items - - Error: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - required: - - code - - reason - - operation_id - properties: - code: - type: string - reason: - type: string - operation_id: - type: string - details: {} - - ErrorList: - allOf: - - $ref: '#/components/schemas/List' - - type: object - required: - - items - properties: - items: - type: array - items: - $ref: '#/components/schemas/Error' - - ComposeList: - allOf: - - $ref: '#/components/schemas/List' - - type: object - required: - - items - properties: - items: - type: array - items: - $ref: '#/components/schemas/ComposeStatus' - - DistributionList: - type: object - description: | - Map of distributions to their architecture. - additionalProperties: - type: object - description: | - Map of architectures to their repositories. - additionalProperties: - type: array - description: Repository used for this distro:arch:image-type - items: - $ref: '#/components/schemas/BlueprintRepository' - - ComposeStatus: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - required: - - status - - image_status - properties: - status: - $ref: '#/components/schemas/ComposeStatusValue' - image_status: - $ref: '#/components/schemas/ImageStatus' - image_statuses: - type: array - items: - $ref: '#/components/schemas/ImageStatus' - koji_status: - $ref: '#/components/schemas/KojiStatus' - ComposeStatusValue: - type: string - enum: - - success - - failure - - pending - example: success - - ComposeDeleteStatus: - $ref: '#/components/schemas/ObjectReference' - - ComposeLogs: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - required: - - image_builds - properties: - image_builds: - type: array - items: - type: object - x-go-type: interface{} - koji: - $ref: '#/components/schemas/KojiLogs' - KojiLogs: - type: object - required: - - init - - import - properties: - init: {} - import: {} - ComposeManifests: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - required: - - manifests - properties: - manifests: - type: array - items: - type: object - x-go-type: interface{} - ImageSBOM: - required: - - sbom - - sbom_type - - pipeline_name - - pipeline_purpose - properties: - sbom: - type: object - x-go-type: interface{} - description: |- - The SBOM document in the 'sbom_type' format. - sbom_type: - type: string - enum: ["spdx"] - description: |- - The type of the SBOM document. Currently only SPDX is supported. - pipeline_name: - type: string - description: |- - The name of the osbuild pipeline which has the packages described - in the SBOM installed. - pipeline_purpose: - type: string - enum: ["buildroot", "image"] - description: |- - The purpose of the pipeline. The `buildroot` pipeline was used for - the build environment dueing the image build. The `image` pipeline - represents the actual content of the image. Due to the nature of - some image types, there may be multiple pipelines of the same - purpose. - ComposeSBOMs: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - required: - - items - properties: - items: - type: array - description: |- - The SBOM documents for each image built in the compose. - items: - type: array - description: |- - The SBOM documents for the given image. Each image usually has - at least two SBOMs, one for the build environment and one for the - actual content of the image. - items: - $ref: '#/components/schemas/ImageSBOM' - ImageStatus: - required: - - status - properties: - status: - $ref: '#/components/schemas/ImageStatusValue' - upload_status: - $ref: '#/components/schemas/UploadStatus' - upload_statuses: - type: array - items: - $ref: '#/components/schemas/UploadStatus' - error: - $ref: '#/components/schemas/ComposeStatusError' - ComposeStatusError: - required: - - id - - reason - properties: - id: - type: integer - reason: - type: string - details: {} - ImageStatusValue: - type: string - enum: ['success', 'failure', 'pending', 'building', 'uploading', 'registering'] - UploadStatus: - required: - - status - - type - - options - properties: - status: - $ref: '#/components/schemas/UploadStatusValue' - type: - $ref: '#/components/schemas/UploadTypes' - options: - oneOf: - - $ref: '#/components/schemas/AWSEC2UploadStatus' - - $ref: '#/components/schemas/AWSS3UploadStatus' - - $ref: '#/components/schemas/GCPUploadStatus' - - $ref: '#/components/schemas/AzureUploadStatus' - - $ref: '#/components/schemas/ContainerUploadStatus' - - $ref: '#/components/schemas/OCIUploadStatus' - - $ref: '#/components/schemas/PulpOSTreeUploadStatus' - - $ref: '#/components/schemas/LocalUploadStatus' - UploadStatusValue: - type: string - enum: ['success', 'failure', 'pending', 'running'] - UploadTypes: - type: string - enum: - - aws - - aws.s3 - - gcp - - azure - - container - - oci.objectstorage - - pulp.ostree - - local - AWSEC2UploadStatus: - type: object - required: - - ami - - region - properties: - ami: - type: string - example: 'ami-0c830793775595d4b' - region: - type: string - example: 'eu-west-1' - AWSS3UploadStatus: - type: object - required: - - url - properties: - url: - type: string - GCPUploadStatus: - type: object - required: - - project_id - - image_name - properties: - project_id: - type: string - example: 'ascendant-braid-303513' - image_name: - type: string - example: 'my-image' - AzureUploadStatus: - type: object - required: - - image_name - properties: - image_name: - type: string - example: 'my-image' - KojiStatus: - type: object - properties: - build_id: - type: integer - example: 42 - ContainerUploadStatus: - type: object - additionalProperties: false - required: - - url - - digest - properties: - url: - type: string - example: 'quay.io/myaccount/osbuild:latest' - description: | - FQDN of the uploaded image - digest: - type: string - description: | - Digest of the manifest of the uploaded container on the registry - OCIUploadStatus: - type: object - required: - - url - properties: - url: - type: string - PulpOSTreeUploadStatus: - type: object - required: - - repo_url - properties: - repo_url: - type: string - LocalUploadStatus: - type: object - required: - - artifact_path - properties: - artifact_path: - type: string - ComposeMetadata: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - properties: - packages: - type: array - items: - $ref: '#/components/schemas/PackageMetadata' - description: 'Package list including NEVRA' - ostree_commit: - type: string - description: 'ID (hash) of the built commit' - request: - $ref: '#/components/schemas/ComposeRequest' - description: 'Original request to create this compose' - PackageMetadataCommon: - required: - - type - - name - - version - - release - - arch - - sigmd5 - properties: - type: - type: string - name: - type: string - version: - type: string - release: - type: string - epoch: - type: string - arch: - type: string - signature: - type: string - checksum: - type: string - description: 'Optional package checksum using ALGO:HASH form' - example: 'sha256:525788de3dd44497c27d4172568366b20380a6b6707f0a1970473e4d97046a4f' - PackageMetadata: - allOf: - - $ref: '#/components/schemas/PackageMetadataCommon' - - type: object - required: - - sigmd5 - properties: - sigmd5: - type: string - - ComposeRequest: - additionalProperties: false - required: - - distribution - not: {required: ['customizations', 'blueprint']} - properties: - distribution: - type: string - example: 'rhel-8' - image_request: - $ref: '#/components/schemas/ImageRequest' - image_requests: - type: array - items: - $ref: '#/components/schemas/ImageRequest' - customizations: - $ref: '#/components/schemas/Customizations' - koji: - $ref: '#/components/schemas/Koji' - blueprint: - $ref: '#/components/schemas/Blueprint' - ImageRequest: - additionalProperties: false - required: - - architecture - - image_type - - repositories - properties: - architecture: - type: string - example: 'x86_64' - image_type: - $ref: '#/components/schemas/ImageTypes' - repositories: - type: array - items: - $ref: '#/components/schemas/Repository' - ostree: - $ref: '#/components/schemas/OSTree' - upload_targets: - type: array - description: | - The type and options for multiple upload targets. Each item defines - a separate upload destination with its own options. Multiple - different targets as well as multiple targets of the same kind are - supported. - items: - $ref: '#/components/schemas/UploadTarget' - upload_options: - description: | - Top level upload options for a single upload target. If this is - defined, it is used with the default target type for the image type - and is combined with the targets defined in upload_targets. - $ref: '#/components/schemas/UploadOptions' - size: - x-go-type: uint64 - default: 0 - example: 4294967296 - description: | - Size of image, in bytes. When set to 0 the image size is a minimum - defined by the image type. - ImageTypes: - type: string - enum: - - aws - - aws-ha-rhui - - aws-rhui - - aws-sap-rhui - - azure - - azure-cvm - - azure-eap7-rhui - - azure-rhui - - azure-sap-rhui - - edge-commit - - edge-container - - edge-installer - - gcp - - gcp-rhui - - guest-image - - image-installer - - iot-bootable-container - - iot-commit - - iot-container - - iot-installer - - iot-raw-image - - iot-simplified-installer - - live-installer - - minimal-raw - - oci - - vsphere - - vsphere-ova - - wsl - Repository: - type: object - description: | - Repository configuration. - At least one of the 'baseurl', 'mirrorlist', 'metalink' properties must - be specified. If more of them are specified, the order of precedence is - the same as listed above. - properties: - rhsm: - type: boolean - default: false - description: 'Determines whether a valid subscription is required to access this repository.' - baseurl: - type: string - format: uri - example: 'https://cdn.redhat.com/content/dist/rhel8/8/x86_64/baseos/os/' - mirrorlist: - type: string - format: uri - example: 'http://mirrorlist.centos.org/?release=8-stream&arch=aarch64&repo=BaseOS' - metalink: - type: string - format: uri - example: 'https://mirrors.fedoraproject.org/metalink?repo=fedora-32&arch=x86_64' - gpgkey: - type: string - example: "-----BEGIN PGP PUBLIC KEY BLOCK-----\n\nmQINBGAcScoBEADLf8YHkezJ6adlMYw7aGGIlJalt8Jj2x/B2K+hIfIuxGtpVj7e\nLRgDU76jaT5pVD5mFMJ3pkeneR/cTmqqQkNyQshX2oQXwEzUSb1CNMCfCGgkX8Q2\nzZkrIcCrF0Q2wrKblaudhU+iVanADsm18YEqsb5AU37dtUrM3QYdWg9R+XiPfV8R\nKBjT03vVBOdMSsY39LaCn6Ip1Ovp8IEo/IeEVY1qmCOPAaK0bJH3ufg4Cueks+TS\nwQWTeCLxuZL6OMXoOPKwvMQfxbg1XD8vuZ0Ktj/cNH2xau0xmsAu9HJpekvOPRxl\nyqtjyZfroVieFypwZgvQwtnnM8/gSEu/JVTrY052mEUT7Ccb74kcHFTFfMklnkG/\n0fU4ARa504H3xj0ktbe3vKcPXoPOuKBVsHSv00UGYAyPeuy+87cU/YEhM7k3SVKj\n6eIZgyiMO0wl1YGDRKculwks9A+ulkg1oTb4s3zmZvP07GoTxW42jaK5WS+NhZee\n860XoVhbc1KpS+jfZojsrEtZ8PbUZ+YvF8RprdWArjHbJk2JpRKAxThxsQAsBhG1\n0Lux2WaMB0g2I5PcMdJ/cqjo08ccrjBXuixWri5iu9MXp8qT/fSzNmsdIgn8/qZK\ni8Qulfu77uqhW/wt2btnitgRsqjhxMujYU4Zb4hktF8hKU/XX742qhL5KwARAQAB\ntDFGZWRvcmEgKDM1KSA8ZmVkb3JhLTM1LXByaW1hcnlAZmVkb3JhcHJvamVjdC5v\ncmc+iQJOBBMBCAA4FiEEeH6mrhFH7uVsQLMM20Y5cZhnxY8FAmAcScoCGw8FCwkI\nBwIGFQoJCAsCBBYCAwECHgECF4AACgkQ20Y5cZhnxY+NYA/7BYpglySAZYHhjyKh\n/+f6zPfVvbH20Eq3kI7OFBN0nLX+BU1muvS+qTuS3WLrB3m3GultpKREJKLtm5ED\n1rGzXAoT1yp9YI8LADdMCCOyjAjsoWU87YUuC+/bnjrTeR2LROCfyPC76W985iOV\nm5S+bsQDw7C2LrldAM4MDuoyZ1SitGaZ4KQLVt+TEa14isYSGCjzo7PY8V3JOk50\ngqWg82N/bm2EzS7T83WEDb1lvj4IlvxgIqKeg11zXYxmrYSZJJCfvzf+lNS6uxgH\njx/J0ylZ2LibGr6GAAyO9UWrAZSwSM0EcjT8wECnxkSDuyqmWwVvNBXuEIV8Oe3Y\nMiU1fJN8sd7DpsFx5M+XdnMnQS+HrjTPKD3mWrlAdnEThdYV8jZkpWhDys3/99eO\nhk0rLny0jNwkauf/iU8Oc6XvMkjLRMJg5U9VKyJuWWtzwXnjMN5WRFBqK4sZomMM\nftbTH1+5ybRW/A3vBbaxRW2t7UzNjczekSZEiaLN9L/HcJCIR1QF8682DdAlEF9d\nk2gQiYSQAaaJ0JJAzHvRkRJLLgK2YQYiHNVy2t3JyFfsram5wSCWOfhPeIyLBTZJ\nvrpNlPbefsT957Tf2BNIugzZrC5VxDSKkZgRh1VGvSIQnCyzkQy6EU2qPpiW59G/\nhPIXZrKocK3KLS9/izJQTRltjMA=\n=PfT7\n-----END PGP PUBLIC KEY BLOCK-----\n" - description: 'GPG key used to sign packages in this repository.' - check_gpg: - type: boolean - check_repo_gpg: - type: boolean - default: false - description: | - Enables gpg verification of the repository metadata - ignore_ssl: - type: boolean - module_hotfixes: - type: boolean - default: false - description: | - Disables modularity filtering for this repository. - package_sets: - type: array - example: ["build", "os"] - items: - type: string - description: | - Naming package sets for a repository assigns it to a specific part - (pipeline) of the build process. - CustomRepository: - type: object - required: - - id - properties: - id: - type: string - name: - type: string - filename: - type: string - baseurl: - type: array - items: - type: string - format: uri - example: 'https://cdn.redhat.com/content/dist/rhel8/8/x86_64/baseos/os/' - mirrorlist: - type: string - format: uri - example: 'http://mirrorlist.centos.org/?release=8-stream&arch=aarch64&repo=BaseOS' - metalink: - type: string - format: uri - example: 'https://mirrors.fedoraproject.org/metalink?repo=fedora-32&arch=x86_64' - enabled: - type: boolean - gpgkey: - type: array - items: - type: string - check_gpg: - type: boolean - check_repo_gpg: - type: boolean - ssl_verify: - type: boolean - priority: - type: integer - module_hotfixes: - type: boolean - BlueprintRepository: - type: object - required: - - id - properties: - id: - type: string - baseurls: - type: array - items: - type: string - format: uri - example: 'https://cdn.redhat.com/content/dist/rhel8/8/x86_64/baseos/os/' - gpgkeys: - type: array - items: - type: string - metalink: - type: string - format: uri - example: 'https://mirrors.fedoraproject.org/metalink?repo=fedora-32&arch=x86_64' - mirrorlist: - type: string - format: uri - example: 'http://mirrorlist.centos.org/?release=8-stream&arch=aarch64&repo=BaseOS' - name: - type: string - priority: - type: integer - enabled: - type: boolean - gpgcheck: - type: boolean - repo_gpgcheck: - type: boolean - sslverify: - type: boolean - filename: - type: string - module_hotfixes: - type: boolean - description: | - Disables modularity filtering for this repository. - OpenSCAP: - type: object - required: - - profile_id - properties: - policy_id: - type: string - format: uuid - description: | - Puts a specified policy ID in the RHSM facts, so that any instances registered to - insights will be automatically connected to the compliance policy in the console. - profile_id: - type: string - tailoring: - $ref: '#/components/schemas/OpenSCAPTailoring' - json_tailoring: - $ref: '#/components/schemas/OpenSCAPJSONTailoring' - BlueprintOpenSCAP: - type: object - required: - - profile_id - properties: - policy_id: - type: string - format: uuid - description: | - Puts a specified policy ID in the RHSM facts, so that any instances registered to - insights will be automatically connected to the compliance policy in the console. - profile_id: - type: string - datastream: - type: string - tailoring: - $ref: '#/components/schemas/OpenSCAPTailoring' - json_tailoring: - $ref: '#/components/schemas/OpenSCAPJSONTailoring' - OpenSCAPTailoring: - type: object - properties: - selected: - type: array - items: - type: string - unselected: - type: array - items: - type: string - OpenSCAPJSONTailoring: - type: object - required: - - profile_id - - filepath - properties: - profile_id: - type: string - filepath: - type: string - Installer: - type: object - properties: - unattended: - type: boolean - sudo-nopasswd: - type: array - items: - type: string - ImportKeys: - type: object - properties: - files: - type: array - items: - type: string - RPMCustomization: - type: object - properties: - import_keys: - $ref: '#/components/schemas/ImportKeys' - DNFPluginConfig: - type: object - properties: - enabled: - type: boolean - SubManDNFPluginsConfig: - type: object - properties: - product_id: - $ref: '#/components/schemas/DNFPluginConfig' - subscription_manager: - $ref: '#/components/schemas/DNFPluginConfig' - SubManRHSMConfig: - type: object - properties: - manage_repos: - type: boolean - auto_enable_yum_plugins: - type: boolean - SubManRHSMCertdConfig: - type: object - properties: - auto_registration: - type: boolean - SubManConfig: - type: object - properties: - rhsm: - $ref: '#/components/schemas/SubManRHSMConfig' - rhsmcertd: - $ref: '#/components/schemas/SubManRHSMCertdConfig' - RHSMConfig: - type: object - properties: - dnf_plugins: - $ref: '#/components/schemas/SubManDNFPluginsConfig' - subscription_manager: - $ref: '#/components/schemas/SubManConfig' - RHSMCustomization: - type: object - properties: - config: - $ref: '#/components/schemas/RHSMConfig' - CACertsCustomization: - type: object - additionalProperties: false - required: - - pem_certs - properties: - pem_certs: - type: array - example: ['---BEGIN CERTIFICATE---\nMIIC0DCCAbigAwIBAgIUI...\n---END CERTIFICATE---'] - items: - type: string - UploadTarget: - type: object - required: - - type - - upload_options - properties: - type: - $ref: '#/components/schemas/UploadTypes' - description: | - The name of the upload target that matches the upload_options. - upload_options: - $ref: '#/components/schemas/UploadOptions' - UploadOptions: - anyOf: - - $ref: '#/components/schemas/AWSEC2UploadOptions' - - $ref: '#/components/schemas/AWSS3UploadOptions' - - $ref: '#/components/schemas/GCPUploadOptions' - - $ref: '#/components/schemas/AzureUploadOptions' - - $ref: '#/components/schemas/ContainerUploadOptions' - - $ref: '#/components/schemas/LocalUploadOptions' - - $ref: '#/components/schemas/OCIUploadOptions' - - $ref: '#/components/schemas/PulpOSTreeUploadOptions' - description: | - Options for a given upload destination. - This should really be oneOf but AWSS3UploadOptions is a subset of - AWSEC2UploadOptions. This means that all AWSEC2UploadOptions objects - are also valid AWSS3UploadOptionas objects which violates the oneOf - rules. Therefore, we have to use anyOf here but be aware that it isn't - possible to mix and match more schemas together. - LocalUploadOptions: - type: object - additionalProperties: false - properties: {} - AWSEC2UploadOptions: - type: object - additionalProperties: false - required: - - region - - share_with_accounts - properties: - region: - type: string - example: 'eu-west-1' - snapshot_name: - type: string - example: 'my-snapshot' - share_with_accounts: - type: array - example: ['123456789012'] - items: - type: string - AWSS3UploadOptions: - type: object - additionalProperties: false - required: - - region - properties: - region: - type: string - example: 'eu-west-1' - public: - type: boolean - default: false - description: | - If set to false (the default value), a long, obfuscated URL - is returned. Its expiration might be sooner than for other upload - targets. - - If set to true, a shorter URL is returned and - its expiration is the same as for the other upload targets. - OCIUploadOptions: - type: object - additionalProperties: false - GCPUploadOptions: - type: object - additionalProperties: false - required: - - region - properties: - region: - type: string - example: 'eu' - description: | - The GCP region where the OS image will be imported to and shared from. - The value must be a valid GCP location. See https://cloud.google.com/storage/docs/locations. - If not specified, the multi-region location closest to the source - (source Storage Bucket location) is chosen automatically. - bucket: - type: string - example: 'my-example-bucket' - description: 'Name of an existing STANDARD Storage class Bucket.' -# don't expose the os type for now -# os: -# type: string -# example: 'rhel-8-byol' -# description: 'OS of the disk image being imported needed for installation of GCP guest tools.' - image_name: - type: string - example: 'my-image' - description: | - The name to use for the imported and shared Compute Engine image. - The image name must be unique within the GCP project, which is used - for the OS image upload and import. If not specified a random - 'composer-api-<uuid>' string is used as the image name. - share_with_accounts: - type: array - example: [ - 'user:alice@example.com', - 'serviceAccount:my-other-app@appspot.gserviceaccount.com', - 'group:admins@example.com', - 'domain:example.com' - ] - description: | - List of valid Google accounts to share the imported Compute Engine image with. - Each string must contain a specifier of the account type. Valid formats are: - - 'user:{emailid}': An email address that represents a specific - Google account. For example, 'alice@example.com'. - - 'serviceAccount:{emailid}': An email address that represents a - service account. For example, 'my-other-app@appspot.gserviceaccount.com'. - - 'group:{emailid}': An email address that represents a Google group. - For example, 'admins@example.com'. - - 'domain:{domain}': The G Suite domain (primary) that represents all - the users of that domain. For example, 'google.com' or 'example.com'. - If not specified, the imported Compute Engine image is not shared with any - account. - items: - type: string - AzureUploadOptions: - type: object - additionalProperties: false - required: - - tenant_id - - subscription_id - - resource_group - properties: - tenant_id: - type: string - example: '5c7ef5b6-1c3f-4da0-a622-0b060239d7d7' - description: | - ID of the tenant where the image should be uploaded. - How to find it in the Azure Portal: - https://docs.microsoft.com/en-us/azure/active-directory/fundamentals/active-directory-how-to-find-tenant - subscription_id: - type: string - example: '4e5d8b2c-ab24-4413-90c5-612306e809e2' - description: | - ID of subscription where the image should be uploaded. - resource_group: - type: string - example: 'ToucanResourceGroup' - description: | - Name of the resource group where the image should be uploaded. - location: - type: string - example: 'westeurope' - description: | - Location of the provided resource_group, where the image should be uploaded and registered. - How to list all locations: - https://docs.microsoft.com/en-us/cli/azure/account?view=azure-cli-latest#az_account_list_locations' - If the location is not specified, it is deducted from the provided resource_group. - image_name: - type: string - example: 'my-image' - description: | - Name of the uploaded image. It must be unique in the given resource group. - If name is omitted from the request, a random one based on a UUID is - generated. - hyper_v_generation: - type: string - enum: - - V1 - - V2 - default: V1 - description: | - Choose the VM Image HyperV generation, different features on Azure are available - depending on the HyperV generation. - ContainerUploadOptions: - type: object - additionalProperties: false - properties: - name: - type: string - example: 'osbuild' - description: | - Name for the created container image - tag: - type: string - example: 'latest' - description: | - Tag for the created container image - PulpOSTreeUploadOptions: - type: object - additionalProperties: false - required: - - basepath - properties: - basepath: - type: string - description: 'Basepath for distributing the repository' - repository: - type: string - description: 'Repository to import the ostree commit to' - server_address: - type: string - format: uri - Blueprint: - type: object - required: - - name - additionalProperties: false - properties: - name: - type: string - description: - type: string - version: - type: string - example: '7.7.70' - description: A semver version number - distro: - type: string - example: 'fedora-39' - description: | - The distribution to use for the compose. If left empty the host - distro will be used. - packages: - type: array - description: Packages to be installed - items: - $ref: '#/components/schemas/Package' - modules: - type: array - description: | - An alias for packages, retained for backwards compatability - items: - $ref: '#/components/schemas/Package' - enabled_modules: - type: array - items: - $ref: '#/components/schemas/Module' - groups: - type: array - description: Package groups to be installed - items: - $ref: '#/components/schemas/PackageGroup' - containers: - type: array - description: Container images to embed into the final artfact - items: - $ref: '#/components/schemas/Container' - customizations: - $ref: '#/components/schemas/BlueprintCustomizations' - BlueprintCustomizations: - type: object - additionalProperties: false - properties: - hostname: - type: string - description: Configures the hostname - kernel: - $ref: '#/components/schemas/Kernel' - sshkey: - type: array - description: List of ssh keys - items: - $ref: '#/components/schemas/SSHKey' - user: - type: array - description: List of users to create - items: - $ref: '#/components/schemas/BlueprintUser' - group: - type: array - description: List of groups to create - items: - $ref: '#/components/schemas/Group' - timezone: - $ref: '#/components/schemas/Timezone' - locale: - $ref: '#/components/schemas/Locale' - firewall: - $ref: '#/components/schemas/BlueprintFirewall' - services: - $ref: '#/components/schemas/Services' - filesystem: - type: array - description: List of filesystem mountpoints to create - items: - $ref: '#/components/schemas/BlueprintFilesystem' - disk: - $ref: '#/components/schemas/Disk' - installation_device: - type: string - description: | - Name of the installation device, currently only useful for the edge-simplified-installer type - example: /dev/sda - partitioning_mode: - type: string - enum: - - raw - - lvm - - auto-lvm - default: auto-lvm - description: | - Select how the disk image will be partitioned. 'auto-lvm' will use raw unless - there are one or more mountpoints in which case it will use LVM. 'lvm' always - uses LVM, even when there are no extra mountpoints. 'raw' uses raw partitions - even when there are one or more mountpoints. - fdo: - $ref: '#/components/schemas/FDO' - openscap: - $ref: '#/components/schemas/BlueprintOpenSCAP' - ignition: - $ref: '#/components/schemas/Ignition' - directories: - type: array - description: Directories to create in the final artifact - items: - $ref: '#/components/schemas/Directory' - files: - type: array - description: Files to create in the final artifact - items: - $ref: '#/components/schemas/BlueprintFile' - repositories: - type: array - description: | - Repositories to write to /etc/yum.repos.d/ in the final image. Note - that these are not used at build time. - items: - $ref: '#/components/schemas/BlueprintRepository' - fips: - type: boolean - description: Enable FIPS mode - installer: - $ref: '#/components/schemas/Installer' - rpm: - $ref: '#/components/schemas/RPMCustomization' - rhsm: - $ref: '#/components/schemas/RHSMCustomization' - cacerts: - $ref: '#/components/schemas/CACertsCustomization' - SSHKey: - type: object - additionalProperties: false - required: - - user - - key - properties: - user: - type: string - description: User to configure the ssh key for - example: admin - key: - type: string - description: Adds the key to the user's authorized_keys file - example: | - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIASWitkOH4U874EdsBUnytb3bwvRggHlQlbYXl7n10v9 - Package: - type: object - required: - - name - additionalProperties: false - properties: - name: - type: string - example: 'tmux' - description: | - Name of the package to install. File globbing is supported, - eg. 'openssh-*' - version: - type: string - example: '3.3a' - description: | - Optional version of the package to install. If left blank the - latest available version will be used. Wildcards are supported - eg. '4.11.*' - PackageGroup: - type: object - required: - - name - additionalProperties: false - properties: - name: - type: string - example: 'anaconda-tools' - description: Package group name - Module: - type: object - required: - - name - - stream - additionalProperties: false - properties: - name: - type: string - example: 'nodejs' - description: | - Name of the module to enable. - stream: - type: string - example: '22' - description: | - Stream to enable. - Customizations: - type: object - additionalProperties: false - properties: - containers: - type: array - items: - $ref: '#/components/schemas/Container' - description: Container images to embed into the final artfact - directories: - type: array - items: - $ref: '#/components/schemas/Directory' - description: Directories to create in the final artifact - files: - type: array - items: - $ref: '#/components/schemas/File' - description: Files to create in the final artifact - subscription: - $ref: '#/components/schemas/Subscription' - packages: - type: array - example: ['postgres'] - items: - type: string - enabled_modules: - type: array - items: - $ref: '#/components/schemas/Module' - users: - type: array - items: - $ref: '#/components/schemas/User' - payload_repositories: - type: array - items: - $ref: '#/components/schemas/Repository' - description: | - Extra repositories for packages specified in customizations. These - repositories will only be used to depsolve and retrieve packages - for the OS itself (they will not be available for the build root or - any other part of the build process). The package_sets field for these - repositories is ignored. - custom_repositories: - type: array - items: - $ref: '#/components/schemas/CustomRepository' - description: | - Extra repositories for packages specified in customizations. These - repositories will be used to depsolve and retrieve packages. Additionally, - these packages will be saved and imported to the `/etc/yum.repos.d/` directory - on the image - openscap: - $ref: '#/components/schemas/OpenSCAP' - filesystem: - type: array - items: - $ref: '#/components/schemas/Filesystem' - services: - $ref: '#/components/schemas/Services' - hostname: - type: string - description: Configures the hostname - example: myhostname - kernel: - $ref: '#/components/schemas/Kernel' - groups: - type: array - description: List of groups to create - items: - $ref: '#/components/schemas/Group' - timezone: - $ref: '#/components/schemas/Timezone' - locale: - $ref: '#/components/schemas/Locale' - firewall: - $ref: '#/components/schemas/FirewallCustomization' - installation_device: - type: string - description: | - Name of the installation device, currently only useful for the edge-simplified-installer type - example: /dev/sda - fdo: - $ref: '#/components/schemas/FDO' - ignition: - $ref: '#/components/schemas/Ignition' - partitioning_mode: - type: string - enum: - - raw - - lvm - - auto-lvm - default: auto-lvm - description: | - Select how the disk image will be partitioned. 'auto-lvm' will use raw unless - there are one or more mountpoints in which case it will use LVM. 'lvm' always - uses LVM, even when there are no extra mountpoints. 'raw' uses raw partitions - even when there are one or more mountpoints. - fips: - $ref: '#/components/schemas/FIPS' - installer: - $ref: '#/components/schemas/Installer' - rpm: - $ref: '#/components/schemas/RPMCustomization' - rhsm: - $ref: '#/components/schemas/RHSMCustomization' - cacerts: - $ref: '#/components/schemas/CACertsCustomization' - disk: - $ref: '#/components/schemas/Disk' - Container: - type: object - required: - - source - properties: - source: - type: string - description: Reference to the container to embed - example: 'registry.example.com/image:tag' - name: - type: string - description: Name to use for the container from the image - tls_verify: - type: boolean - description: Control TLS verifification - example: true - FirewallCustomization: - type: object - description: Firewalld configuration - additionalProperties: false - properties: - ports: - type: array - description: List of ports (or port ranges) and protocols to open - example: ["22:tcp", "80:tcp", "imap:tcp"] - items: - type: string - services: - $ref: '#/components/schemas/FirewallServices' - BlueprintFirewall: - type: object - description: Firewalld configuration - additionalProperties: false - properties: - ports: - type: array - description: List of ports (or port ranges) and protocols to open - example: ["22:tcp", "80:tcp", "imap:tcp"] - items: - type: string - services: - $ref: '#/components/schemas/FirewallServices' - zones: - type: array - items: - $ref: '#/components/schemas/FirewallZones' - FirewallServices: - type: object - description: Firewalld services to enable or disable - additionalProperties: false - properties: - enabled: - type: array - description: List of services to enable - example: ["ftp", "ntp"] - items: - type: string - disabled: - type: array - description: List of services to disable - example: ["telnet"] - items: - type: string - FirewallZones: - type: object - description: | - Bind a list of network sources to a zone to restrict traffic from - those sources based on the settings of the zone. - additionalProperties: false - properties: - name: - type: string - description: | - name of the zone, if left empty the sources will apply to - the default zone. - sources: - type: array - description: List of sources for the zone - items: - type: string - description: <source>[/<mask>]|<MAC>|ipset:<ipset> - Directory: - type: object - description: | - A custom directory to create in the final artifact. - required: - - path - properties: - path: - type: string - description: Path to the directory - example: '/etc/mydir' - mode: - type: string - description: Permissions string for the directory in octal format - example: "0755" - user: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Owner of the directory as a user name or a uid - example: 'root' - group: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Group of the directory as a group name or a gid - example: 'root' - ensure_parents: - type: boolean - description: Ensure that the parent directories exist - default: false - File: - type: object - description: | - A custom file to create in the final artifact. - required: - - path - properties: - path: - type: string - description: Path to the file - example: '/etc/myfile' - mode: - type: string - description: Permissions string for the file in octal format - example: "0644" - user: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Owner of the file as a uid or a user name - example: 'root' - group: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Group of the file as a gid or a group name - example: 'root' - data: - type: string - description: Contents of the file as plain text - ensure_parents: - type: boolean - description: Ensure that the parent directories exist - example: true - default: false - BlueprintFile: - type: object - description: | - A custom file to create in the final artifact. - required: - - path - properties: - path: - type: string - description: Path to the file - example: '/etc/myfile' - mode: - type: string - description: Permissions string for the file in octal format - example: "0644" - user: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Owner of the file as a uid or a user name - example: 'root' - group: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Group of the file as a gid or a group name - example: 'root' - data: - type: string - description: Contents of the file as plain text - Filesystem: - type: object - required: - - mountpoint - - min_size - properties: - mountpoint: - type: string - example: '/var' - min_size: - x-go-type: uint64 - example: 2147483648 - description: 'size of the filesystem in bytes' - BlueprintFilesystem: - type: object - required: - - mountpoint - - minsize - properties: - mountpoint: - type: string - example: '/var' - minsize: - $ref: '#/components/schemas/minsize' - OSTree: - type: object - properties: - url: - type: string - contenturl: - type: string - description: | - A URL which, if set, is used for fetching content. Implies that `url` is set as well, - which will be used for metadata only. - ref: - type: string - example: 'rhel/8/x86_64/edge' - parent: - type: string - description: > - Can be either a commit (example: - 02604b2da6e954bd34b8b82a835e5a77d2b60ffa), or a branch-like - reference (example: rhel/8/x86_64/edge) - example: 'rhel/8/x86_64/edge' - rhsm: - type: boolean - default: false - description: | - Determines whether a valid subscription manager (candlepin) identity is required to - access this repository. Consumer certificates will be used as client certificates when - fetching metadata and content. - Subscription: - type: object - required: - - organization - - activation_key - - server_url - - base_url - - insights - properties: - organization: - type: string - example: '2040324' - activation_key: - type: string - format: password - example: 'my-secret-key' - server_url: - type: string - format: uri - example: 'subscription.rhsm.redhat.com' - base_url: - type: string - format: uri - example: 'http://cdn.redhat.com/' - insights: - type: boolean - example: true - rhc: - type: boolean - default: false - example: true - description: | - Optional flag to use rhc to register the system, which also always enables Insights. - insights_client_proxy: - type: string - format: uri - description: | - Optional value to set proxy option when registering the system to Insights - template_uuid: - type: string - description: | - Optional value to register with a template when registering the system with Insights. - template_name: - type: string - description: | - Optional value to register with a template when using rhc to register the system with Insights. - User: - type: object - additionalProperties: false - required: - - name - properties: - name: - type: string - example: "user1" - groups: - type: array - items: - type: string - example: "group1" - key: - type: string - example: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINrGKErMYi+MMUwuHaRAJmRLoIzRf2qD2dD5z0BTx/6x" - password: - type: string - format: password - description: | - If the password starts with $6$, $5$, or $2b$ it will be stored as - an encrypted password. Otherwise it will be treated as a plain text - password. - BlueprintUser: - type: object - additionalProperties: false - required: - - name - properties: - name: - type: string - example: "user1" - description: - type: string - password: - type: string - description: | - If the password starts with $6$, $5$, or $2b$ it will be stored as - an encrypted password. Otherwise it will be treated as a plain text - password. - key: - type: string - description: ssh public key - example: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINrGKErMYi+MMUwuHaRAJmRLoIzRf2qD2dD5z0BTx/6x" - home: - type: string - description: The user's home directory - shell: - type: string - description: Login shell to use - groups: - type: array - items: - type: string - example: "group1" - description: A list of additional groups to add the user to - uid: - type: integer - description: User id to use instead of the default - gid: - type: integer - description: Group id to use instead of the default - Kernel: - type: object - additionalProperties: false - properties: - name: - type: string - description: Name of the kernel to use - example: kernel-debug - append: - type: string - description: Appends arguments to the bootloader kernel command line - example: nosmt=force - Services: - type: object - additionalProperties: false - properties: - enabled: - description: List of services to enable by default - type: array - minItems: 1 - items: - type: string - example: "nftables" - disabled: - description: List of services to disable by default - type: array - minItems: 1 - items: - type: string - example: "firewalld" - masked: - description: List of services to mask by default - type: array - minItems: 1 - items: - type: string - example: "telnetd" - Timezone: - type: object - description: Timezone configuration - additionalProperties: false - properties: - timezone: - type: string - description: Name of the timezone, defaults to UTC - example: US/Eastern - ntpservers: - type: array - description: List of ntp servers - example: ["0.north-america.pool.ntp.org", "1.north-america.pool.ntp.org"] - items: - type: string - Locale: - type: object - description: Locale configuration - additionalProperties: false - properties: - languages: - type: array - description: | - List of locales to be installed, the first one becomes primary, subsequent ones are secondary - example: ["en_US.UTF-8"] - items: - type: string - keyboard: - type: string - description: Sets the keyboard layout - example: us - FDO: - type: object - additionalProperties: false - description: FIDO device onboard configuration - properties: - manufacturing_server_url: - type: string - diun_pub_key_insecure: - type: string - diun_pub_key_hash: - type: string - diun_pub_key_root_certs: - type: string - di_mfg_string_type_mac_iface: - type: string - FIPS: - type: object - additionalProperties: false - description: System FIPS mode setup - properties: - enabled: - type: boolean - description: Enables the system FIPS mode - default: false - Ignition: - type: object - additionalProperties: false - description: Ignition configuration - properties: - embedded: - $ref: '#/components/schemas/IgnitionEmbedded' - firstboot: - $ref: '#/components/schemas/IgnitionFirstboot' - IgnitionEmbedded: - type: object - additionalProperties: false - required: - - config - properties: - config: - type: string - IgnitionFirstboot: - type: object - additionalProperties: false - required: - - url - properties: - url: - type: string - description: Provisioning URL - Group: - type: object - additionalProperties: false - required: - - name - properties: - name: - type: string - description: Name of the group to create - gid: - type: integer - description: Group id of the group to create (optional) - Koji: - type: object - additionalProperties: false - required: - - server - - task_id - - name - - version - - release - properties: - server: - type: string - format: uri - example: 'https://koji.fedoraproject.org/kojihub' - task_id: - type: integer - example: 42 - name: - type: string - example: Fedora-Cloud-Base - version: - type: string - example: '31' - release: - type: string - example: '20200907.0' - ComposeId: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - required: - - id - properties: - id: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - - CloneComposeBody: - oneOf: - - $ref: '#/components/schemas/AWSEC2CloneCompose' - - AWSEC2CloneCompose: - type: object - additionalProperties: false - required: - - region - properties: - region: - type: string - share_with_accounts: - type: array - example: ['123456789012'] - items: - type: string - - CloneComposeResponse: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - type: object - required: - - id - properties: - id: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - - CloneStatus: - allOf: - - $ref: '#/components/schemas/ObjectReference' - - $ref: '#/components/schemas/UploadStatus' - - DepsolveRequest: - additionalProperties: false - required: - - blueprint - - distribution - - architecture - properties: - repositories: - type: array - items: - $ref: '#/components/schemas/Repository' - distribution: - type: string - example: 'rhel-8' - architecture: - type: string - example: 'x86_64' - blueprint: - $ref: '#/components/schemas/Blueprint' - - DepsolveResponse: - type: object - required: - - packages - properties: - packages: - type: array - items: - $ref: '#/components/schemas/PackageMetadataCommon' - description: 'Package list including NEVRA' - - SearchPackagesRequest: - additionalProperties: false - required: - - packages - - distribution - - architecture - properties: - repositories: - type: array - items: - $ref: '#/components/schemas/Repository' - distribution: - type: string - example: 'rhel-8' - architecture: - type: string - example: 'x86_64' - packages: - type: array - description: | - Array of package names to search for. Supports * wildcards for - names, but not for versions. - items: - type: string - - SearchPackagesResponse: - type: object - required: - - packages - properties: - packages: - type: array - items: - $ref: '#/components/schemas/PackageDetails' - description: 'Detailed package information from DNF' - - PackageDetails: - type: object - required: - - name - - version - - release - - arch - properties: - name: - type: string - summary: - type: string - description: - type: string - url: - type: string - version: - type: string - release: - type: string - epoch: - type: string - arch: - type: string - buildtime: - type: string - license: - type: string - - Disk: - type: object - required: - - partitions - properties: - type: - type: string - enum: - - gpt - - dos - description: | - Type of the partition table - minsize: - $ref: '#/components/schemas/minsize' - partitions: - type: array - items: - $ref: '#/components/schemas/Partition' - Partition: - type: object - oneOf: - - $ref: '#/components/schemas/FilesystemTyped' - - $ref: '#/components/schemas/BtrfsVolume' - - $ref: '#/components/schemas/VolumeGroup' - FilesystemTyped: - type: object - required: - - fs_type - properties: - type: - type: string - enum: - - plain - part_type: - type: string - description: | - The partition type GUID for GPT partitions. For DOS partitions, this field can be used to set the (2 hex digit) partition type. If not set, the type will be automatically set based on the mountpoint or the payload type. - minsize: - $ref: '#/components/schemas/minsize' - mountpoint: - type: string - label: - type: string - fs_type: - type: string - enum: - - ext4 - - xfs - - vfat - - swap - description: | - The filesystem type. Swap partitions must have an empty mountpoint. - BtrfsVolume: - type: object - required: - - type - - subvolumes - properties: - type: - type: string - enum: - - btrfs - part_type: - type: string - description: | - The partition type GUID for GPT partitions. For DOS partitions, this field can be used to set the (2 hex digit) partition type. If not set, the type will be automatically set based on the mountpoint or the payload type. - minsize: - $ref: '#/components/schemas/minsize' - subvolumes: - type: array - items: - $ref: '#/components/schemas/BtrfsSubvolume' - BtrfsSubvolume: - type: object - required: - - name - - mountpoint - properties: - name: - type: string - description: | - The name of the subvolume, which defines the location (path) on the root volume - mountpoint: - type: string - description: | - Mountpoint for the subvolume - VolumeGroup: - type: object - required: - - type - - logical_volumes - properties: - type: - type: string - enum: - - lvm - part_type: - type: string - description: | - The partition type GUID for GPT partitions. For DOS partitions, this field can be used to set the (2 hex digit) partition type. If not set, the type will be automatically set based on the mountpoint or the payload type. - name: - type: string - description: | - Volume group name (will be automatically generated if omitted) - minsize: - $ref: '#/components/schemas/minsize' - logical_volumes: - type: array - items: - $ref: '#/components/schemas/LogicalVolume' - LogicalVolume: - type: object - required: - - fs_type - properties: - name: - type: string - minsize: - $ref: '#/components/schemas/minsize' - mountpoint: - type: string - description: | - Mountpoint for the logical volume - label: - type: string - fs_type: - type: string - enum: - - ext4 - - xfs - - vfat - - swap - description: | - The filesystem type for the logical volume. Swap LVs must have an empty mountpoint. - minsize: - type: string - example: "2 GiB" - description: 'size with data units' - - parameters: - page: - name: page - in: query - description: Page index - required: false - schema: - type: string - examples: - page: - value: "1" - size: - name: size - in: query - description: Number of items in each page - required: false - schema: - type: string - examples: - size: - value: "100" - - securitySchemes: - Bearer: - scheme: bearer - bearerFormat: JWT - type: http diff --git a/api/schema/contentSources.json b/api/schema/contentSources.json deleted file mode 100644 index 13641c5b..00000000 --- a/api/schema/contentSources.json +++ /dev/null @@ -1,6657 +0,0 @@ -{ - "components": { - "schemas": { - "api.AddUploadsRequest": { - "properties": { - "artifacts": { - "description": "List of created artifacts", - "items": { - "$ref": "#/components/schemas/api.Artifact" - }, - "type": "array" - }, - "uploads": { - "description": "List of unfinished uploads", - "items": { - "$ref": "#/components/schemas/api.Upload" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.Artifact": { - "properties": { - "href": { - "description": "HREF to the completed artifact", - "type": "string" - }, - "sha256": { - "description": "SHA256 sum of the completed artifact", - "type": "string" - } - }, - "type": "object" - }, - "api.ContentUnitSearchRequest": { - "properties": { - "exact_names": { - "description": "List of names to search using an exact match", - "items": { - "type": "string" - }, - "type": "array" - }, - "include_package_sources": { - "description": "Whether to include module information", - "type": "boolean" - }, - "limit": { - "description": "Maximum number of records to return for the search", - "type": "integer" - }, - "search": { - "description": "Search string to search content unit names", - "type": "string" - }, - "urls": { - "description": "URLs of repositories to search", - "items": { - "type": "string" - }, - "type": "array" - }, - "uuids": { - "description": "List of repository UUIDs to search", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.CreateUploadRequest": { - "properties": { - "chunk_size": { - "description": "Size of the chunk", - "type": "integer" - }, - "sha256": { - "description": "SHA-256 checksum of the file", - "type": "string" - }, - "size": { - "description": "Size of the upload in bytes", - "type": "integer" - } - }, - "required": [ - "chunk_size", - "sha256", - "size" - ], - "type": "object" - }, - "api.DetectRpmsRequest": { - "properties": { - "limit": { - "description": "Maximum number of records to return for the search", - "type": "integer" - }, - "rpm_names": { - "description": "List of rpm names to search", - "items": { - "type": "string" - }, - "type": "array" - }, - "urls": { - "description": "URLs of repositories to search", - "items": { - "type": "string" - }, - "type": "array" - }, - "uuids": { - "description": "List of repository UUIDs to search", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.DetectRpmsResponse": { - "properties": { - "found": { - "description": "List of rpm names found in given repositories", - "items": { - "type": "string" - }, - "type": "array" - }, - "missing": { - "description": "List of rpm names not found in given repositories", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.Feature": { - "properties": { - "accessible": { - "description": "Whether the current user can access the feature", - "type": "boolean" - }, - "enabled": { - "description": "Whether the feature is enabled on the running server", - "type": "boolean" - } - }, - "type": "object" - }, - "api.FeatureSet": { - "additionalProperties": { - "$ref": "#/components/schemas/api.Feature" - }, - "type": "object" - }, - "api.FetchGPGKeyRequest": { - "properties": { - "url": { - "description": "The url from which to download the GPG Key.", - "type": "string" - } - }, - "required": [ - "url" - ], - "type": "object" - }, - "api.FetchGPGKeyResponse": { - "properties": { - "gpg_key": { - "description": "The downloaded GPG Keys from the provided url.", - "type": "string" - } - }, - "type": "object" - }, - "api.GenericAttributeValidationResponse": { - "properties": { - "error": { - "description": "Error message if the attribute is not valid", - "type": "string" - }, - "skipped": { - "description": "Skipped if the attribute is not passed in for validation", - "type": "boolean" - }, - "valid": { - "description": "Valid if not skipped and the provided attribute is valid", - "type": "boolean" - } - }, - "type": "object" - }, - "api.Links": { - "properties": { - "first": { - "description": "Path to first page of results", - "type": "string" - }, - "last": { - "description": "Path to last page of results", - "type": "string" - }, - "next": { - "description": "Path to next page of results", - "type": "string" - }, - "prev": { - "description": "Path to previous page of results", - "type": "string" - } - }, - "type": "object" - }, - "api.ListSnapshotByDateRequest": { - "properties": { - "date": { - "description": "Exact date to search by.", - "type": "string" - }, - "repository_uuids": { - "description": "Repository UUIDs to find snapshots for", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "date", - "repository_uuids" - ], - "type": "object" - }, - "api.ListSnapshotByDateResponse": { - "properties": { - "data": { - "description": "Requested Data", - "items": { - "$ref": "#/components/schemas/api.SnapshotForDate" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.PackageSourcesResponse": { - "properties": { - "arch": { - "description": "Architecture of the module", - "type": "string" - }, - "context": { - "description": "Context of the module", - "type": "string" - }, - "description": { - "description": "Description of the module", - "type": "string" - }, - "end_date": { - "description": "End date of the lifecycle", - "type": "string" - }, - "name": { - "description": "Name of the module", - "type": "string" - }, - "start_date": { - "description": "Start date of the lifecycle", - "type": "string" - }, - "stream": { - "description": "Stream of the module", - "type": "string" - }, - "type": { - "description": "Type of rpm (can be either 'package' or 'module')", - "type": "string" - }, - "version": { - "description": "Version of the module", - "type": "string" - } - }, - "type": "object" - }, - "api.PopularRepositoriesCollectionResponse": { - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/api.PopularRepositoryResponse" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.PopularRepositoryResponse": { - "properties": { - "distribution_arch": { - "description": "Architecture to restrict client usage to", - "example": "x86_64", - "type": "string" - }, - "distribution_versions": { - "description": "Versions to restrict client usage to", - "example": [ - "7", - "8" - ], - "items": { - "type": "string" - }, - "type": "array" - }, - "existing_name": { - "description": "Existing reference name for repository", - "type": "string" - }, - "gpg_key": { - "description": "GPG key for repository", - "type": "string" - }, - "metadata_verification": { - "description": "Verify packages", - "type": "boolean" - }, - "suggested_name": { - "description": "Suggested name of the popular repository", - "type": "string" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - }, - "uuid": { - "description": "UUID of the repository if it exists for the user", - "type": "string" - } - }, - "type": "object" - }, - "api.PublicRepositoryCollectionResponse": { - "properties": { - "data": { - "items": { - "$ref": "#/components/schemas/api.PublicRepositoryResponse" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.PublicRepositoryResponse": { - "properties": { - "last_introspection_error": { - "description": "Error of last attempted introspection", - "type": "string" - }, - "last_introspection_status": { - "description": "Status of last introspection", - "type": "string" - }, - "last_introspection_time": { - "description": "Timestamp of last attempted introspection", - "type": "string" - }, - "last_success_introspection_time": { - "description": "Timestamp of last successful introspection", - "type": "string" - }, - "last_update_introspection_time": { - "description": "Timestamp of last introspection that had updates", - "type": "string" - }, - "package_count": { - "description": "Number of packages last read in the repository", - "type": "integer" - }, - "status": { - "description": "Combined introspection and snapshot status of the repository", - "type": "string" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryCollectionResponse": { - "properties": { - "data": { - "description": "Requested Data", - "items": { - "$ref": "#/components/schemas/api.RepositoryResponse" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.RepositoryEnvironment": { - "properties": { - "description": { - "description": "The environment description", - "type": "string" - }, - "id": { - "description": "The environment ID", - "type": "string" - }, - "name": { - "description": "The environment name", - "type": "string" - }, - "uuid": { - "description": "Identifier of the environment", - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryEnvironmentCollectionResponse": { - "properties": { - "data": { - "description": "List of environments", - "items": { - "$ref": "#/components/schemas/api.RepositoryEnvironment" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.RepositoryExportRequest": { - "properties": { - "repository_uuids": { - "description": "List of repository uuids to export", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "repository_uuids" - ], - "type": "object" - }, - "api.RepositoryExportResponse": { - "properties": { - "distribution_arch": { - "description": "Architecture to restrict client usage to", - "example": "x86_64", - "type": "string" - }, - "distribution_versions": { - "description": "Versions to restrict client usage to", - "example": [ - "8" - ], - "items": { - "type": "string" - }, - "type": "array" - }, - "gpg_key": { - "description": "GPG key for repository", - "type": "string" - }, - "metadata_verification": { - "description": "Verify packages", - "type": "boolean" - }, - "module_hotfixes": { - "description": "Disable modularity filtering on this repository", - "type": "boolean" - }, - "name": { - "description": "Name of the remote yum repository", - "type": "string" - }, - "origin": { - "description": "Origin of the repository", - "type": "string" - }, - "snapshot": { - "description": "Enable snapshotting and hosting of this repository", - "type": "boolean" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryImportResponse": { - "properties": { - "account_id": { - "description": "Account ID of the owner", - "readOnly": true, - "type": "string" - }, - "content_type": { - "description": "Content Type (rpm) of the repository", - "type": "string" - }, - "distribution_arch": { - "description": "Architecture to restrict client usage to", - "example": "x86_64", - "type": "string" - }, - "distribution_versions": { - "description": "Versions to restrict client usage to", - "example": [ - "7", - "8" - ], - "items": { - "type": "string" - }, - "type": "array" - }, - "failed_introspections_count": { - "description": "Number of consecutive failed introspections", - "type": "integer" - }, - "failed_snapshot_count": { - "description": "Number of consecutive failed snapshots", - "type": "integer" - }, - "feature_name": { - "description": "The feature name this repo requires", - "type": "string" - }, - "gpg_key": { - "description": "GPG key for repository", - "type": "string" - }, - "label": { - "description": "Label used to configure the yum repository on clients", - "type": "string" - }, - "last_introspection_error": { - "description": "Error of last attempted introspection", - "type": "string" - }, - "last_introspection_status": { - "description": "Status of last introspection", - "type": "string" - }, - "last_introspection_time": { - "description": "Timestamp of last attempted introspection", - "type": "string" - }, - "last_snapshot": { - "$ref": "#/components/schemas/api.SnapshotResponse" - }, - "last_snapshot_task": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - }, - "last_snapshot_task_uuid": { - "description": "UUID of the last snapshot task", - "type": "string" - }, - "last_snapshot_uuid": { - "description": "UUID of the last dao.Snapshot", - "type": "string" - }, - "last_success_introspection_time": { - "description": "Timestamp of last successful introspection", - "type": "string" - }, - "last_update_introspection_time": { - "description": "Timestamp of last introspection that had updates", - "type": "string" - }, - "latest_snapshot_url": { - "description": "Latest URL for the snapshot distribution", - "type": "string" - }, - "metadata_verification": { - "description": "Verify packages", - "type": "boolean" - }, - "module_hotfixes": { - "description": "Disable modularity filtering on this repository", - "type": "boolean" - }, - "name": { - "description": "Name of the remote yum repository", - "type": "string" - }, - "org_id": { - "description": "Organization ID of the owner", - "readOnly": true, - "type": "string" - }, - "origin": { - "description": "Origin of the repository", - "type": "string" - }, - "package_count": { - "description": "Number of packages last read in the repository", - "type": "integer" - }, - "snapshot": { - "description": "Enable snapshotting and hosting of this repository", - "type": "boolean" - }, - "status": { - "description": "Combined status of last introspection and snapshot of repository (Valid, Invalid, Unavailable, Pending)", - "type": "string" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - }, - "uuid": { - "description": "UUID of the object", - "readOnly": true, - "type": "string" - }, - "warnings": { - "description": "Warnings to alert user of mismatched fields if there is an existing repo with the same URL", - "items": { - "additionalProperties": true, - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.RepositoryIntrospectRequest": { - "properties": { - "reset_count": { - "description": "Reset the failed introspections count", - "type": "boolean" - } - }, - "type": "object" - }, - "api.RepositoryPackageGroup": { - "properties": { - "description": { - "description": "The package group description", - "type": "string" - }, - "id": { - "description": "The package group ID", - "type": "string" - }, - "name": { - "description": "The package group name", - "type": "string" - }, - "packagelist": { - "description": "The list of packages in the package group", - "items": { - "type": "string" - }, - "type": "array" - }, - "uuid": { - "description": "Identifier of the package group", - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryPackageGroupCollectionResponse": { - "properties": { - "data": { - "description": "List of package groups", - "items": { - "$ref": "#/components/schemas/api.RepositoryPackageGroup" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.RepositoryParameterResponse": { - "properties": { - "distribution_arches": { - "description": "Architectures available for repository creation", - "items": { - "$ref": "#/components/schemas/config.DistributionArch" - }, - "type": "array" - }, - "distribution_versions": { - "description": "Versions available for repository creation", - "items": { - "$ref": "#/components/schemas/config.DistributionVersion" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.RepositoryRequest": { - "properties": { - "distribution_arch": { - "description": "Architecture to restrict client usage to", - "example": "x86_64", - "type": "string" - }, - "distribution_versions": { - "description": "Versions to restrict client usage to", - "example": [ - "7", - "8" - ], - "items": { - "type": "string" - }, - "type": "array" - }, - "gpg_key": { - "description": "GPG key for repository", - "type": "string" - }, - "metadata_verification": { - "description": "Verify packages", - "type": "boolean" - }, - "module_hotfixes": { - "description": "Disable modularity filtering on this repository", - "type": "boolean" - }, - "name": { - "description": "Name of the remote yum repository", - "type": "string" - }, - "origin": { - "description": "Origin of the repository", - "readOnly": true, - "type": "string" - }, - "snapshot": { - "description": "Enable snapshotting and hosting of this repository", - "type": "boolean" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "api.RepositoryResponse": { - "properties": { - "account_id": { - "description": "Account ID of the owner", - "readOnly": true, - "type": "string" - }, - "content_type": { - "description": "Content Type (rpm) of the repository", - "type": "string" - }, - "distribution_arch": { - "description": "Architecture to restrict client usage to", - "example": "x86_64", - "type": "string" - }, - "distribution_versions": { - "description": "Versions to restrict client usage to", - "example": [ - "7", - "8" - ], - "items": { - "type": "string" - }, - "type": "array" - }, - "failed_introspections_count": { - "description": "Number of consecutive failed introspections", - "type": "integer" - }, - "failed_snapshot_count": { - "description": "Number of consecutive failed snapshots", - "type": "integer" - }, - "feature_name": { - "description": "The feature name this repo requires", - "type": "string" - }, - "gpg_key": { - "description": "GPG key for repository", - "type": "string" - }, - "label": { - "description": "Label used to configure the yum repository on clients", - "type": "string" - }, - "last_introspection_error": { - "description": "Error of last attempted introspection", - "type": "string" - }, - "last_introspection_status": { - "description": "Status of last introspection", - "type": "string" - }, - "last_introspection_time": { - "description": "Timestamp of last attempted introspection", - "type": "string" - }, - "last_snapshot": { - "$ref": "#/components/schemas/api.SnapshotResponse" - }, - "last_snapshot_task": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - }, - "last_snapshot_task_uuid": { - "description": "UUID of the last snapshot task", - "type": "string" - }, - "last_snapshot_uuid": { - "description": "UUID of the last dao.Snapshot", - "type": "string" - }, - "last_success_introspection_time": { - "description": "Timestamp of last successful introspection", - "type": "string" - }, - "last_update_introspection_time": { - "description": "Timestamp of last introspection that had updates", - "type": "string" - }, - "latest_snapshot_url": { - "description": "Latest URL for the snapshot distribution", - "type": "string" - }, - "metadata_verification": { - "description": "Verify packages", - "type": "boolean" - }, - "module_hotfixes": { - "description": "Disable modularity filtering on this repository", - "type": "boolean" - }, - "name": { - "description": "Name of the remote yum repository", - "type": "string" - }, - "org_id": { - "description": "Organization ID of the owner", - "readOnly": true, - "type": "string" - }, - "origin": { - "description": "Origin of the repository", - "type": "string" - }, - "package_count": { - "description": "Number of packages last read in the repository", - "type": "integer" - }, - "snapshot": { - "description": "Enable snapshotting and hosting of this repository", - "type": "boolean" - }, - "status": { - "description": "Combined status of last introspection and snapshot of repository (Valid, Invalid, Unavailable, Pending)", - "type": "string" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - }, - "uuid": { - "description": "UUID of the object", - "readOnly": true, - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryRpm": { - "properties": { - "arch": { - "description": "The architecture of the rpm", - "type": "string" - }, - "checksum": { - "description": "The checksum of the rpm", - "type": "string" - }, - "epoch": { - "description": "The epoch of the rpm", - "type": "integer" - }, - "name": { - "description": "The rpm package name", - "type": "string" - }, - "release": { - "description": "The release of the rpm", - "type": "string" - }, - "summary": { - "description": "The summary of the rpm", - "type": "string" - }, - "uuid": { - "description": "Identifier of the rpm", - "type": "string" - }, - "version": { - "description": "The version of the rpm", - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryRpmCollectionResponse": { - "properties": { - "data": { - "description": "List of rpms", - "items": { - "$ref": "#/components/schemas/api.RepositoryRpm" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.RepositoryUpdateRequest": { - "properties": { - "distribution_arch": { - "description": "Architecture to restrict client usage to", - "example": "x86_64", - "type": "string" - }, - "distribution_versions": { - "description": "Versions to restrict client usage to", - "example": [ - "7", - "8" - ], - "items": { - "type": "string" - }, - "type": "array" - }, - "gpg_key": { - "description": "GPG key for repository", - "type": "string" - }, - "metadata_verification": { - "description": "Verify packages", - "type": "boolean" - }, - "module_hotfixes": { - "description": "Disable modularity filtering on this repository", - "type": "boolean" - }, - "name": { - "description": "Name of the remote yum repository", - "type": "string" - }, - "snapshot": { - "description": "Enable snapshotting and hosting of this repository", - "type": "boolean" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryValidationRequest": { - "properties": { - "gpg_key": { - "description": "GPGKey of the remote yum repository", - "type": "string" - }, - "metadata_verification": { - "description": "If set, attempt to validate the yum metadata with the specified GPG Key", - "type": "boolean" - }, - "name": { - "description": "Name of the remote yum repository", - "type": "string" - }, - "url": { - "description": "URL of the remote yum repository", - "type": "string" - }, - "uuid": { - "description": "If set, this is an \"Update\" validation", - "type": "string" - } - }, - "type": "object" - }, - "api.RepositoryValidationResponse": { - "properties": { - "gpg_key": { - "$ref": "#/components/schemas/api.GenericAttributeValidationResponse" - }, - "name": { - "$ref": "#/components/schemas/api.GenericAttributeValidationResponse" - }, - "url": { - "$ref": "#/components/schemas/api.UrlValidationResponse" - } - }, - "type": "object" - }, - "api.ResponseMetadata": { - "properties": { - "count": { - "description": "Total count of results", - "type": "integer" - }, - "limit": { - "description": "Limit of results used for the request", - "type": "integer" - }, - "offset": { - "description": "Offset into results used for the request", - "type": "integer" - } - }, - "type": "object" - }, - "api.SearchEnvironmentResponse": { - "properties": { - "description": { - "description": "Description of the environment found", - "type": "string" - }, - "environment_name": { - "description": "Environment found", - "type": "string" - }, - "id": { - "description": "ID of the environment found", - "type": "string" - } - }, - "type": "object" - }, - "api.SearchModuleStreams": { - "properties": { - "module_name": { - "description": "Module name", - "type": "string" - }, - "streams": { - "description": "A list of stream related information for the module", - "items": { - "$ref": "#/components/schemas/api.Stream" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.SearchModuleStreamsRequest": { - "properties": { - "rpm_names": { - "description": "List of rpm names to search", - "items": { - "type": "string" - }, - "type": "array" - }, - "search": { - "description": "Search string to search rpm names", - "type": "string" - }, - "sort_by": { - "description": "SortBy sets the sort order of the result", - "type": "string" - }, - "urls": { - "description": "List of repository URLs to search", - "items": { - "type": "string" - }, - "type": "array" - }, - "uuids": { - "description": "List of repository UUIDs to search", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "rpm_names", - "urls", - "uuids" - ], - "type": "object" - }, - "api.SearchPackageGroupResponse": { - "properties": { - "description": { - "description": "Description of the package group found", - "type": "string" - }, - "id": { - "description": "Package group ID", - "type": "string" - }, - "package_group_name": { - "description": "Name of package group found", - "type": "string" - }, - "package_list": { - "description": "Package list of the package group found", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.SearchRpmResponse": { - "properties": { - "package_name": { - "description": "Package name found", - "type": "string" - }, - "package_sources": { - "description": "List of the module streams for the package", - "items": { - "$ref": "#/components/schemas/api.PackageSourcesResponse" - }, - "type": "array" - }, - "summary": { - "description": "Summary of the package found", - "type": "string" - } - }, - "type": "object" - }, - "api.SearchSnapshotModuleStreamsRequest": { - "properties": { - "rpm_names": { - "description": "List of rpm names to restrict returned modules", - "items": { - "type": "string" - }, - "type": "array" - }, - "search": { - "description": "Search string to search module names", - "type": "string" - }, - "sort_by": { - "description": "SortBy sets the sort order of the result", - "type": "string" - }, - "uuids": { - "description": "List of snapshot UUIDs to search", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "rpm_names", - "uuids" - ], - "type": "object" - }, - "api.SnapshotCollectionResponse": { - "properties": { - "data": { - "description": "Requested Data", - "items": { - "$ref": "#/components/schemas/api.SnapshotResponse" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.SnapshotErrata": { - "properties": { - "cves": { - "description": "List of CVEs", - "items": { - "type": "string" - }, - "type": "array" - }, - "description": { - "description": "Description of the errata", - "type": "string" - }, - "errata_id": { - "description": "ID of the errata", - "type": "string" - }, - "id": { - "type": "string" - }, - "issued_date": { - "description": "IssuedDate of the errata", - "type": "string" - }, - "reboot_suggested": { - "description": "Whether a reboot is suggested", - "type": "boolean" - }, - "severity": { - "description": "Severity of the errata", - "type": "string" - }, - "summary": { - "description": "Summary of the errata", - "type": "string" - }, - "title": { - "description": "Title of the errata", - "type": "string" - }, - "type": { - "description": "Type of the errata", - "type": "string" - }, - "updated_date": { - "description": "UpdateDate of the errata", - "type": "string" - } - }, - "type": "object" - }, - "api.SnapshotErrataCollectionResponse": { - "properties": { - "data": { - "description": "List of errata", - "items": { - "$ref": "#/components/schemas/api.SnapshotErrata" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.SnapshotForDate": { - "properties": { - "is_after": { - "description": "Is the snapshot after the specified date", - "type": "boolean" - }, - "match": { - "$ref": "#/components/schemas/api.SnapshotResponse" - }, - "repository_uuid": { - "description": "Repository uuid for associated snapshot", - "type": "string" - } - }, - "type": "object" - }, - "api.SnapshotResponse": { - "properties": { - "added_counts": { - "additionalProperties": { - "type": "integer" - }, - "description": "Count of each content type", - "type": "object" - }, - "content_counts": { - "additionalProperties": { - "type": "integer" - }, - "description": "Count of each content type", - "type": "object" - }, - "created_at": { - "description": "Datetime the snapshot was created", - "type": "string" - }, - "removed_counts": { - "additionalProperties": { - "type": "integer" - }, - "description": "Count of each content type", - "type": "object" - }, - "repository_name": { - "description": "Name of repository the snapshot belongs to", - "type": "string" - }, - "repository_path": { - "description": "Path to repository snapshot contents", - "type": "string" - }, - "repository_uuid": { - "description": "UUID of the repository the snapshot belongs to", - "type": "string" - }, - "url": { - "description": "URL to the snapshot's content", - "type": "string" - }, - "uuid": { - "type": "string" - } - }, - "type": "object" - }, - "api.SnapshotRpm": { - "properties": { - "arch": { - "description": "The architecture of the rpm", - "type": "string" - }, - "epoch": { - "description": "The epoch of the rpm", - "type": "string" - }, - "name": { - "description": "The rpm package name", - "type": "string" - }, - "release": { - "description": "The release of the rpm", - "type": "string" - }, - "summary": { - "description": "The summary of the rpm", - "type": "string" - }, - "version": { - "description": "The version of the rpm", - "type": "string" - } - }, - "type": "object" - }, - "api.SnapshotRpmCollectionResponse": { - "properties": { - "data": { - "description": "List of rpms", - "items": { - "$ref": "#/components/schemas/api.SnapshotRpm" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.SnapshotSearchRpmRequest": { - "properties": { - "include_package_sources": { - "description": "Whether to include module information", - "type": "boolean" - }, - "limit": { - "description": "Maximum number of records to return for the search", - "type": "integer" - }, - "search": { - "description": "Search string to search rpm names", - "type": "string" - }, - "uuids": { - "description": "List of Snapshot UUIDs to search", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "api.Stream": { - "properties": { - "arch": { - "description": "The Architecture of the rpm", - "type": "string" - }, - "context": { - "description": "Context of the module", - "type": "string" - }, - "description": { - "description": "Module description", - "type": "string" - }, - "name": { - "description": "Name of the module", - "type": "string" - }, - "profiles": { - "additionalProperties": { - "items": { - "type": "string" - }, - "type": "array" - }, - "description": "Module profile data", - "type": "object" - }, - "stream": { - "description": "Module stream version", - "type": "string" - }, - "version": { - "description": "The version of the rpm", - "type": "string" - } - }, - "type": "object" - }, - "api.TaskInfoCollectionResponse": { - "properties": { - "data": { - "description": "Requested Data", - "items": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.TaskInfoResponse": { - "properties": { - "created_at": { - "description": "Timestamp of task creation", - "type": "string" - }, - "dependencies": { - "description": "UUIDs of parent tasks", - "items": { - "type": "string" - }, - "type": "array" - }, - "dependents": { - "description": "UUIDs of child tasks", - "items": { - "type": "string" - }, - "type": "array" - }, - "ended_at": { - "description": "Timestamp task ended running at", - "type": "string" - }, - "error": { - "description": "Error thrown while running task", - "type": "string" - }, - "object_name": { - "description": "Name of the associated repository or template", - "type": "string" - }, - "object_type": { - "description": "Type of the associated object, either repository or template", - "type": "string" - }, - "object_uuid": { - "description": "UUID of the associated repository or template", - "type": "string" - }, - "org_id": { - "description": "Organization ID of the owner", - "type": "string" - }, - "status": { - "description": "Status of task (running, failed, completed, canceled, pending)", - "type": "string" - }, - "type": { - "description": "Type of task", - "type": "string" - }, - "uuid": { - "description": "UUID of the object", - "type": "string" - } - }, - "type": "object" - }, - "api.TemplateCollectionResponse": { - "properties": { - "data": { - "description": "Requested Data", - "items": { - "$ref": "#/components/schemas/api.TemplateResponse" - }, - "type": "array" - }, - "links": { - "$ref": "#/components/schemas/api.Links" - }, - "meta": { - "$ref": "#/components/schemas/api.ResponseMetadata" - } - }, - "type": "object" - }, - "api.TemplateRequest": { - "properties": { - "arch": { - "description": "Architecture of the template", - "type": "string" - }, - "date": { - "description": "Latest date to include snapshots for", - "type": "string" - }, - "description": { - "description": "Description of the template", - "type": "string" - }, - "name": { - "description": "Name of the template", - "type": "string" - }, - "repository_uuids": { - "description": "Repositories to add to the template", - "items": { - "type": "string" - }, - "type": "array" - }, - "use_latest": { - "description": "Use latest snapshot for all repositories in the template", - "type": "boolean" - }, - "version": { - "description": "Version of the template", - "type": "string" - } - }, - "required": [ - "arch", - "name", - "repository_uuids", - "version" - ], - "type": "object" - }, - "api.TemplateResponse": { - "properties": { - "arch": { - "description": "Architecture of the template", - "type": "string" - }, - "created_at": { - "description": "Datetime template was created", - "type": "string" - }, - "created_by": { - "description": "User that created the template", - "type": "string" - }, - "date": { - "description": "Latest date to include snapshots for", - "type": "string" - }, - "description": { - "description": "Description of the template", - "type": "string" - }, - "last_update_snapshot_error": { - "description": "Error of last update_latest_snapshot task that updated the template", - "type": "string" - }, - "last_update_task": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - }, - "last_update_task_uuid": { - "description": "UUID of the last update_template_content task that updated the template", - "type": "string" - }, - "last_updated_by": { - "description": "User that most recently updated the template", - "type": "string" - }, - "name": { - "description": "Name of the template", - "type": "string" - }, - "org_id": { - "description": "Organization ID of the owner", - "type": "string" - }, - "repository_uuids": { - "description": "Repositories added to the template", - "items": { - "type": "string" - }, - "type": "array" - }, - "rhsm_environment_created": { - "description": "Whether the candlepin environment is created and systems can be added", - "readOnly": true, - "type": "boolean" - }, - "rhsm_environment_id": { - "description": "Environment ID used by subscription-manager and candlepin", - "type": "string" - }, - "snapshots": { - "description": "The list of snapshots in use by the template", - "items": { - "$ref": "#/components/schemas/api.SnapshotResponse" - }, - "readOnly": true, - "type": "array" - }, - "to_be_deleted_snapshots": { - "description": "List of snapshots used by this template which are going to be deleted soon", - "items": { - "$ref": "#/components/schemas/api.SnapshotResponse" - }, - "readOnly": true, - "type": "array" - }, - "updated_at": { - "description": "Datetime template was last updated", - "type": "string" - }, - "use_latest": { - "description": "Use latest snapshot for all repositories in the template", - "type": "boolean" - }, - "uuid": { - "readOnly": true, - "type": "string" - }, - "version": { - "description": "Version of the template", - "type": "string" - } - }, - "type": "object" - }, - "api.TemplateUpdateRequest": { - "properties": { - "date": { - "description": "Latest date to include snapshots for", - "type": "string" - }, - "description": { - "description": "Description of the template", - "type": "string" - }, - "name": { - "description": "Name of the template", - "type": "string" - }, - "repository_uuids": { - "description": "Repositories to add to the template", - "items": { - "type": "string" - }, - "type": "array" - }, - "use_latest": { - "description": "Use latest snapshot for all repositories in the template", - "type": "boolean" - } - }, - "type": "object" - }, - "api.UUIDListRequest": { - "properties": { - "uuids": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "uuids" - ], - "type": "object" - }, - "api.Upload": { - "properties": { - "href": { - "description": "HREF to the unfinished upload, use with internal API", - "type": "string" - }, - "sha256": { - "description": "SHA256 sum of the uploaded file", - "type": "string" - }, - "uuid": { - "description": "Upload UUID, use with public API", - "type": "string" - } - }, - "type": "object" - }, - "api.UploadResponse": { - "properties": { - "artifact_href": { - "description": "Artifact href if one exists (on create only)", - "type": "string" - }, - "completed": { - "description": "Timestamp when upload is committed", - "type": "string" - }, - "completed_checksums": { - "description": "A list of already completed checksums", - "items": { - "type": "string" - }, - "type": "array" - }, - "created": { - "description": "Timestamp of creation", - "type": "string" - }, - "last_updated": { - "description": "Timestamp of last update", - "type": "string" - }, - "size": { - "description": "Size of the upload in bytes", - "type": "integer" - }, - "upload_uuid": { - "description": "Upload UUID", - "type": "string" - } - }, - "type": "object" - }, - "api.UrlValidationResponse": { - "properties": { - "error": { - "description": "Error message if the attribute is not valid", - "type": "string" - }, - "http_code": { - "description": "If the metadata cannot be fetched successfully, the http code that is returned if the http request was completed", - "type": "integer" - }, - "metadata_present": { - "description": "True if the metadata can be fetched successfully", - "type": "boolean" - }, - "metadata_signature_present": { - "description": "True if a repomd.xml.sig file was found in the repository", - "type": "boolean" - }, - "skipped": { - "description": "Skipped if the URL is not passed in for validation", - "type": "boolean" - }, - "valid": { - "description": "Valid if not skipped and the provided attribute is valid", - "type": "boolean" - } - }, - "type": "object" - }, - "config.DistributionArch": { - "properties": { - "label": { - "description": "Static label of the architecture", - "type": "string" - }, - "name": { - "description": "Human-readable form of the architecture", - "type": "string" - } - }, - "type": "object" - }, - "config.DistributionVersion": { - "properties": { - "label": { - "description": "Static label of the version", - "type": "string" - }, - "name": { - "description": "Human-readable form of the version", - "type": "string" - } - }, - "type": "object" - }, - "errors.ErrorResponse": { - "properties": { - "errors": { - "items": { - "$ref": "#/components/schemas/errors.HandlerError" - }, - "type": "array" - } - }, - "type": "object" - }, - "errors.HandlerError": { - "properties": { - "detail": { - "description": "An explanation specific to the problem", - "type": "string" - }, - "status": { - "description": "HTTP status code applicable to the error", - "type": "integer" - }, - "title": { - "description": "A summary of the problem", - "type": "string" - } - }, - "type": "object" - } - }, - "securitySchemes": { - "RhIdentity": { - "in": "header", - "name": "x-rh-identity", - "type": "apiKey" - } - } - }, - "info": { - "contact": {}, - "description": "The API for the repositories of the content sources that you can use to create and manage repositories between third-party applications and the [Red Hat Hybrid Cloud Console](https://console.redhat.com). With these repositories, you can build and deploy images using Image Builder for Cloud, on-Premise, and Edge. You can handle tasks, search for required RPMs, fetch a GPGKey from the URL, and list the features within applications.\n", - "license": { - "name": "Apache 2.0", - "url": "https://www.apache.org/licenses/LICENSE-2.0" - }, - "title": "ContentSourcesBackend", - "version": "v1.0.0" - }, - "openapi": "3.0.3", - "paths": { - "/environments/names": { - "post": { - "description": "This enables users to search for environments in a given list of repositories.", - "operationId": "searchEnvironments", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.ContentUnitSearchRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchEnvironmentResponse" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Search environments", - "tags": [ - "environments" - ] - } - }, - "/features/": { - "get": { - "description": "Get features enables retrieving information about the features within an application, regardless of their current status (enabled or disabled) and the user's access to them.", - "operationId": "listFeatures", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.FeatureSet" - } - } - }, - "description": "OK" - } - }, - "summary": "List Features within the application, whether they are enabled, and whether the requesting user can use them", - "tags": [ - "features" - ] - } - }, - "/module_streams/search": { - "post": { - "description": "List modules and their streams for repositories", - "operationId": "searchRepositoryModuleStreams", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SearchModuleStreamsRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchModuleStreams" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List modules and their streams for repositories", - "tags": [ - "module_streams" - ] - } - }, - "/package_groups/names": { - "post": { - "description": "This enables users to search for package groups in a given list of repositories.", - "operationId": "searchPackageGroup", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.ContentUnitSearchRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchPackageGroupResponse" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Search package groups", - "tags": [ - "packagegroups" - ] - } - }, - "/popular_repositories/": { - "get": { - "description": "This operation enables retrieving a paginated list of repository suggestions that are commonly used.", - "operationId": "listPopularRepositories", - "parameters": [ - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name or URL.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.PopularRepositoriesCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Popular Repositories", - "tags": [ - "popular_repositories" - ] - } - }, - "/public_repositories/": { - "get": { - "description": "Get public repositories.\nThis enables listing a set of pre-created entries that represent a base set of RPMs needed for image building. These repositories are defined and made available to all user accounts, enabling them to perform RPM name searches using URLs as search criteria. These public repositories are not listed by the normal repositories API.\nIt does not show up via the normal repositories API.", - "operationId": "listPublicRepositories", - "parameters": [ - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.PublicRepositoryCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Public Repositories", - "tags": [ - "public_repositories" - ] - } - }, - "/repositories/": { - "get": { - "description": "This operation enables users to retrieve a list of repositories.", - "operationId": "listRepositories", - "parameters": [ - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "A comma separated list of release versions to filter on. For example, `1,2` would return repositories with versions 1 or 2 only.", - "in": "query", - "name": "version", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of architectures or platforms for that you want to retrieve repositories. It controls responses where repositories support multiple architectures or platforms. For example, ‘x86_64,s390x' returns repositories with `x86_64` or `s390x` only.", - "in": "query", - "name": "arch", - "schema": { - "type": "string" - } - }, - { - "description": "Filter repositories by supported release version. For example, `1` returns repositories with the version `1` or where version is not set.", - "in": "query", - "name": "available_for_version", - "schema": { - "type": "string" - } - }, - { - "description": "Filter repositories by architecture. For example, `x86_64` returns repositories with the version `x86_64` or where architecture is not set.", - "in": "query", - "name": "available_for_arch", - "schema": { - "type": "string" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name or URL.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - }, - { - "description": "Filter repositories by name.", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of URLs to control api response.", - "in": "query", - "name": "url", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of UUIDs to control api response.", - "in": "query", - "name": "uuid", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response data based on specific repository parameters. Sort criteria can include `name`, `url`, `status`, and `package_count`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of statuses to control api response. Statuses can include `Pending`, `Valid`, `Invalid`, `Unavailable`.", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of origins to filter api response. Origins can include `red_hat` and `external`.", - "in": "query", - "name": "origin", - "schema": { - "type": "string" - } - }, - { - "description": "content type of a repository to filter on (rpm)", - "in": "query", - "name": "content_type", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Repositories", - "tags": [ - "repositories" - ] - }, - "post": { - "description": "This operation enables creating custom repositories based on user preferences.", - "operationId": "createRepository", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryResponse" - } - } - }, - "description": "Created", - "headers": { - "Location": { - "description": "resource URL", - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Create Repository", - "tags": [ - "repositories" - ] - } - }, - "/repositories/bulk_create/": { - "post": { - "description": "This enables creating multiple repositories in a single API. If a user encounters any error, none of the repositories will be created. The applicable error message will be returned.", - "operationId": "bulkCreateRepositories", - "requestBody": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.RepositoryRequest" - }, - "type": "array" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.RepositoryResponse" - }, - "type": "array" - } - } - }, - "description": "Created", - "headers": { - "Location": { - "description": "resource URL", - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Bulk create repositories", - "tags": [ - "repositories" - ] - } - }, - "/repositories/bulk_delete/": { - "post": { - "description": "This enables deleting multiple repositories.", - "operationId": "bulkDeleteRepositories", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.UUIDListRequest" - } - } - }, - "description": "Identifiers of the repositories", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "204": { - "description": "Repositories were successfully deleted" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Bulk delete repositories", - "tags": [ - "repositories" - ] - } - }, - "/repositories/bulk_export/": { - "post": { - "description": "Export multiple repositories.", - "operationId": "bulkExportRepositories", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryExportRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.RepositoryExportResponse" - }, - "type": "array" - } - } - }, - "description": "Created", - "headers": { - "Location": { - "description": "resource URL", - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Bulk export repositories", - "tags": [ - "repositories" - ] - } - }, - "/repositories/bulk_import/": { - "post": { - "description": "Import multiple repositories.", - "operationId": "bulkImportRepositories", - "requestBody": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.RepositoryRequest" - }, - "type": "array" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.RepositoryImportResponse" - }, - "type": "array" - } - } - }, - "description": "Created", - "headers": { - "Location": { - "description": "resource URL", - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Bulk import repositories", - "tags": [ - "repositories" - ] - } - }, - "/repositories/uploads/": { - "post": { - "description": "Create an upload.", - "operationId": "createUpload", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.CreateUploadRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.UploadResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Create an upload", - "tags": [ - "repositories" - ] - } - }, - "/repositories/uploads/{upload_uuid}/upload_chunk/": { - "post": { - "description": "Upload a file chunk.", - "operationId": "uploadChunk", - "parameters": [ - { - "description": "Upload ID.", - "in": "path", - "name": "upload_uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Content-Range header", - "in": "header", - "name": "Content-Range", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "multipart/form-data": { - "schema": { - "properties": { - "file": { - "description": "file chunk", - "format": "binary", - "type": "string", - "x-formData-name": "file" - }, - "sha256": { - "description": "sha256", - "type": "string", - "x-formData-name": "sha256" - } - }, - "required": [ - "file", - "sha256" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.UploadResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Upload a file chunk", - "tags": [ - "repositories" - ] - } - }, - "/repositories/{repo_uuid}/snapshots/bulk_delete/": { - "post": { - "description": "This enables deleting specified snapshots from a repository.", - "operationId": "bulkDeleteSnapshots", - "parameters": [ - { - "description": "Repository UUID.", - "in": "path", - "name": "repo_uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/api.UUIDListRequest" - } - } - }, - "description": "Identifiers of the snapshots", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "204": { - "description": "Snapshots were successfully deleted" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Bulk delete a snapshots", - "tags": [ - "snapshots" - ] - } - }, - "/repositories/{repo_uuid}/snapshots/{snapshot_uuid}": { - "delete": { - "description": "This enables deleting a specific snapshot.", - "operationId": "deleteSnapshot", - "parameters": [ - { - "description": "Repository UUID.", - "in": "path", - "name": "repo_uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Snapshot UUID.", - "in": "path", - "name": "snapshot_uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Snapshot was successfully deleted" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Delete a snapshot", - "tags": [ - "snapshots" - ] - } - }, - "/repositories/{uuid}": { - "delete": { - "description": "This enables deleting a specific repository.", - "operationId": "deleteRepository", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Repository was successfully deleted" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Delete a repository", - "tags": [ - "repositories" - ] - }, - "get": { - "description": "Get repository information.", - "operationId": "getRepository", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get Repository", - "tags": [ - "repositories" - ] - }, - "patch": { - "description": "Partially update a repository.", - "operationId": "partialUpdateRepository", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryUpdateRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Partial Update Repository", - "tags": [ - "repositories" - ] - }, - "put": { - "description": "Update a repository.", - "operationId": "fullUpdateRepository", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Update Repository", - "tags": [ - "repositories" - ] - } - }, - "/repositories/{uuid}/add_uploads/": { - "post": { - "description": "Add uploads to a repository.", - "operationId": "add_upload", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.AddUploadsRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Add uploads to a repository", - "tags": [ - "repositories" - ] - } - }, - "/repositories/{uuid}/config.repo": { - "get": { - "operationId": "getLatestRepoConfigurationFile", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "text/plain": { - "schema": { - "type": "string" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get latest configuration file for a repository", - "tags": [ - "repositories" - ] - } - }, - "/repositories/{uuid}/environments": { - "get": { - "description": "List environments in a repository.", - "operationId": "listRepositoriesEnvironments", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response based on specific repository parameters. Sort criteria can include `id`, `name`, and `description`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryEnvironmentCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Repositories Environments", - "tags": [ - "environments" - ] - } - }, - "/repositories/{uuid}/introspect/": { - "post": { - "description": "Check for repository updates.", - "operationId": "introspect", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "*/*": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryIntrospectRequest" - } - } - }, - "description": "request body", - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "introspect a repository", - "tags": [ - "repositories" - ] - } - }, - "/repositories/{uuid}/package_groups": { - "get": { - "description": "List package groups in a repository.", - "operationId": "listRepositoriesPackageGroups", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response based on specific repository parameters. Sort criteria can include `id`, `name`, `description`, and `package_list`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryPackageGroupCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Repositories Package Groups", - "tags": [ - "packagegroups" - ] - } - }, - "/repositories/{uuid}/rpms": { - "get": { - "description": "List RPMs in a repository.", - "operationId": "listRepositoriesRpms", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response based on specific repository parameters. Sort criteria can include `name`, `url`, `status`, and `package_count`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryRpmCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Repositories RPMs", - "tags": [ - "rpms" - ] - } - }, - "/repositories/{uuid}/snapshot/": { - "post": { - "description": "Snapshot a repository if not already snapshotting", - "operationId": "createSnapshot", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "snapshot a repository", - "tags": [ - "repositories" - ] - } - }, - "/repositories/{uuid}/snapshots/": { - "get": { - "description": "List snapshots of a repository.", - "operationId": "listSnapshotsForRepo", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response data based on specific repository parameters. Sort criteria can include `created_at`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List snapshots of a repository", - "tags": [ - "snapshots" - ] - } - }, - "/repository_gpg_key/{uuid}": { - "get": { - "description": "Get the GPG key file for a repository.", - "operationId": "getGpgKeyFile", - "parameters": [ - { - "description": "Repository ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "text/plain": { - "schema": { - "type": "string" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get the GPG key file for a repository", - "tags": [ - "repositories" - ] - } - }, - "/repository_parameters/": { - "get": { - "description": "List repository parameters.", - "operationId": "listRepositoryParameters", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.RepositoryParameterResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - } - }, - "summary": "List Repository Parameters", - "tags": [ - "repositories" - ] - } - }, - "/repository_parameters/external_gpg_key/": { - "post": { - "description": "Fetch a gpgkey from a remote repo.", - "operationId": "fetchGpgKey", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.FetchGPGKeyRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.FetchGPGKeyResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Fetch gpgkey from URL", - "tags": [ - "gpgKey" - ] - } - }, - "/repository_parameters/validate/": { - "post": { - "description": "This validates the parameters before creating a repository. It provides a way to ensure the accuracy and validity of the provided parameters, including a check for the presence of remote yum metadata. Users can perform necessary checks before proceeding with the creation of a repository.", - "operationId": "validateRepositoryParameters", - "requestBody": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.RepositoryValidationRequest" - }, - "type": "array" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.RepositoryValidationResponse" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Validate parameters prior to creating a repository", - "tags": [ - "repositories" - ] - } - }, - "/rpms/names": { - "post": { - "description": "This enables users to search for RPMs (Red Hat Package Manager) in a given list of repositories.", - "operationId": "searchRpm", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.ContentUnitSearchRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchRpmResponse" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Search RPMs", - "tags": [ - "rpms" - ] - } - }, - "/rpms/presence": { - "post": { - "deprecated": true, - "description": "This enables users to detect presence of RPMs (Red Hat Package Manager) in a given list of repositories.", - "operationId": "detectRpm", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.DetectRpmsRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.DetectRpmsResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Detect RPMs presence", - "tags": [ - "rpms" - ] - } - }, - "/snapshots/environments/names": { - "post": { - "description": "This enables users to search for environments in a given list of snapshots.", - "operationId": "searchSnapshotEnvironments", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotSearchRpmRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchEnvironmentResponse" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Search environments within snapshots", - "tags": [ - "environments" - ] - } - }, - "/snapshots/for_date/": { - "post": { - "description": "Get nearest snapshot by date for a list of repositories.", - "operationId": "listSnapshotsByDate", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.ListSnapshotByDateRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.ListSnapshotByDateResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get nearest snapshot by date for a list of repositories.", - "tags": [ - "snapshots" - ] - } - }, - "/snapshots/module_streams/search": { - "post": { - "description": "List modules and their streams for snapshots", - "operationId": "searchSnapshotModuleStreams", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SearchSnapshotModuleStreamsRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchModuleStreams" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List modules and their streams for snapshots", - "tags": [ - "module_streams" - ] - } - }, - "/snapshots/package_groups/names": { - "post": { - "description": "This enables users to search for package groups in a given list of snapshots.", - "operationId": "searchSnapshotPackageGroups", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotSearchRpmRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchPackageGroupResponse" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Search package groups within snapshots", - "tags": [ - "packagegroups" - ] - } - }, - "/snapshots/rpms/names": { - "post": { - "description": "This enables users to search for RPMs (Red Hat Package Manager) in a given list of snapshots.", - "operationId": "searchSnapshotRpms", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotSearchRpmRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/api.SearchRpmResponse" - }, - "type": "array" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Search RPMs within snapshots", - "tags": [ - "rpms" - ] - } - }, - "/snapshots/{snapshot_uuid}/config.repo": { - "get": { - "operationId": "getRepoConfigurationFile", - "parameters": [ - { - "description": "Identifier of the snapshot", - "in": "path", - "name": "snapshot_uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "text/plain": { - "schema": { - "type": "string" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get configuration file of a repository", - "tags": [ - "repositories" - ] - } - }, - "/snapshots/{uuid}/errata": { - "get": { - "description": "List errata in a repository snapshot.", - "operationId": "listSnapshotErrata", - "parameters": [ - { - "description": "Snapshot ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of types to control api response. Type can include `security`, `enhancement`, `bugfix`, and `other`.", - "in": "query", - "name": "type", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of severities to control api response. Severity can include `Important`, `Critical`, `Moderate`, `Low`, and `Unknown`.", - "in": "query", - "name": "severity", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response based on specific parameters. Sort criteria can include `issued_date`, `updated_date`, `type`, and `severity`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotErrataCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Snapshot Errata", - "tags": [ - "rpms" - ] - } - }, - "/snapshots/{uuid}/rpms": { - "get": { - "description": "List RPMs in a repository snapshot.", - "operationId": "listSnapshotRpms", - "parameters": [ - { - "description": "Snapshot ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotRpmCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Snapshot RPMs", - "tags": [ - "rpms" - ] - } - }, - "/tasks/": { - "get": { - "description": "Get the list of tasks.", - "operationId": "listTasks", - "parameters": [ - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "A comma separated list of statuses to control response. Statuses can include `running`, `completed`, `failed`.", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "Filter results based on a specific task types. Helps to narrow down the results to a specific type. Task types can be `snapshot` or `introspect`. ", - "in": "query", - "name": "type", - "schema": { - "type": "string" - } - }, - { - "description": "A unique identifier of a repository to filter the results.", - "in": "query", - "name": "repository_uuid", - "schema": { - "type": "string" - } - }, - { - "description": "A unique identifier of a template to filter the results.", - "in": "query", - "name": "template_uuid", - "schema": { - "type": "string" - } - }, - { - "description": "A flag to exclude tasks for the red hat org from the query.", - "in": "query", - "name": "exclude_red_hat_org", - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TaskInfoCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Tasks", - "tags": [ - "tasks" - ] - } - }, - "/tasks/{uuid}": { - "get": { - "description": "Get information about a specific task.", - "operationId": "getTask", - "parameters": [ - { - "description": "Task ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TaskInfoResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get Task", - "tags": [ - "tasks" - ] - } - }, - "/templates/": { - "get": { - "description": "This operation enables users to retrieve a list of templates.", - "operationId": "listTemplates", - "parameters": [ - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Filter templates by version.", - "in": "query", - "name": "version", - "schema": { - "type": "string" - } - }, - { - "description": "Filter templates by architecture.", - "in": "query", - "name": "arch", - "schema": { - "type": "string" - } - }, - { - "description": "Filter templates by name.", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "Filter templates by associated repositories using a comma separated list of repository UUIDs", - "in": "query", - "name": "repository_uuids", - "schema": { - "type": "string" - } - }, - { - "description": "Filter templates by associated snapshots using a comma separated list of snapshot UUIDs", - "in": "query", - "name": "snapshot_uuids", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response data based on specific parameters. Sort criteria can include `name`, `arch`, and `version`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Templates", - "tags": [ - "templates" - ] - }, - "post": { - "description": "This operation enables creating templates based on user preferences.", - "operationId": "createTemplate", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateResponse" - } - } - }, - "description": "Created", - "headers": { - "Location": { - "description": "resource URL", - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Create Template", - "tags": [ - "templates" - ] - } - }, - "/templates/{template_uuid}/config.repo": { - "get": { - "operationId": "getTemplateRepoConfigurationFile", - "parameters": [ - { - "description": "Identifier of the template", - "in": "path", - "name": "template_uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "text/plain": { - "schema": { - "type": "string" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get configuration file for all repositories in a template", - "tags": [ - "templates" - ] - } - }, - "/templates/{uuid}": { - "delete": { - "description": "This enables deleting a specific template.", - "operationId": "deleteTemplate", - "parameters": [ - { - "description": "Template ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Template was successfully deleted" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Delete a template", - "tags": [ - "templates" - ] - }, - "get": { - "description": "Get template information.", - "operationId": "getTemplate", - "parameters": [ - { - "description": "Template ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Get Template", - "tags": [ - "templates" - ] - }, - "patch": { - "description": "This operation enables updating some subset of attributes of a template", - "operationId": "partialUpdateTemplate", - "parameters": [ - { - "description": "Template ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateUpdateRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateResponse" - } - } - }, - "description": "Created", - "headers": { - "Location": { - "description": "resource URL", - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Update some attributes of a Template", - "tags": [ - "templates" - ] - }, - "put": { - "description": "This operation enables updating all attributes of a template", - "operationId": "fullUpdateTemplate", - "parameters": [ - { - "description": "Template ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateUpdateRequest" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.TemplateResponse" - } - } - }, - "description": "Created", - "headers": { - "Location": { - "description": "resource URL", - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "415": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unsupported Media Type" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Fully update all attributes of a Template", - "tags": [ - "templates" - ] - } - }, - "/templates/{uuid}/errata": { - "get": { - "description": "List errata in a content template.", - "operationId": "listTemplateErrata", - "parameters": [ - { - "description": "Template ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of types to control api response. Type can include `security`, `enhancement`, `bugfix`, and `other`.", - "in": "query", - "name": "type", - "schema": { - "type": "string" - } - }, - { - "description": "A comma separated list of severities to control api response. Severity can include `Important`, `Critical`, `Moderate`, `Low`, and `Unknown`.", - "in": "query", - "name": "severity", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response based on specific parameters. Sort criteria can include `issued_date`, `updated_date`, `type`, and `severity`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotErrataCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Template Errata", - "tags": [ - "templates" - ] - } - }, - "/templates/{uuid}/rpms": { - "get": { - "description": "List RPMs in a content template.", - "operationId": "listTemplateRpms", - "parameters": [ - { - "description": "Template ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Term to filter and retrieve items that match the specified search criteria. Search term can include name.", - "in": "query", - "name": "search", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotRpmCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List Template RPMs", - "tags": [ - "rpms" - ] - } - }, - "/templates/{uuid}/snapshots/": { - "get": { - "description": "List snapshots for a template.", - "operationId": "listSnapshotsForTemplate", - "parameters": [ - { - "description": "Template ID.", - "in": "path", - "name": "uuid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Search through snapshots by repository name.", - "in": "query", - "name": "repository_search", - "schema": { - "type": "string" - } - }, - { - "description": "Sort the response data based on specific snapshot parameters. Sort criteria can include `repository_name` or `created_at`.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "Starting point for retrieving a subset of results. Determines how many items to skip from the beginning of the result set. Default value:`0`.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "Number of items to include in response. Use it to control the number of items, particularly when dealing with large datasets. Default value: `100`.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/api.SnapshotCollectionResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Bad Request" - }, - "401": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Unauthorized" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.ErrorResponse" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "List snapshots for a template", - "tags": [ - "snapshots" - ] - } - } - }, - "servers": [ - { - "url": "https://console.redhat.com/api/content-sources/v1.0/" - } - ] -} \ No newline at end of file diff --git a/api/schema/edge.json b/api/schema/edge.json deleted file mode 100644 index 065837d9..00000000 --- a/api/schema/edge.json +++ /dev/null @@ -1,5919 +0,0 @@ -{ - "components": { - "schemas": { - "CheckThirdPartyRepoName": { - "properties": { - "data": { - "allOf": [ - { - "$ref": "#/components/schemas/CheckThirdPartyRepoNameData" - } - ], - "description": "The data of third party repository check name result" - } - }, - "type": "object" - }, - "CheckThirdPartyRepoNameData": { - "properties": { - "isValid": { - "description": "The indicator of third party repository name validity", - "example": false, - "type": "boolean" - } - }, - "type": "object" - }, - "Commit": { - "properties": { - "arch": { - "description": "The commit architecture", - "example": "x86_64", - "type": "string" - } - }, - "type": "object" - }, - "CustomPackages": { - "properties": { - "name": { - "description": "Name of custom packages", - "example": "cat", - "type": "string" - } - }, - "type": "object" - }, - "DeviceNotification": { - "properties": { - "application": { - "description": "application name", - "example": "edge-management", - "type": "string" - }, - "bundle": { - "description": "bundle name", - "example": "rhel", - "type": "string" - }, - "context": { - "description": "notification context payload data", - "example": "{\"CommitID\":\"31581\",\"UpdateID\":\"34916\"}", - "type": "string" - }, - "event_type": { - "description": "event type", - "example": "update-devices", - "type": "string" - }, - "events": { - "description": "notification events", - "items": { - "$ref": "#/components/schemas/EventNotification" - }, - "type": "array" - }, - "org_id": { - "description": "notification organization id", - "example": "11111111", - "type": "string" - }, - "recipients": { - "description": "notification recipients", - "items": { - "$ref": "#/components/schemas/RecipientNotification" - }, - "type": "array" - }, - "timestamp": { - "description": "notification timestamp", - "example": "2023-07-06T11:15:04Z", - "type": "string" - }, - "version": { - "description": "notification version", - "example": "v1.1.0", - "type": "string" - } - }, - "type": "object" - }, - "DevicesUpdate": { - "properties": { - "CommitID": { - "description": "Optional: The unique ID of the target commit", - "example": 1026, - "type": "integer" - }, - "DevicesUUID": { - "description": "List of devices uuids to update", - "example": [ - "b579a578-1a6f-48d5-8a45-21f2a656a5d4", - "1abb288d-6d88-4e2d-bdeb-fcc536be58ec" - ], - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "EventNotification": { - "properties": { - "payload": { - "description": "notification event payload", - "example": "{\"ID\":\"\"}", - "type": "string" - } - }, - "type": "object" - }, - "ImageResponse": { - "properties": { - "Account": { - "type": "string" - }, - "Commit": { - "$ref": "#/components/schemas/models.Commit" - }, - "CommitID": { - "type": "integer" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "CustomPackages": { - "items": { - "$ref": "#/components/schemas/models.Package" - }, - "type": "array" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "Description": { - "type": "string" - }, - "Distribution": { - "type": "string" - }, - "ID": { - "type": "integer" - }, - "ImageSetID": { - "description": "TODO: Wipe staging database and set to not nullable", - "type": "integer" - }, - "ImageType": { - "description": "TODO: Remove as soon as the frontend stops using", - "type": "string" - }, - "Installer": { - "$ref": "#/components/schemas/models.Installer" - }, - "InstallerID": { - "type": "integer" - }, - "Name": { - "type": "string" - }, - "OutputTypes": { - "items": { - "type": "string" - }, - "type": "array" - }, - "Packages": { - "items": { - "$ref": "#/components/schemas/models.Package" - }, - "type": "array" - }, - "Status": { - "type": "string" - }, - "SystemsRunning": { - "description": "only for forms", - "type": "integer" - }, - "ThirdPartyRepositories": { - "items": { - "$ref": "#/components/schemas/models.ThirdPartyRepo" - }, - "type": "array" - }, - "TotalPackages": { - "description": "only for forms", - "type": "integer" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "Version": { - "type": "integer" - }, - "activationKey": { - "type": "string" - }, - "org_id": { - "type": "string" - }, - "request_id": { - "description": "storing for logging reference on resume", - "type": "string" - } - }, - "type": "object" - }, - "ImageValidationRequest": { - "properties": { - "ID": { - "description": "the unique ID of the image", - "example": 1029, - "type": "integer" - } - }, - "type": "object" - }, - "ImageValidationResponse": { - "properties": { - "UpdateValid": { - "example": true, - "type": "boolean" - } - }, - "type": "object" - }, - "RecipientNotification": { - "properties": { - "ignore_user_preferences": { - "description": "notification recipient to ignore user preferences", - "example": false, - "type": "boolean" - }, - "only_admins": { - "description": "notification recipient for only admins", - "example": false, - "type": "boolean" - }, - "users": { - "description": "notification recipient users", - "example": [ - "user-id" - ], - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "ThirdPartyRepo": { - "properties": { - "Description": { - "description": "The description of the third party repository", - "example": "a repo for some utilities", - "type": "string" - }, - "ID": { - "description": "The unique ID of the third party repository", - "example": 1028, - "type": "integer" - }, - "Name": { - "description": "The name of the third party repository", - "example": "my_custom_repo", - "type": "string" - }, - "URL": { - "description": "The URL of the third party repository", - "example": "https://public.example.com/my_custom_repo", - "type": "string" - } - }, - "type": "object" - }, - "ThirdPartyRepoList": { - "properties": { - "count": { - "description": "The overall count of the stored third party repositories", - "example": 25, - "type": "integer" - }, - "data": { - "description": "The data list of the third party repositories", - "items": { - "$ref": "#/components/schemas/ThirdPartyRepo" - }, - "type": "array" - } - }, - "type": "object" - }, - "Update": { - "properties": { - "ChangesRefs": { - "description": "Whether this update is changing device ostree ref", - "example": false, - "type": "boolean" - }, - "Commit": { - "allOf": [ - { - "$ref": "#/components/schemas/models.UpdateCommitAPI" - } - ], - "description": "The device Update target commit" - }, - "Devices": { - "description": "The current devices to update", - "items": { - "$ref": "#/components/schemas/UpdateDevice" - }, - "type": "array" - }, - "DispatchRecords": { - "description": "The current update dispatcher records", - "items": { - "$ref": "#/components/schemas/UpdateDispatchRecord" - }, - "type": "array" - }, - "ID": { - "description": "The unique ID of device update", - "example": 1026, - "type": "integer" - }, - "OldCommits": { - "description": "The device alternate commits from current device commit to target commit", - "items": { - "$ref": "#/components/schemas/models.UpdateCommitAPI" - }, - "type": "array" - }, - "Repo": { - "allOf": [ - { - "$ref": "#/components/schemas/UpdateRepo" - } - ], - "description": "The current repository built from this update" - }, - "Status": { - "description": "the current devices update status", - "example": "BUILDING", - "type": "string" - } - }, - "type": "object" - }, - "UpdateDevice": { - "properties": { - "Connected": { - "description": "Is the device connected", - "example": true, - "type": "boolean" - }, - "CurrentHash": { - "description": "the current device loaded commit hash", - "example": "0bd8dfe9856aa5bb1683e85f123bfe7785d45fbdb6f10372ff2c80e703400446", - "type": "string" - }, - "ID": { - "description": "The unique ID of the device", - "example": 1096, - "type": "integer" - }, - "ImageID": { - "description": "The current related image ID", - "example": 10778, - "type": "integer" - }, - "Name": { - "description": "the device inventory name", - "example": "teat-host.example.com", - "type": "string" - }, - "RHCClientID": { - "description": "The device RHC client ID", - "example": "5f9ac7d3-2264-4dad-a5a0-39c91c071c8a", - "type": "string" - }, - "UUID": { - "description": "The device inventory uuid", - "example": "54880418-b7c2-402e-93e5-287e168de7a6", - "type": "string" - }, - "UpdateAvailable": { - "description": "Whether an update is available", - "example": true, - "type": "boolean" - } - }, - "type": "object" - }, - "UpdateDispatchRecord": { - "properties": { - "DeviceID": { - "description": "The unique ID of the device being updated", - "example": 12789, - "type": "integer" - }, - "ID": { - "description": "The unique ID of the DispatcherRecord", - "example": 1089, - "type": "integer" - }, - "PlaybookDispatcherID": { - "description": "The playbook dispatcher job id", - "example": "c84cfd11-745c-4ee3-b87d-057a96732415", - "type": "string" - }, - "PlaybookURL": { - "description": "The generated playbook url", - "example": "https://console.redhat.com/api/edge/v1/updates/1026/update-playbook.yml", - "type": "string" - }, - "Reason": { - "description": "In case of failure the error reason returned by the playbook-dispatcher service", - "example": "", - "type": "string" - }, - "Status": { - "description": "The status of device update", - "example": "BUILDING", - "type": "string" - } - }, - "type": "object" - }, - "UpdateRepo": { - "properties": { - "ID": { - "description": "The unique ID of the update repository", - "example": 53218, - "type": "integer" - }, - "RepoStatus": { - "description": "The status of the device update repository building", - "example": "SUCCESS", - "type": "string" - }, - "RepoURL": { - "description": "The url of the update ostree repository", - "example": "https://storage-host.example.com/53218/upd/53218/repo", - "type": "string" - } - }, - "type": "object" - }, - "errors.BadRequest": { - "properties": { - "Code": { - "type": "string" - }, - "Status": { - "type": "integer" - }, - "Title": { - "type": "string" - } - }, - "type": "object" - }, - "errors.InternalServerError": { - "properties": { - "Code": { - "type": "string" - }, - "Status": { - "type": "integer" - }, - "Title": { - "type": "string" - } - }, - "type": "object" - }, - "errors.NotFound": { - "properties": { - "Code": { - "type": "string" - }, - "Status": { - "type": "integer" - }, - "Title": { - "type": "string" - } - }, - "type": "object" - }, - "gorm.DeletedAt": { - "properties": { - "time": { - "type": "string" - }, - "valid": { - "description": "Valid is true if Time is not NULL", - "type": "boolean" - } - }, - "type": "object" - }, - "models.CheckGroupNameParamAPI": { - "properties": { - "Name": { - "description": "device group name", - "example": "my-device-group", - "type": "string" - } - }, - "type": "object" - }, - "models.Commit": { - "properties": { - "Account": { - "type": "string" - }, - "Arch": { - "type": "string" - }, - "BlueprintToml": { - "type": "string" - }, - "BuildDate": { - "type": "string" - }, - "BuildNumber": { - "type": "integer" - }, - "ChangesRefs": { - "type": "boolean" - }, - "ComposeJobID": { - "type": "string" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "ID": { - "type": "integer" - }, - "ImageBuildHash": { - "type": "string" - }, - "ImageBuildParentHash": { - "type": "string" - }, - "ImageBuildTarURL": { - "type": "string" - }, - "InstalledPackages": { - "items": { - "$ref": "#/components/schemas/models.InstalledPackage" - }, - "type": "array" - }, - "OSTreeCommit": { - "type": "string" - }, - "OSTreeParentCommit": { - "type": "string" - }, - "OSTreeParentRef": { - "type": "string" - }, - "OSTreeRef": { - "type": "string" - }, - "Repo": { - "$ref": "#/components/schemas/models.Repo" - }, - "RepoID": { - "type": "integer" - }, - "Status": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "external": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "org_id": { - "type": "string" - } - }, - "type": "object" - }, - "models.CreateDeviceGroupAPI": { - "properties": { - "DevicesAPI": { - "description": "Devices of group", - "items": { - "$ref": "#/components/schemas/models.DeviceForDeviceGroupAPI" - }, - "type": "array" - }, - "name": { - "description": "the device group name", - "example": "my-device-group", - "type": "string" - }, - "type": { - "description": "the device group type", - "example": "static", - "type": "string" - } - }, - "type": "object" - }, - "models.CreateImageAPI": { - "type": "object" - }, - "models.Device": { - "properties": { - "Account": { - "type": "string" - }, - "AvailableHash": { - "type": "string" - }, - "Connected": { - "type": "boolean" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "CurrentHash": { - "type": "string" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "DevicesGroups": { - "items": { - "$ref": "#/components/schemas/models.DeviceGroup" - }, - "type": "array" - }, - "ID": { - "type": "integer" - }, - "ImageID": { - "type": "integer" - }, - "LastSeen": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "Name": { - "type": "string" - }, - "RHCClientID": { - "type": "string" - }, - "UUID": { - "type": "string" - }, - "UpdateAvailable": { - "type": "boolean" - }, - "UpdateTransaction": { - "items": { - "$ref": "#/components/schemas/models.UpdateTransaction" - }, - "type": "array" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "group_name": { - "description": "the inventory group name", - "type": "string" - }, - "group_uuid": { - "description": "the inventory group id", - "type": "string" - }, - "org_id": { - "type": "string" - } - }, - "type": "object" - }, - "models.DeviceAPI": { - "properties": { - "AvailableHash": { - "description": "Hash that available", - "example": "true", - "type": "string" - }, - "Connected": { - "description": "If Device connect of not", - "example": true, - "type": "boolean" - }, - "CurrentHash": { - "type": "string" - }, - "ImageID": { - "description": "image id of device`", - "example": 12834, - "type": "integer" - }, - "Name": { - "description": "Name of device", - "example": "device_name", - "type": "string" - }, - "RHCClientID": { - "description": "RHC Client ID", - "type": "string" - }, - "UUID": { - "description": "UUID of edge device", - "example": "ba-93ba-49a3-b4ae-a6c8acdc4736", - "type": "string" - }, - "UpdateAvailable": { - "description": "If there is Update available", - "example": true, - "type": "boolean" - }, - "UpdateTransaction": { - "items": { - "$ref": "#/components/schemas/models.UpdateTransaction" - }, - "type": "array" - }, - "booted": { - "description": "Booted status is referring to the LastDeployment of this device", - "example": true, - "type": "boolean" - }, - "deviceName": { - "type": "string" - }, - "devicesGroups": { - "description": "device groups", - "items": { - "$ref": "#/components/schemas/models.DeviceGroupAPI" - }, - "type": "array" - }, - "lastSeen": { - "description": "Last datetime that device updated", - "type": "string" - } - }, - "type": "object" - }, - "models.DeviceDetailsAPI": { - "properties": { - "Device": { - "allOf": [ - { - "$ref": "#/components/schemas/models.EdgeDeviceAPI" - } - ], - "description": "Details of device like name, LastSeen and more" - }, - "DeviceUpdating": { - "description": "If there is update to device", - "example": true, - "type": "boolean" - }, - "DevicesGroups": { - "description": "Device's groups", - "items": { - "$ref": "#/components/schemas/models.DeviceGroupAPI" - }, - "type": "array" - }, - "ImageInfo": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageInfo" - } - ], - "description": "Information of device's image" - }, - "UpdateTransactions": { - "items": { - "$ref": "#/components/schemas/models.UpdateTransactionAPI" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.DeviceDetailsListAPI": { - "properties": { - "count": { - "description": "total number of device", - "example": 40, - "type": "integer" - }, - "data": { - "description": "List of Devices", - "items": { - "$ref": "#/components/schemas/models.DeviceDetailsAPI" - }, - "type": "array" - }, - "total": { - "description": "total number of device", - "example": 40, - "type": "integer" - } - }, - "type": "object" - }, - "models.DeviceForDeviceGroupAPI": { - "properties": { - "UUID": { - "description": "device uuid", - "example": "68485bb8-6427-40ad-8711-93b6a5b4deac", - "type": "string" - } - }, - "type": "object" - }, - "models.DeviceGroup": { - "properties": { - "Account": { - "type": "string" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "Devices": { - "items": { - "$ref": "#/components/schemas/models.Device" - }, - "type": "array" - }, - "ID": { - "type": "integer" - }, - "Name": { - "type": "string" - }, - "Type": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "ValidUpdate": { - "type": "boolean" - }, - "org_id": { - "type": "string" - }, - "uuid": { - "type": "string" - } - }, - "type": "object" - }, - "models.DeviceGroupAPI": { - "properties": { - "Devices": { - "description": "Devices that belong to the group", - "items": { - "$ref": "#/components/schemas/models.DeviceAPI" - }, - "type": "array" - }, - "Name": { - "description": "The device group name`", - "example": "device_group name", - "type": "string" - }, - "Type": { - "description": "The device group type``", - "example": "static", - "type": "string" - }, - "ValidUpdate": { - "description": "indicate if the update is valid", - "example": true, - "type": "boolean" - } - }, - "type": "object" - }, - "models.DeviceGroupViewAPI": { - "properties": { - "DeviceGroup": { - "allOf": [ - { - "$ref": "#/components/schemas/models.DeviceGroup" - } - ], - "description": "device group data" - }, - "DevicesView": { - "allOf": [ - { - "$ref": "#/components/schemas/models.DeviceGroupViewResponseAPI" - } - ], - "description": "device group detail" - } - }, - "type": "object" - }, - "models.DeviceGroupViewResponseAPI": { - "properties": { - "Devices": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageSetImagePackagesAPI" - } - ], - "description": "all devices in a group" - }, - "Total": { - "description": "count of devices", - "example": 10, - "type": "integer" - } - }, - "type": "object" - }, - "models.DeviceViewAPI": { - "properties": { - "DeviceGroups": { - "description": "Device's groups", - "items": { - "$ref": "#/components/schemas/models.DeviceGroupAPI" - }, - "type": "array" - }, - "DeviceID": { - "description": "ID of device", - "example": 1913277, - "type": "integer" - }, - "DeviceName": { - "description": "Name of device", - "example": "device_name", - "type": "string" - }, - "DeviceUUID": { - "description": "UUID of Device", - "example": "a-8bdf-a21accb24925", - "type": "string" - }, - "DispatcherReason": { - "description": "Reason of Dispatch", - "type": "string" - }, - "DispatcherStatus": { - "description": "Status of Dispatch", - "type": "string" - }, - "GroupName": { - "description": "the inventory group name", - "type": "string" - }, - "GroupUUID": { - "description": "the inventory group id", - "type": "string" - }, - "ImageID": { - "description": "ID of image", - "example": 323241, - "type": "integer" - }, - "ImageName": { - "description": "Name of image", - "example": "image_name", - "type": "string" - }, - "ImageSetID": { - "description": "ID of image set", - "example": 33341, - "type": "integer" - }, - "LastSeen": { - "allOf": [ - { - "$ref": "#/components/schemas/models.EdgeAPITime" - } - ], - "description": "Last datetime that device updated" - }, - "Status": { - "description": "Status of device", - "example": "SUCCESS", - "type": "string" - }, - "UpdateAvailable": { - "description": "indicate if there is update to device", - "example": true, - "type": "boolean" - } - }, - "type": "object" - }, - "models.DeviceViewListAPI": { - "properties": { - "devices": { - "description": "List of Devices", - "items": { - "$ref": "#/components/schemas/models.DeviceViewAPI" - }, - "type": "array" - }, - "enforce_edge_groups": { - "description": "Whether to enforce the edge groups usage", - "type": "boolean" - }, - "total": { - "description": "Total number of device", - "example": 40, - "type": "integer" - } - }, - "type": "object" - }, - "models.DeviceViewListResponseAPI": { - "properties": { - "count": { - "description": "The overall number of devices", - "example": 40, - "type": "integer" - }, - "data": { - "allOf": [ - { - "$ref": "#/components/schemas/models.DeviceViewListAPI" - } - ], - "description": "The devices view data" - } - }, - "type": "object" - }, - "models.DispatchRecord": { - "properties": { - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "Device": { - "$ref": "#/components/schemas/models.Device" - }, - "DeviceID": { - "type": "integer" - }, - "ID": { - "type": "integer" - }, - "PlaybookDispatcherID": { - "type": "string" - }, - "PlaybookURL": { - "type": "string" - }, - "Reason": { - "type": "string" - }, - "Status": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - } - }, - "type": "object" - }, - "models.DispatchRecordAPI": { - "properties": { - "Device": { - "$ref": "#/components/schemas/models.DeviceAPI" - }, - "DeviceID": { - "description": "ID of device", - "example": 1913277, - "type": "integer" - }, - "PlaybookDispatcherID": { - "type": "string" - }, - "PlaybookURL": { - "type": "string" - }, - "Reason": { - "type": "string" - }, - "Status": { - "description": "Status of device", - "example": "SUCCESS", - "type": "string" - } - }, - "type": "object" - }, - "models.EdgeAPITime": { - "properties": { - "time": { - "type": "string" - }, - "valid": { - "description": "Valid is true if Time is not NULL", - "type": "boolean" - } - }, - "type": "object" - }, - "models.EdgeDeviceAPI": { - "properties": { - "AvailableHash": { - "description": "Hash that available", - "example": "true", - "type": "string" - }, - "Connected": { - "description": "If Device connect of not", - "example": true, - "type": "boolean" - }, - "CurrentHash": { - "type": "string" - }, - "DevicesGroups": { - "description": "device groups", - "items": { - "$ref": "#/components/schemas/models.DeviceGroupAPI" - }, - "type": "array" - }, - "ImageID": { - "description": "image id of device", - "example": 12834, - "type": "integer" - }, - "LastSeen": { - "allOf": [ - { - "$ref": "#/components/schemas/models.EdgeAPITime" - } - ], - "description": "Last datetime that device updated" - }, - "Name": { - "description": "Name of Edge Device", - "type": "string" - }, - "RHCClientID": { - "description": "RHC Client ID", - "type": "string" - }, - "UUID": { - "description": "UUID of edge device", - "example": "ba-93ba-49a3-b4ae-a6c8acdc4736", - "type": "string" - }, - "UpdateAvailable": { - "description": "If there is update available", - "example": true, - "type": "boolean" - }, - "UpdateTransaction": { - "items": { - "$ref": "#/components/schemas/models.UpdateTransaction" - }, - "type": "array" - }, - "booted": { - "description": "Booted status is referring to the LastDeployment of this device", - "example": true, - "type": "boolean" - }, - "deviceName": { - "description": "The device name", - "example": "test_device_api_static", - "type": "string" - } - }, - "type": "object" - }, - "models.EnforceEdgeGroupsAPI": { - "properties": { - "enforce_edge_groups": { - "description": "whether to enforce edge groups usage", - "example": false, - "type": "boolean" - } - }, - "type": "object" - }, - "models.FilterByDevicesAPI": { - "properties": { - "devices_uuid": { - "description": "Devices UUID", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.Image": { - "properties": { - "Account": { - "type": "string" - }, - "Commit": { - "$ref": "#/components/schemas/models.Commit" - }, - "CommitID": { - "type": "integer" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "CustomPackages": { - "items": { - "$ref": "#/components/schemas/models.Package" - }, - "type": "array" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "Description": { - "type": "string" - }, - "Distribution": { - "type": "string" - }, - "ID": { - "type": "integer" - }, - "ImageSetID": { - "description": "TODO: Wipe staging database and set to not nullable", - "type": "integer" - }, - "ImageType": { - "description": "TODO: Remove as soon as the frontend stops using", - "type": "string" - }, - "Installer": { - "$ref": "#/components/schemas/models.Installer" - }, - "InstallerID": { - "type": "integer" - }, - "Name": { - "type": "string" - }, - "OutputTypes": { - "items": { - "type": "string" - }, - "type": "array" - }, - "Packages": { - "items": { - "$ref": "#/components/schemas/models.Package" - }, - "type": "array" - }, - "Status": { - "type": "string" - }, - "SystemsRunning": { - "description": "only for forms", - "type": "integer" - }, - "ThirdPartyRepositories": { - "items": { - "$ref": "#/components/schemas/models.ThirdPartyRepo" - }, - "type": "array" - }, - "TotalPackages": { - "description": "only for forms", - "type": "integer" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "Version": { - "type": "integer" - }, - "activationKey": { - "type": "string" - }, - "org_id": { - "type": "string" - }, - "request_id": { - "description": "storing for logging reference on resume", - "type": "string" - } - }, - "type": "object" - }, - "models.ImageDetailAPI": { - "properties": { - "additional_packages": { - "description": "Number of additional packages", - "example": 3, - "type": "integer" - }, - "image": { - "$ref": "#/components/schemas/models.Image" - }, - "packages": { - "description": "Number of packages", - "example": 3, - "type": "integer" - }, - "update_added": { - "description": "Number of added update", - "example": 3, - "type": "integer" - }, - "update_removed": { - "description": "Number of removed update", - "example": 2, - "type": "integer" - }, - "update_updated": { - "description": "Number of updated update", - "example": 3, - "type": "integer" - } - }, - "type": "object" - }, - "models.ImageInfo": { - "properties": { - "Count": { - "type": "integer" - }, - "Image": { - "$ref": "#/components/schemas/models.Image" - }, - "RollbackImage": { - "$ref": "#/components/schemas/models.Image" - }, - "UpdatesAvailable": { - "items": { - "$ref": "#/components/schemas/models.ImageUpdateAvailable" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.ImageSetAPI": { - "properties": { - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "ID": { - "type": "integer" - }, - "Images": { - "description": "images of image set", - "items": { - "$ref": "#/components/schemas/models.Image" - }, - "type": "array" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "name": { - "description": "the image set name", - "example": "my-edge-image", - "type": "string" - }, - "version": { - "description": "the image set version", - "example": 1, - "type": "integer" - } - }, - "type": "object" - }, - "models.ImageSetDetailsResponseAPI": { - "properties": { - "Count": { - "description": "count of image-sets", - "example": 10, - "type": "integer" - }, - "Data": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageSetImagePackagesAPI" - } - ], - "description": "all data of image-sets" - } - }, - "type": "object" - }, - "models.ImageSetDevicesAPI": { - "properties": { - "Count": { - "description": "count of image-set's devices", - "example": 10, - "type": "integer" - }, - "Data": { - "description": "Data of image set's devices", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.ImageSetIDViewAPI": { - "properties": { - "ImageBuildIsoURL": { - "description": "The image-set latest available image ISO", - "example": "/api/edge/v1/storage/isos/432", - "type": "string" - }, - "ImageSet": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageSetAPI" - } - ], - "description": "image set data" - }, - "LastImageDetails": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageDetailAPI" - } - ], - "description": "The image-set latest image details" - } - }, - "type": "object" - }, - "models.ImageSetImageIDViewAPI": { - "properties": { - "ImageBuildIsoURL": { - "description": "The image-set latest available image ISO", - "example": "/api/edge/v1/storage/isos/432", - "type": "string" - }, - "ImageDetails": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageDetailAPI" - } - ], - "description": "the requested image details" - }, - "ImageSet": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageSetAPI" - } - ], - "description": "image set data" - } - }, - "type": "object" - }, - "models.ImageSetImagePackagesAPI": { - "properties": { - "image_build_iso_url": { - "description": "The image-set latest available image ISO", - "example": "/api/edge/v1/storage/isos/432", - "type": "string" - }, - "image_set": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageSetAPI" - } - ], - "description": "image set data" - }, - "images": { - "description": "image detail", - "items": { - "$ref": "#/components/schemas/models.ImageDetailAPI" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.ImageSetInstallerURLAPI": { - "properties": { - "image_build_iso_url": { - "description": "The image-set latest available image ISO", - "example": "/api/edge/v1/storage/isos/432", - "type": "string" - }, - "image_set": { - "allOf": [ - { - "$ref": "#/components/schemas/models.ImageSetAPI" - } - ], - "description": "image set data" - } - }, - "type": "object" - }, - "models.ImageSetView": { - "properties": { - "Distribution": { - "type": "string" - }, - "ID": { - "type": "integer" - }, - "ImageBuildIsoURL": { - "type": "string" - }, - "ImageID": { - "type": "integer" - }, - "Name": { - "type": "string" - }, - "OutputTypes": { - "items": { - "type": "string" - }, - "type": "array" - }, - "Status": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "Version": { - "type": "integer" - } - }, - "type": "object" - }, - "models.ImageSetsResponseAPI": { - "properties": { - "Count": { - "description": "count of image-sets", - "example": 10, - "type": "integer" - }, - "Data": { - "description": "all data of image-sets", - "items": { - "$ref": "#/components/schemas/models.ImageSetInstallerURLAPI" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.ImageSetsViewResponseAPI": { - "properties": { - "count": { - "description": "count of image-sets", - "example": 10, - "type": "integer" - }, - "data": { - "description": "data of image set view", - "items": { - "$ref": "#/components/schemas/models.ImageSetView" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.ImageUpdateAvailable": { - "properties": { - "CanUpdate": { - "type": "boolean" - }, - "Image": { - "$ref": "#/components/schemas/models.Image" - }, - "PackageDiff": { - "$ref": "#/components/schemas/models.PackageDiff" - } - }, - "type": "object" - }, - "models.ImageView": { - "properties": { - "CommitCheckSum": { - "type": "string" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "ID": { - "type": "integer" - }, - "ImageBuildIsoURL": { - "type": "string" - }, - "ImageType": { - "type": "string" - }, - "Name": { - "type": "string" - }, - "OutputTypes": { - "items": { - "type": "string" - }, - "type": "array" - }, - "Status": { - "type": "string" - }, - "Version": { - "type": "integer" - } - }, - "type": "object" - }, - "models.ImagesViewDataAPI": { - "properties": { - "count": { - "description": "total number of image view data", - "example": 100, - "type": "integer" - }, - "data": { - "items": { - "$ref": "#/components/schemas/models.ImageView" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.InstalledPackage": { - "properties": { - "ID": { - "type": "integer" - }, - "arch": { - "type": "string" - }, - "commits": { - "items": { - "$ref": "#/components/schemas/models.Commit" - }, - "type": "array" - }, - "epoch": { - "type": "string" - }, - "name": { - "type": "string" - }, - "release": { - "type": "string" - }, - "sigmd5": { - "type": "string" - }, - "signature": { - "type": "string" - }, - "type": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "type": "object" - }, - "models.Installer": { - "properties": { - "Account": { - "type": "string" - }, - "Checksum": { - "type": "string" - }, - "ComposeJobID": { - "type": "string" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "ID": { - "type": "integer" - }, - "ImageBuildISOURL": { - "type": "string" - }, - "SshKey": { - "type": "string" - }, - "Status": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "Username": { - "type": "string" - }, - "org_id": { - "type": "string" - } - }, - "type": "object" - }, - "models.InventoryGroupDevicesUpdateInfoResponseAPI": { - "properties": { - "devices_count": { - "description": "the overall count of all devices that belongs to inventory group", - "example": 25, - "type": "integer" - }, - "group_uuid": { - "description": "the inventory group id", - "example": "b579a578-1a6f-48d5-8a45-21f2a656a5d4", - "type": "string" - }, - "image_set_id": { - "description": "the image set id common to all inventory group devices", - "example": 1024, - "type": "integer" - }, - "image_sets_count": { - "description": "how much image set ids the inventory group devices belongs to", - "example": 1, - "type": "integer" - }, - "update_devices_uuids": { - "description": "the list of devices uuids that belongs to inventory group that are available to update", - "example": [ - "b579a578-1a6f-48d5-8a45-21f2a656a5d4", - "1abb288d-6d88-4e2d-bdeb-fcc536be58ec" - ], - "items": { - "type": "string" - }, - "type": "array" - }, - "update_valid": { - "description": "whether the inventory group devices update is valid", - "example": true, - "type": "boolean" - } - }, - "type": "object" - }, - "models.Package": { - "properties": { - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "ID": { - "type": "integer" - }, - "Name": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - } - }, - "type": "object" - }, - "models.PackageDiff": { - "properties": { - "Added": { - "items": { - "$ref": "#/components/schemas/models.InstalledPackage" - }, - "type": "array" - }, - "Removed": { - "items": { - "$ref": "#/components/schemas/models.InstalledPackage" - }, - "type": "array" - }, - "Upgraded": { - "items": { - "$ref": "#/components/schemas/models.InstalledPackage" - }, - "type": "array" - } - }, - "type": "object" - }, - "models.PostDeviceForDeviceGroupAPI": { - "properties": { - "Name": { - "description": "device name", - "example": "localhost", - "type": "string" - }, - "UUID": { - "description": "device uuid", - "example": "68485bb8-6427-40ad-8711-93b6a5b4deac", - "type": "string" - } - }, - "type": "object" - }, - "models.PutGroupNameParamAPI": { - "properties": { - "Name": { - "description": "device group name", - "example": "my-device-group", - "type": "string" - }, - "Type": { - "description": "device group type", - "example": "static", - "type": "string" - } - }, - "type": "object" - }, - "models.Repo": { - "properties": { - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "ID": { - "type": "integer" - }, - "RepoStatus": { - "description": "AWS repo upload status", - "type": "string" - }, - "RepoURL": { - "description": "AWS repo URL", - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "pulp_repo_id": { - "description": "Pulp Repo ID (used for updates)", - "type": "string" - }, - "pulp_repo_status": { - "description": "Status of Pulp repo import", - "type": "string" - }, - "pulp_repo_url": { - "description": "Distribution URL returned from Pulp", - "type": "string" - } - }, - "type": "object" - }, - "models.SuccessPlaceholderResponse": { - "type": "object" - }, - "models.ThirdPartyRepo": { - "properties": { - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "Description": { - "type": "string" - }, - "ID": { - "type": "integer" - }, - "Images": { - "items": { - "$ref": "#/components/schemas/models.Image" - }, - "type": "array" - }, - "Name": { - "type": "string" - }, - "URL": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "account": { - "type": "string" - }, - "distribution_arch": { - "type": "string" - }, - "distribution_version": { - "items": { - "type": "string" - }, - "type": "array" - }, - "gpg_key": { - "type": "string" - }, - "org_id": { - "type": "string" - }, - "package_count": { - "type": "integer" - }, - "uuid": { - "type": "string" - } - }, - "type": "object" - }, - "models.UpdateCommitAPI": { - "properties": { - "ID": { - "description": "The unique ID of the commit", - "example": 1056, - "type": "integer" - }, - "ImageBuildTarURL": { - "description": "The commit tar url", - "example": "https://storage-host.example.com/v2/99999999/tar/59794/tmp/repos/59794/repo.tar", - "type": "string" - }, - "OSTreeCommit": { - "description": "The ostree commit hash", - "example": "9bd8dfe9856aa5bb1683e85f123bfe7785d45fbdb6f10372ff2c80e703400999", - "type": "string" - }, - "OSTreeRef": { - "description": "The commit ostree ref", - "example": "rhel/9/x86_64/edge", - "type": "string" - } - }, - "type": "object" - }, - "models.UpdateTransaction": { - "properties": { - "Account": { - "type": "string" - }, - "ChangesRefs": { - "type": "boolean" - }, - "Commit": { - "$ref": "#/components/schemas/models.Commit" - }, - "CommitID": { - "type": "integer" - }, - "CreatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "DeletedAt": { - "$ref": "#/components/schemas/gorm.DeletedAt" - }, - "Devices": { - "items": { - "$ref": "#/components/schemas/models.Device" - }, - "type": "array" - }, - "DispatchRecords": { - "items": { - "$ref": "#/components/schemas/models.DispatchRecord" - }, - "type": "array" - }, - "ID": { - "type": "integer" - }, - "OldCommits": { - "items": { - "$ref": "#/components/schemas/models.Commit" - }, - "type": "array" - }, - "Repo": { - "$ref": "#/components/schemas/models.Repo" - }, - "RepoID": { - "type": "integer" - }, - "Status": { - "type": "string" - }, - "Tag": { - "type": "string" - }, - "UpdatedAt": { - "$ref": "#/components/schemas/models.EdgeAPITime" - }, - "org_id": { - "type": "string" - } - }, - "type": "object" - }, - "models.UpdateTransactionAPI": { - "properties": { - "ChangesRefs": { - "example": false, - "type": "boolean" - }, - "Commit": { - "$ref": "#/components/schemas/models.Commit" - }, - "CommitID": { - "description": "Commit ID of device", - "example": 1754, - "type": "integer" - }, - "Devices": { - "description": "List of Devices", - "items": { - "$ref": "#/components/schemas/models.DeviceAPI" - }, - "type": "array" - }, - "DispatchRecords": { - "items": { - "$ref": "#/components/schemas/models.DispatchRecordAPI" - }, - "type": "array" - }, - "OldCommits": { - "description": "Old Commit ID if the device has one", - "items": { - "$ref": "#/components/schemas/models.Commit" - }, - "type": "array" - }, - "Repo": { - "$ref": "#/components/schemas/models.Repo" - }, - "RepoID": { - "description": "Repo ID", - "example": 2256, - "type": "integer" - }, - "Status": { - "description": "Status of device", - "example": "SUCCESS", - "type": "string" - }, - "Tag": { - "description": "Tag og Device if device has one", - "example": "device_tag", - "type": "string" - } - }, - "type": "object" - } - } - }, - "info": { - "contact": {}, - "description": "API of the Edge Management application on [console.redhat.com](https://console.redhat.com)", - "license": { - "name": "MIT" - }, - "title": "Edge API", - "version": "1.0" - }, - "openapi": "3.0.3", - "paths": { - "/device-groups": { - "get": { - "description": "Returns device groups for an orgID", - "parameters": [ - { - "description": "Define sort fields: created_at, updated_at, name. To sort DESC use -", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by name", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "field: return number of image-set view until limit is reached. Default is 100.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of image-set view beginning at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceGroup" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Returns device groups for an orgID", - "tags": [ - "Device Groups" - ] - }, - "post": { - "description": "Creates a Device Group for an account.", - "operationId": "CreateDeviceGroup", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CreateDeviceGroupAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceGroupAPI" - } - } - }, - "description": "The created device groups" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Creates a Device Group for an account.", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/checkName/{name}": { - "get": { - "description": "Validates if a group name already exists", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CheckGroupNameParamAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Validates if a group name already exists", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/enforce-edge-groups": { - "get": { - "description": "Returns whether the edge groups is enforced for the current organization", - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.EnforceEdgeGroupsAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - } - }, - "summary": "Returns whether the edge groups is enforced for the current organization", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/{ID}": { - "delete": { - "description": "Deletes an existing device group", - "parameters": [ - { - "description": "A unique existing Device Group", - "in": "query", - "name": "required_param", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Deletes an existing device group", - "tags": [ - "Device Groups" - ] - }, - "get": { - "description": "Returns devices groups for group identified by ID", - "parameters": [ - { - "description": "device group ID", - "in": "query", - "name": "required_param", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceGroup" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Returns devices groups for group identified by ID", - "tags": [ - "Device Groups" - ] - }, - "put": { - "description": "Updates the existing device group", - "parameters": [ - { - "description": "An unique existing Device Group", - "in": "query", - "name": "required_param", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.PutGroupNameParamAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceGroup" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Updates the existing device group", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/{ID}/details": { - "get": { - "description": "Returns details for group identified by ID", - "parameters": [ - { - "description": "device group ID", - "in": "query", - "name": "required_param", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceGroup" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Returns details for group identified by ID", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/{ID}/devices": { - "delete": { - "description": "Deletes the requested devices from device-group", - "parameters": [ - { - "description": "Identifier of the DeviceGroup", - "in": "path", - "name": "DeviceGroupID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Deletes the requested devices from device-group", - "tags": [ - "Device Groups" - ] - }, - "post": { - "description": "Adds devices to device group", - "parameters": [ - { - "description": "An unique existing Device Group", - "in": "query", - "name": "required_param", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.PostDeviceForDeviceGroupAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Adds devices to device group", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/{ID}/devices/{deviceID}": { - "delete": { - "description": "Deletes the requested device from the device-group", - "parameters": [ - { - "description": "Identifier of the Device Group", - "in": "path", - "name": "DeviceGroupId", - "required": true, - "schema": { - "type": "integer" - } - }, - { - "description": "Identifier of the Device in a Device Group", - "in": "path", - "name": "DeviceId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Deletes the requested device from the device-group", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/{ID}/updateDevices": { - "post": { - "description": "Updates all devices that belong to a group", - "parameters": [ - { - "description": "Identifier of the DeviceGroup", - "in": "query", - "name": "required_param", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Updates all devices that belong to a group", - "tags": [ - "Device Groups" - ] - } - }, - "/device-groups/{ID}/view": { - "get": { - "description": "Returns device groups view for group identified by ID", - "parameters": [ - { - "description": "device group ID", - "in": "query", - "name": "required_param", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceGroupViewAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Returns device groups view for group identified by ID", - "tags": [ - "Device Groups" - ] - } - }, - "/devices": { - "get": { - "description": "Get combined system data from Edge API and Inventory API", - "operationId": "GetDevices", - "parameters": [ - { - "description": "field: maximum devices per page", - "in": "query", - "name": "per_page", - "schema": { - "type": "integer" - } - }, - { - "description": "field: which page to query from", - "in": "query", - "name": "page", - "schema": { - "type": "integer" - } - }, - { - "description": "field: order by display_name, updated or operating_system", - "in": "query", - "name": "order_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: choose to order ASC or DESC when order_by is being used", - "in": "query", - "name": "order_how", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by hostname_or_id", - "in": "query", - "name": "hostname_or_id", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceDetailsListAPI" - } - } - }, - "description": "OK" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Get All Devices.", - "tags": [ - "Devices (Systems)" - ] - } - }, - "/devices/devicesview": { - "get": { - "description": "Return all data of Devices.", - "operationId": "GetDevicesView", - "parameters": [ - { - "description": "fields: name, uuid, update_available, image_id. To sort DESC use - before the fields.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by name", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by update_available", - "in": "query", - "name": "update_available", - "schema": { - "type": "boolean" - } - }, - { - "description": "field: filter by uuid", - "in": "query", - "name": "uuid", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by creation date", - "in": "query", - "name": "created_at", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by image id", - "in": "query", - "name": "image_id", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of devices until limit is reached. Default is 100.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of devices begining at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceViewListResponseAPI" - } - } - }, - "description": "OK" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return all data of Devices.", - "tags": [ - "Devices (Systems)" - ] - }, - "post": { - "description": "Return all data of Devices.", - "operationId": "GetDevicesViewWithinDevices", - "parameters": [ - { - "description": "fields: name, uuid, update_available, image_id. To sort DESC use - before the fields.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by name", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by update_available", - "in": "query", - "name": "update_available", - "schema": { - "type": "boolean" - } - }, - { - "description": "field: filter by uuid", - "in": "query", - "name": "uuid", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by creation date", - "in": "query", - "name": "created_at", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by image id", - "in": "query", - "name": "image_id", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of devices until limit is reached. Default is 100.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of devices beginning at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.FilterByDevicesAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceViewListResponseAPI" - } - } - }, - "description": "OK" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return all data of Devices.", - "tags": [ - "Devices (Systems)" - ] - } - }, - "/devices/{DeviceUUID}": { - "get": { - "description": "Get a device by UUID.", - "operationId": "GetDevice", - "parameters": [ - { - "description": "DeviceUUID", - "in": "path", - "name": "DeviceUUID", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.DeviceDetailsAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The device was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Get a device by UUID.", - "tags": [ - "Devices (Systems)" - ] - } - }, - "/image-sets": { - "get": { - "description": "Return the list of image sets.", - "operationId": "ListAllImageSets", - "parameters": [ - { - "description": "Define sort fields: created_at, updated_at, name. To sort DESC use -", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by name", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by status", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "field: return number of image-set view until limit is reached. Default is 100.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of image-set view beginning at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImageSetsResponseAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The Image Set was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return the list of image sets.", - "tags": [ - "Image-Sets" - ] - } - }, - "/image-sets/view": { - "get": { - "description": "Return the list of image set view.", - "parameters": [ - { - "description": "Define sort fields: created_at, updated_at, name. To sort DESC use -", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by name", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by status", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by id", - "in": "query", - "name": "id", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of image-set view until limit is reached. Default is 30.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of image-set view beginning at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImageSetsViewResponseAPI" - } - } - }, - "description": "OK" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return the list of image set view.", - "tags": [ - "Image-Sets" - ] - } - }, - "/image-sets/view/{imageSetID}/versions/{imageID}": { - "get": { - "description": "Return the image-set images view list.", - "operationId": "GetImageSetImageView", - "parameters": [ - { - "description": "the image set id", - "in": "path", - "name": "imageSetID", - "required": true, - "schema": { - "type": "integer" - } - }, - { - "description": "the image id", - "in": "path", - "name": "imageID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImageSetImageIDViewAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The Image-Set or Image was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return the image-set images view list.", - "tags": [ - "Image-Sets" - ] - } - }, - "/image-sets/view/{image_set_id}": { - "get": { - "description": "Return the image-set description view.", - "operationId": "GetImageSetViewByID", - "parameters": [ - { - "description": "the image-set id", - "in": "path", - "name": "image_set_id", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImageSetIDViewAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The Image-Set was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return the image-set description view.", - "tags": [ - "Image-Sets" - ] - } - }, - "/image-sets/view/{image_set_id}/versions": { - "get": { - "description": "Return the image-set images view list.", - "operationId": "GetAllImageSetImagesView", - "parameters": [ - { - "description": "the image-set id", - "in": "path", - "name": "image_set_id", - "required": true, - "schema": { - "type": "integer" - } - }, - { - "description": "Define sort fields: created_at, version, To sort DESC use -", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by status", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by version", - "in": "query", - "name": "version", - "schema": { - "type": "string" - } - }, - { - "description": "field: return number of images until limit is reached. Default is 100.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of images beginning at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImagesViewDataAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The Image-Set was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return the image-set images view list.", - "tags": [ - "Image-Sets" - ] - } - }, - "/image-sets/{imageSetID}": { - "delete": { - "description": "Delete Image Set", - "operationId": "DeleteImageSet", - "parameters": [ - { - "description": "Identifier of the ImageSet", - "in": "path", - "name": "imageSetID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImageSetAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "image-set was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Delete Image Set", - "tags": [ - "Image-Sets" - ] - } - }, - "/image-sets/{imageSetID}/": { - "get": { - "description": "Get image set by ID", - "operationId": "GetImageSetsByID", - "parameters": [ - { - "description": "Image Set ID", - "in": "path", - "name": "imageSetID", - "required": true, - "schema": { - "type": "integer" - } - }, - { - "description": "Define sort fields: created_at, updated_at, name. To sort DESC use -", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by name", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by status", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by version", - "in": "query", - "name": "version", - "schema": { - "type": "string" - } - }, - { - "description": "field: return number of image-set view until limit is reached. Default is 100.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of image-set view beginning at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImageSetDetailsResponseAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "image-set was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Get an image-set", - "tags": [ - "Image-Sets" - ] - } - }, - "/image-sets/{imageSetID}/devices": { - "get": { - "description": "Return device ids for an image set.", - "operationId": "GetImageSetsDevicesByID", - "parameters": [ - { - "description": "Identifier of the ImageSet", - "in": "path", - "name": "ImageSetId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.ImageSetDevicesAPI" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The Image Set ID was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return device ids for an image set.", - "tags": [ - "Image-Sets" - ] - } - }, - "/images": { - "get": { - "description": "This is a placeholder description", - "operationId": "GetAllImages", - "parameters": [ - { - "description": "Return number of images until limit is reached.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "Return number of images beginning at the offset", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "created_at, distribution, name,status. To sort DESC use -before the fields", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "Filter by name.", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "Filter by status.", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "Filter by distribution.", - "in": "query", - "name": "distribution", - "schema": { - "type": "string" - } - }, - { - "description": "Filter by creation date.", - "in": "query", - "name": "created_at", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": " The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - }, - "post": { - "description": "Create an ostree commit and/or installer ISO", - "operationId": "createImage", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CreateImageAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ImageResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Create an image", - "tags": [ - "Images" - ] - } - }, - "/images/checkImageName": { - "post": { - "description": "Create an updated ostree commit", - "operationId": "CheckImageName", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CreateImageAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Update an image", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}": { - "delete": { - "description": "This is a placeholder description", - "operationId": "DeleteImage", - "parameters": [ - { - "description": "Identifier of the ImageSet", - "in": "path", - "name": "imageSetID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - }, - "get": { - "description": "This is a placeholder description", - "operationId": "GetImageByID", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/details": { - "get": { - "description": "This is a placeholder description", - "operationId": "GetImageDetailsByID", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/installer": { - "post": { - "description": "This is a placeholder description", - "operationId": "CreateInstallerForImage", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CreateImageAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/kickstart": { - "post": { - "description": "This is a placeholder description", - "operationId": "CreateKickStartForImage", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CreateImageAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/metadata": { - "get": { - "description": "This is a placeholder description", - "operationId": "GetMetadataForImage", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/repo": { - "get": { - "description": "This is a placeholder description", - "operationId": "GetRepoForImage", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/retry": { - "post": { - "description": "Create an updated ostree commit", - "operationId": "RetryCreateImage", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CreateImageAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "Retry is being processed" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Retries building an image from scratch", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/status": { - "get": { - "description": "This is a placeholder description", - "operationId": "GetImageStatusByID", - "parameters": [ - { - "description": "Image Identifier", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/images/{imageId}/update": { - "post": { - "description": "Create an updated ostree commit", - "operationId": "CreateImageUpdate", - "parameters": [ - { - "description": "Image ID", - "in": "path", - "name": "imageId", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.CreateImageAPI" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Update an image", - "tags": [ - "Images" - ] - } - }, - "/images/{ostreeCommitHash}/info": { - "get": { - "description": "This is a placeholder description", - "operationId": "GetImageByOstree", - "parameters": [ - { - "description": "Ostree Commit Hash", - "in": "path", - "name": "ostreeCommitHash", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.SuccessPlaceholderResponse" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Placeholder summary", - "tags": [ - "Images" - ] - } - }, - "/inventory-groups/{GroupUUID}/update-info": { - "get": { - "description": "Gets the inventory group update info", - "operationId": "GetInventoryGroupDevicesUpdateInfo", - "parameters": [ - { - "description": "a unique uuid to identify the inventory group", - "in": "path", - "name": "GroupUUID", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.InventoryGroupDevicesUpdateInfoResponseAPI" - } - } - }, - "description": "The requested inventory group update info" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The requested inventory group was not found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error" - } - }, - "summary": "Gets the inventory group update info", - "tags": [ - "Updates (Systems)" - ] - } - }, - "/storage/images-repos/{imageID}/content/{repoFilePath}": { - "get": { - "description": "Redirect request to a signed and valid url for an image commit repository from the path content", - "operationId": "RedirectSignedImageCommitRepository", - "parameters": [ - { - "description": "Id to identify Image", - "in": "path", - "name": "imageID", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "path to file repository", - "in": "path", - "name": "repoFilePath", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "303": { - "content": { - "application/json": { - "schema": { - "type": "string" - } - } - }, - "description": "See Other" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "redirect to a signed url of an image commit repository path content", - "tags": [ - "Storage" - ] - } - }, - "/storage/images-repos/{imageID}/{repoFilePath}": { - "get": { - "description": "Bring the content for a image commit in a repository path", - "operationId": "ContentImageCommitRepositoryPath", - "parameters": [ - { - "description": "Id to identify Image", - "in": "path", - "name": "imageID", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "path to file repository", - "in": "path", - "name": "repoFilePath", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/octet-stream": { - "schema": { - "type": "string" - } - } - }, - "description": "Stream object from file content" - }, - "400": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "return the content of an image commit repository path", - "tags": [ - "Storage" - ] - } - }, - "/storage/isos/{installerID}/": { - "get": { - "description": "This method will redirect request to a signed installer iso url", - "operationId": "RedirectSignedInstaller", - "parameters": [ - { - "description": "Installer ID", - "in": "path", - "name": "installerID", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "303": { - "content": { - "application/octet-stream": { - "schema": { - "type": "string" - } - } - }, - "description": "URL to redirect" - }, - "400": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request send couln't be processed." - }, - "404": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "installer not found." - }, - "500": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Redirect to a signed installer", - "tags": [ - "Storage" - ] - } - }, - "/storage/update-repos/{updateTransactionID}/content/{repoFilePath}": { - "get": { - "description": "Method will redirect to asigned url of an update-transaction based on repository content", - "operationId": "RedirectUpdateTransactionRepositoryPath", - "parameters": [ - { - "description": "id for update transaction id", - "in": "path", - "name": "updateTransactionID", - "required": true, - "schema": { - "type": "integer" - } - }, - { - "description": "path to repository to be checked", - "in": "path", - "name": "repoFilePath", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "303": { - "content": { - "application/octet-stream": { - "schema": { - "type": "string" - } - } - }, - "description": "URL signed to be redirect" - }, - "400": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "redirect to a signed url of an update-transaction repository path content", - "tags": [ - "Storage" - ] - } - }, - "/storage/update-repos/{updateTransactionID}/{repoFilePath}": { - "get": { - "description": "Request will get access to content of an update-transaction file based on the path", - "operationId": "RedirectUpdateTransactionRepositoryContent", - "parameters": [ - { - "description": "Update Transaction Id", - "in": "path", - "name": "updateTransactionID", - "required": true, - "schema": { - "type": "integer" - } - }, - { - "description": "path for repository file", - "in": "path", - "name": "repoFilePath", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/octet-stream": { - "schema": { - "type": "string" - } - } - }, - "description": "Stream object from file content" - }, - "400": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "Bad Request" - }, - "404": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "Not Found" - }, - "500": { - "content": { - "application/octet-stream": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "Internal Server Error" - } - }, - "summary": "Return the content od an update-transaction repository path", - "tags": [ - "Storage" - ] - } - }, - "/thirdpartyrepo": { - "get": { - "description": "Lists all Third Party Repository for an account.", - "operationId": "GetAllThirdPartyRepo", - "parameters": [ - { - "description": "fields: created_at, name, updated_at. To sort DESC use - before the fields.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by name", - "in": "query", - "name": "name", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by creation date", - "in": "query", - "name": "created_at", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by update date", - "in": "query", - "name": "updated_at", - "schema": { - "type": "string" - } - }, - { - "description": "field: return number of repositories until limit is reached.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return number of repositories beginning at the offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ThirdPartyRepoList" - } - } - }, - "description": "The list of third party repositories response" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Lists all Third Party Repository for an account.", - "tags": [ - "Third Party Repo" - ] - }, - "post": { - "description": "Create Third Party Repository for an account.", - "operationId": "CreateThirdPartyRepo", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ThirdPartyRepo" - } - } - }, - "description": "the third party repository to create", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ThirdPartyRepo" - } - } - }, - "description": "The created third party repository" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Create Third Party Repository for an account.", - "tags": [ - "Third Party Repo" - ] - } - }, - "/thirdpartyrepo/checkName/{name}": { - "get": { - "description": "Checks to see if a ThirdParty repo Name exists.", - "operationId": "CheckThirdPartyRepoName", - "parameters": [ - { - "description": "ThirdParty repo Name", - "in": "path", - "name": "name", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CheckThirdPartyRepoName" - } - } - }, - "description": "The third party repository name check result" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Checks to see if a ThirdParty repo Name exists.", - "tags": [ - "Third Party Repo" - ] - } - }, - "/thirdpartyrepo/{ID}": { - "delete": { - "description": "Delete third party repository using id.", - "operationId": "DeleteThirdPartyRepoByID", - "parameters": [ - { - "description": "An unique existing third party repository id.", - "in": "query", - "name": "ID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ThirdPartyRepo" - } - } - }, - "description": "The deleted third party repository." - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The third party repository was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Delete third party repository using id.", - "tags": [ - "Third Party Repo" - ] - }, - "get": { - "description": "Get third party repository by id.", - "operationId": "GetThirdPartyRepoByID", - "parameters": [ - { - "description": "An unique existing third party repository id.", - "in": "query", - "name": "ID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ThirdPartyRepo" - } - } - }, - "description": "The requested third party repository." - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The third party repository was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Get third party repository by id.", - "tags": [ - "Third Party Repo" - ] - }, - "put": { - "description": "Creates an Update for third party repository", - "operationId": "CreateThirdPartyRepoUpdate", - "parameters": [ - { - "description": "An unique existing third party repository id.", - "in": "query", - "name": "ID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ThirdPartyRepo" - } - } - }, - "description": "The third party repository update data", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ThirdPartyRepo" - } - } - }, - "description": "The updated third party repository." - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The third party repository was not found." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Creates an Update for third party repository", - "tags": [ - "Third Party Repo" - ] - } - }, - "/updates": { - "get": { - "description": "Gets all device updates", - "operationId": "ListUpdates", - "parameters": [ - { - "description": "field: return number of updates until limit is reached. Default is 30.", - "in": "query", - "name": "limit", - "schema": { - "type": "integer" - } - }, - { - "description": "field: return updates beginning at the given offset.", - "in": "query", - "name": "offset", - "schema": { - "type": "integer" - } - }, - { - "description": "fields: created_at, updated_at. To sort DESC use - before the fields.", - "in": "query", - "name": "sort_by", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by status", - "in": "query", - "name": "status", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by creation date", - "in": "query", - "name": "created_at", - "schema": { - "type": "string" - } - }, - { - "description": "field: filter by update date", - "in": "query", - "name": "updated_at", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/Update" - }, - "type": "array" - } - } - }, - "description": "List of devices updates" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Gets all device updates", - "tags": [ - "Updates (Systems)" - ] - }, - "post": { - "description": "Executes a device update", - "operationId": "UpdateDevice", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DevicesUpdate" - } - } - }, - "description": "devices uuids to update and optional target commit id", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Update" - } - } - }, - "description": "The created device update" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error" - } - }, - "summary": "Executes a device update", - "tags": [ - "Updates (Systems)" - ] - } - }, - "/updates/device/{DeviceUUID}/updates": { - "get": { - "description": "Return list of available updates for a device.", - "operationId": "GetUpdateAvailableForDevice", - "parameters": [ - { - "description": "DeviceUUID", - "in": "path", - "name": "DeviceUUID", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "query the latest or all updates", - "in": "query", - "name": "latest", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/models.Image" - } - } - }, - "description": "OK" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "Return list of available updates for a device.", - "tags": [ - "Devices (Systems)" - ] - } - }, - "/updates/validate": { - "post": { - "description": "Validate if the images selection could be updated", - "operationId": "PostValidateUpdate", - "requestBody": { - "content": { - "application/json": { - "schema": { - "items": { - "$ref": "#/components/schemas/ImageValidationRequest" - }, - "type": "array" - } - } - }, - "description": "request body", - "required": true, - "x-originalParamName": "body" - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ImageValidationResponse" - } - } - }, - "description": "the validation result" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error" - } - }, - "summary": "Validate if the images selection could be updated", - "tags": [ - "Updates (Systems)" - ] - } - }, - "/updates/{updateID}": { - "get": { - "description": "Gets a single requested update.", - "operationId": "GetUpdate", - "parameters": [ - { - "description": "a unique ID to identify the update", - "in": "path", - "name": "updateID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Update" - } - } - }, - "description": "The requested update" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The requested update was not found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error" - } - }, - "summary": "Gets a single requested update", - "tags": [ - "Updates (Systems)" - ] - } - }, - "/updates/{updateID}/notify": { - "get": { - "description": "Send a notification for a device update", - "operationId": "SendNotificationForDevice", - "parameters": [ - { - "description": "a unique ID to identify the update", - "in": "path", - "name": "updateID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeviceNotification" - } - } - }, - "description": "The notification payload" - }, - "400": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed" - }, - "404": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "The requested update was not found" - }, - "500": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error" - } - }, - "summary": "Send a notification for a device update", - "tags": [ - "Updates (Systems)" - ] - } - }, - "/updates/{updateID}/update-playbook.yml": { - "get": { - "description": "returns the update transaction playbook used for system update", - "operationId": "GetUpdatePlaybook", - "parameters": [ - { - "description": "a unique ID to identify the update the playbook belongs to", - "in": "path", - "name": "updateID", - "required": true, - "schema": { - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "text/plain": { - "schema": { - "type": "string" - } - } - }, - "description": "the playbook file content for an update" - }, - "400": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.BadRequest" - } - } - }, - "description": "The request sent couldn't be processed." - }, - "404": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.NotFound" - } - } - }, - "description": "the device update was not found" - }, - "500": { - "content": { - "text/plain": { - "schema": { - "$ref": "#/components/schemas/errors.InternalServerError" - } - } - }, - "description": "There was an internal server error." - } - }, - "summary": "returns the playbook yaml file for a system update", - "tags": [ - "Updates (Systems)" - ] - } - } - } -} \ No newline at end of file diff --git a/api/schema/imageBuilder.yaml b/api/schema/imageBuilder.yaml deleted file mode 100644 index 7e3985ed..00000000 --- a/api/schema/imageBuilder.yaml +++ /dev/null @@ -1,2277 +0,0 @@ ---- -openapi: 3.0.1 -info: - version: "1.0" - title: Image-builder service - description: Service that relays image build requests - license: - name: Apache 2.0 - url: https://www.apache.org/licenses/LICENSE-2.0.html - -servers: - - url: "/api/image-builder/v1" - - url: "/api/image-builder/v1.0" - -paths: - /version: - get: - summary: get the service version - description: "get the service version" - operationId: getVersion - tags: - - meta - responses: - '200': - description: a service version - content: - application/json: - schema: - $ref: '#/components/schemas/Version' - /ready: - get: - summary: return the readiness - operationId: getReadiness - tags: - - meta - responses: - '200': - description: readiness - content: - application/json: - schema: - $ref: '#/components/schemas/Readiness' - /openapi.json: - get: - summary: get the openapi json specification - operationId: getOpenapiJson - tags: - - meta - - noAuth - responses: - '200': - description: returns this document - content: - application/json: - schema: - type: object - /distributions: - get: - summary: get the distributions available to this user - operationId: getDistributions - tags: - - distribution - responses: - '200': - description: | - A list of distributions this user has access to. Some distributions are restricted, so - this list might not correspond to the Distributions (enum) schema for a given user. - content: - application/json: - schema: - $ref: '#/components/schemas/DistributionsResponse' - /architectures/{distribution}: - get: - summary: get the architectures and their image types available for a given distribution - parameters: - - in: path - name: distribution - schema: - $ref: '#/components/schemas/Distributions' - required: true - description: distribution for which to look up available architectures - example: 'rhel-84' - operationId: getArchitectures - tags: - - distribution - - architecture - responses: - '200': - description: a list of available architectures and their associated image types - content: - application/json: - schema: - $ref: '#/components/schemas/Architectures' - '403': - description: user is not allowed to build or query this distribution - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /blueprints: - get: - summary: get a collection of blueprints - description: "get a collection of blueprints, returns just the latest version of each blueprint" - operationId: getBlueprints - tags: - - blueprint - parameters: - - in: query - name: name - required: false - schema: - type: string - description: fetch blueprint with specific name - - in: query - name: search - required: false - schema: - type: string - description: search for blueprints by name or description - - in: query - name: limit - schema: - type: integer - default: 100 - minimum: 1 - maximum: 100 - description: max amount of blueprints, default 100 - - in: query - name: offset - schema: - type: integer - default: 0 - minimum: 0 - description: blueprint page offset, default 0 - responses: - '200': - description: a list of blueprints - content: - application/json: - schema: - $ref: '#/components/schemas/BlueprintsResponse' - post: - summary: create blueprint - description: "create blueprint" - operationId: createBlueprint - tags: - - blueprint - requestBody: - required: true - description: details of blueprint - content: - application/json: - schema: - $ref: "#/components/schemas/CreateBlueprintRequest" - responses: - '201': - description: blueprint was saved - content: - application/json: - schema: - $ref: '#/components/schemas/CreateBlueprintResponse' - '422': - description: blueprint is malformed - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - '403': - description: user is not allowed to create blueprints - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /blueprints/{id}: - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: UUID of a blueprint - put: - summary: update blueprint - description: "update blueprint" - operationId: updateBlueprint - tags: - - blueprint - requestBody: - required: true - description: details of blueprint - content: - application/json: - schema: - $ref: "#/components/schemas/CreateBlueprintRequest" - responses: - '200': - description: blueprint was updated - content: - application/json: - schema: - $ref: '#/components/schemas/CreateBlueprintResponse' - '404': - description: blueprint was not found - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - get: - summary: get detail of a blueprint - description: "get a blueprint detail" - operationId: getBlueprint - tags: - - blueprint - parameters: - - in: query - name: version - schema: - type: integer - description: | - Filter by a specific version of the Blueprint we want to fetch. - Omit or pass -1 to fetch latest version. - responses: - '200': - description: detail of a blueprint - content: - application/json: - schema: - $ref: '#/components/schemas/BlueprintResponse' - '404': - description: blueprint was not found - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - delete: - summary: delete a blueprint - description: | - Deletes all versions of Blueprint, the compose will still count towards quota. - operationId: deleteBlueprint - tags: - - blueprint - responses: - '204': - description: Successfully deleted - '404': - description: Blueprint to delete was not found - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /blueprints/{id}/export: - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: UUID of a blueprint - get: - summary: export a blueprint - description: "export a blueprint" - operationId: exportBlueprint - tags: - - blueprint - responses: - '200': - description: detail of a blueprint - content: - application/json: - schema: - $ref: '#/components/schemas/BlueprintExportResponse' - '404': - description: blueprint was not found - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /blueprints/{id}/compose: - post: - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: UUID of a blueprint - summary: create new compose from blueprint - description: "create new compose from blueprint, optionally specifying the target image types to build" - operationId: composeBlueprint - tags: - - blueprint - requestBody: - required: false - description: "list of target image types that the user wants to build for this compose" - content: - application/json: - schema: - type: object - properties: - image_types: - type: array - items: - $ref: "#/components/schemas/ImageTypes" - example: ["azure", "aws"] - responses: - '201': - description: compose was created - content: - application/json: - schema: - type: array - items: - $ref: '#/components/schemas/ComposeResponse' - '403': - description: user is not allowed to compose from blueprints - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /blueprints/{id}/composes: - get: - summary: get composes associated with a blueprint - description: "get a collection of composes associated to a blueprint, allows for filtering by version" - operationId: getBlueprintComposes - tags: - - blueprint - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: UUID of a blueprint - - in: query - name: blueprint_version - schema: - type: integer - description: | - Filter by a specific version of the Blueprint we want to fetch composes for. - Pass special value -1 to fetch composes for latest version of the Blueprint. - - in: query - name: limit - schema: - type: integer - default: 100 - minimum: 1 - maximum: 100 - description: max amount of composes, default 100 - - in: query - name: offset - schema: - type: integer - default: 0 - minimum: 0 - description: composes page offset, default 0 - - in: query - name: ignoreImageTypes - required: false - schema: - type: array - items: - $ref: '#/components/schemas/ImageTypes' - example: ['rhel-edge-installer', 'rhel-edge-commit', ...] - description: | - Filter the composes on image type. The filter is optional and can be specified multiple times. - responses: - '200': - description: a list of composes - content: - application/json: - schema: - $ref: '#/components/schemas/ComposesResponse' - '404': - description: blueprint was not found - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /composes: - get: - summary: get a collection of previous compose requests for the logged in user - operationId: getComposes - tags: - - compose - parameters: - - in: query - name: limit - schema: - type: integer - default: 100 - minimum: 1 - maximum: 100 - description: max amount of composes, default 100 - - in: query - name: offset - schema: - type: integer - default: 0 - minimum: 0 - description: composes page offset, default 0 - - in: query - name: ignoreImageTypes - required: false - schema: - type: array - items: - $ref: '#/components/schemas/ImageTypes' - example: ['rhel-edge-installer', 'rhel-edge-commit', ...] - description: | - Filter the composes on image type. The filter is optional and can be specified multiple times. - responses: - '200': - description: a list of composes - content: - application/json: - schema: - $ref: '#/components/schemas/ComposesResponse' - /composes/{composeId}: - parameters: - - in: path - name: composeId - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: Id of compose - get: - summary: get status of an image compose - description: "status of an image compose" - operationId: getComposeStatus - tags: - - compose - responses: - '200': - description: compose status - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeStatus' - delete: - summary: delete a compose - description: | - Deletes a compose, the compose will still count towards quota. - operationId: deleteCompose - responses: - 200: - description: OK - /composes/{composeId}/metadata: - get: - summary: get metadata of an image compose - parameters: - - in: path - name: composeId - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: Id of compose metadata to get - description: "metadata for an image compose" - operationId: getComposeMetadata - tags: - - compose - responses: - '200': - description: compose metadata - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeMetadata' - /composes/{composeId}/clone: - post: - summary: clone a compose - description: | - Clones a compose. Only composes with the 'aws' image type currently support cloning. - parameters: - - in: path - name: composeId - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: Id of compose to clone - operationId: cloneCompose - tags: - - compose - requestBody: - required: true - description: details of the new clone - content: - application/json: - schema: - $ref: "#/components/schemas/CloneRequest" - responses: - '201': - description: cloning has started - content: - application/json: - schema: - $ref: "#/components/schemas/CloneResponse" - /composes/{composeId}/clones: - get: - summary: get clones of a compose - parameters: - - in: path - name: composeId - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: Id of compose to get the clones of - - in: query - name: limit - schema: - type: integer - default: 100 - minimum: 1 - maximum: 100 - description: max amount of clones, default 100 - - in: query - name: offset - schema: - type: integer - default: 0 - minimum: 0 - description: clones page offset, default 0 - description: | - Returns a list of all the clones which were started for a compose - operationId: getComposeClones - tags: - - compose - responses: - '200': - description: compose clones - content: - application/json: - schema: - $ref: '#/components/schemas/ClonesResponse' - /clones/{id}: - get: - summary: get status of a compose clone - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: Id of clone status to get - description: status of a clone - operationId: getCloneStatus - tags: - - compose - responses: - '200': - description: clone status - content: - application/json: - schema: - $ref: '#/components/schemas/CloneStatusResponse' - /compose: - post: - summary: compose image - description: "compose image" - operationId: composeImage - tags: - - compose - requestBody: - required: true - description: details of image to be composed - content: - application/json: - schema: - $ref: "#/components/schemas/ComposeRequest" - responses: - '201': - description: compose has started - content: - application/json: - schema: - $ref: '#/components/schemas/ComposeResponse' - '400': - description: the compose request is malformed - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - '403': - description: user is not allowed to build this distribution - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /packages: - get: - parameters: - - in: query - name: distribution - required: true - schema: - $ref: '#/components/schemas/Distributions' - description: distribution to look up packages for - - in: query - name: architecture - required: true - schema: - type: string - enum: ['x86_64', 'aarch64'] - description: architecture to look up packages for - - in: query - name: search - required: true - schema: - type: string - description: packages to look for - - in: query - name: limit - schema: - type: integer - default: 100 - minimum: 1 - maximum: 100 - description: max amount of packages, default 100 - - in: query - name: offset - schema: - type: integer - default: 0 - minimum: 0 - description: packages page offset, default 0 - operationId: getPackages - tags: - - package - responses: - '200': - description: a list of packages - content: - application/json: - schema: - $ref: '#/components/schemas/PackagesResponse' - '403': - description: user is not allowed to build or query this distribution - content: - application/json: - schema: - $ref: '#/components/schemas/HTTPErrorList' - /oscap/{distribution}/profiles: - parameters: - - in: path - name: distribution - schema: - $ref: '#/components/schemas/Distributions' - required: true - get: - summary: get the available profiles for a given distribution. This is a temporary endpoint meant to be removed soon. - operationId: getOscapProfiles - tags: - - oscap - responses: - '200': - description: | - A list of profiles configurable for this distribution. - content: - application/json: - schema: - $ref: '#/components/schemas/DistributionProfileResponse' - /oscap/{distribution}/{profile}/customizations: - parameters: - - in: path - name: distribution - schema: - $ref: '#/components/schemas/Distributions' - required: true - - in: path - name: profile - schema: - $ref: '#/components/schemas/DistributionProfileItem' - required: true - description: Name of the profile to retrieve customizations from - get: - summary: get the customizations for a given distribution and profile. This is a temporary endpoint meant to be removed soon. - operationId: getOscapCustomizations - tags: - - oscap - responses: - '200': - description: | - A customizations array updated with the needed elements. - content: - application/json: - schema: - $ref: '#/components/schemas/Customizations' - /oscap/{policy}/{distribution}/policy_customizations: - parameters: - - in: path - name: policy - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - - in: path - name: distribution - schema: - $ref: '#/components/schemas/Distributions' - required: true - get: - summary: get the customizations for a compliance policy - operationId: getOscapCustomizationsForPolicy - tags: - - oscap - responses: - '200': - description: | - A customizations array updated with the needed elements. - content: - application/json: - schema: - $ref: '#/components/schemas/Customizations' - /experimental/recommendations: - post: - summary: List recommended packages. - description: "Returns a list of recommended packages for given list of packages." - operationId: recommendPackage - tags: - - recommendations - requestBody: - content: - application/json: - schema: - "$ref": "#/components/schemas/RecommendPackageRequest" - required: true - responses: - '200': - description: Return the recommended packages. - content: - application/json: - schema: - $ref: "#/components/schemas/RecommendationsResponse" - /experimental/blueprints/{id}/fixup: - parameters: - - in: path - name: id - schema: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - required: true - description: UUID of a blueprint - post: - summary: Apply linter fixes to blueprint - operationId: fixupBlueprint - description: | - Apply fixes which should fix any lint errors in the blueprint. - responses: - 200: - description: successful update - 404: - description: blueprint was not found - -components: - schemas: - HTTPError: - required: - - title - - detail - properties: - title: - type: string - detail: - type: string - HTTPErrorList: - required: - - errors - properties: - errors: - type: array - items: - $ref: '#/components/schemas/HTTPError' - Version: - required: - - version - properties: - version: - type: string - build_commit: - type: string - build_time: - type: string - Readiness: - type: object - required: - - readiness - properties: - readiness: - type: string - ListResponseMeta: - type: object - required: - - count - properties: - count: - type: integer - ListResponseLinks: - type: object - required: - - first - - last - properties: - first: - type: string - last: - type: string - DistributionsResponse: - type: array - description: | - List of distributions this user is allowed to build. - items: - $ref: '#/components/schemas/DistributionItem' - DistributionItem: - type: object - required: - - name - - description - properties: - description: - type: string - example: 'Red Hat Enterprise Linux (RHEL) 8.4' - name: - type: string - example: 'rhel-84' - Architectures: - type: array - items: - $ref: '#/components/schemas/ArchitectureItem' - ArchitectureItem: - type: object - required: - - arch - - image_types - - repositories - properties: - arch: - type: string - example: 'x86_64' - image_types: - type: array - items: - type: string - example: 'qcow2' - repositories: - type: array - items: - $ref: '#/components/schemas/Repository' - description: Base repositories for the given distribution and architecture. - ComposeStatus: - required: - - image_status - - request - properties: - image_status: - $ref: '#/components/schemas/ImageStatus' - request: - $ref: "#/components/schemas/ComposeRequest" - ImageStatus: - required: - - status - properties: - status: - type: string - enum: ['success', 'failure', 'pending', 'building', 'uploading', 'registering'] - example: 'success' - upload_status: - $ref: '#/components/schemas/UploadStatus' - error: - $ref: '#/components/schemas/ComposeStatusError' - ComposeStatusError: - required: - - id - - reason - properties: - id: - type: integer - reason: - type: string - details: {} - CloneStatusResponse: - required: - - compose_id - allOf: - - type: object - properties: - compose_id: - type: string - format: uuid - - $ref: '#/components/schemas/UploadStatus' - UploadStatus: - required: - - status - - type - - options - properties: - status: - type: string - enum: ['success', 'failure', 'pending', 'running'] - type: - $ref: '#/components/schemas/UploadTypes' - options: - oneOf: - - $ref: '#/components/schemas/AWSUploadStatus' - - $ref: '#/components/schemas/AWSS3UploadStatus' - - $ref: '#/components/schemas/GCPUploadStatus' - - $ref: '#/components/schemas/AzureUploadStatus' - - $ref: '#/components/schemas/OCIUploadStatus' - AWSUploadStatus: - type: object - required: - - ami - - region - properties: - ami: - type: string - example: 'ami-0c830793775595d4b' - region: - type: string - example: 'eu-west-1' - AWSS3UploadStatus: - type: object - required: - - url - properties: - url: - type: string - GCPUploadStatus: - type: object - required: - - project_id - - image_name - properties: - project_id: - type: string - example: 'ascendant-braid-303513' - image_name: - type: string - example: 'my-image' - AzureUploadStatus: - type: object - required: - - image_name - properties: - image_name: - type: string - example: 'my-image' - OCIUploadStatus: - type: object - required: - - url - properties: - url: - type: string - ComposeRequest: - type: object - additionalProperties: false - required: - - distribution - - image_requests - properties: - distribution: - $ref: '#/components/schemas/Distributions' - image_name: - type: string - example: "MyImageName" - maxLength: 100 - image_description: - type: string - example: "MyImageDescription" - maxLength: 250 - client_id: - $ref: '#/components/schemas/ClientId' - image_requests: - type: array - minItems: 1 - maxItems: 1 - items: - $ref: '#/components/schemas/ImageRequest' - uniqueItems: true - description: | - Array of exactly one image request. Having more image requests in one compose is currently not supported. - customizations: - $ref: '#/components/schemas/Customizations' - CreateBlueprintRequest: - type: object - additionalProperties: false - required: - - name - - distribution - - image_requests - - customizations - properties: - name: - type: string - example: "My Blueprint" - maxLength: 100 - description: - type: string - example: "My blueprint description" - maxLength: 250 - distribution: - $ref: '#/components/schemas/Distributions' - image_requests: - type: array - minItems: 1 - items: - $ref: '#/components/schemas/ImageRequest' - uniqueItems: true - description: | - Array of image requests. Having more image requests in a single blueprint is currently not supported. - customizations: - $ref: '#/components/schemas/Customizations' - metadata: - $ref: '#/components/schemas/BlueprintMetadata' - CreateBlueprintResponse: - required: - - id - properties: - id: - type: string - format: uuid - BlueprintsResponse: - required: - - meta - - links - - data - properties: - meta: - $ref: '#/components/schemas/ListResponseMeta' - links: - $ref: '#/components/schemas/ListResponseLinks' - data: - type: array - items: - $ref: '#/components/schemas/BlueprintItem' - BlueprintItem: - required: - - id - - version - - name - - description - - last_modified_at - properties: - id: - type: string - format: uuid - version: - type: integer - name: - type: string - description: - type: string - last_modified_at: - type: string - BlueprintResponse: - required: - - id - - name - - description - - lint - - distribution - - image_requests - - customizations - properties: - id: - type: string - format: uuid - name: - type: string - description: - type: string - lint: - $ref: "#/components/schemas/BlueprintLint" - distribution: - $ref: '#/components/schemas/Distributions' - image_requests: - type: array - minItems: 1 - items: - $ref: '#/components/schemas/ImageRequest' - uniqueItems: true - description: | - Array of image requests. Having more image requests in a single blueprint is currently not supported. - customizations: - $ref: '#/components/schemas/Customizations' - BlueprintExportResponse: - required: - - name - - description - - distribution - - customizations - - metadata - properties: - name: - type: string - description: - type: string - distribution: - $ref: '#/components/schemas/Distributions' - customizations: - $ref: '#/components/schemas/Customizations' - metadata: - $ref: '#/components/schemas/BlueprintMetadata' - content_sources: - type: array - items: - type: object - additionalProperties: true - description: | - List of custom repositories including all the repository details needed in order - to recreate the repositories. - snapshot_date: - type: string - description: | - Importing the snapshot date will not yet be supported. It is exported for informative reasons. - The format is YYYY-MM-DD. - BlueprintMetadata: - required: - - parent_id - - exported_at - - is_on_prem - properties: - parent_id: - type: string - format: uuid - nullable: true - exported_at: - type: string - is_on_prem: - type: boolean - default: false - BlueprintLint: - required: - - errors - description: | - Linting errors in the current blueprint, these might need to be resolved before the - blueprint can be used to build images again. - properties: - errors: - type: array - items: - $ref: '#/components/schemas/BlueprintLintItem' - BlueprintLintItem: - type: object - required: - - name - - description - properties: - name: - type: string - example: Compliance - description: - type: string - example: package a required by policy is not present - Distributions: - type: string - description: | - List of all distributions that image builder supports. A user might not have access to - restricted distributions. - - Restricted distributions include the RHEL nightlies and the Fedora distributions. - enum: - - rhel-8 - - rhel-8-nightly - - rhel-84 - - rhel-85 - - rhel-86 - - rhel-87 - - rhel-88 - - rhel-89 - - rhel-8.10 - - rhel-9 - - rhel-9-nightly - - rhel-9.6-nightly - - rhel-9.7-nightly - - rhel-9-beta - - rhel-90 - - rhel-91 - - rhel-92 - - rhel-93 - - rhel-94 - - rhel-95 - - rhel-9.6 - - rhel-10 - - rhel-10-nightly - - rhel-10.0-nightly - - rhel-10.1-nightly - - rhel-10-beta - - rhel-10.0 - - centos-9 - - centos-10 - - fedora-37 - - fedora-38 - - fedora-39 - - fedora-40 - - fedora-41 - - fedora-42 - ImageRequest: - type: object - additionalProperties: false - required: - - architecture - - image_type - - upload_request - properties: - architecture: - type: string - enum: - - x86_64 - - aarch64 - description: | - CPU architecture of the image, x86_64 and aarch64 are currently supported. - image_type: - $ref: '#/components/schemas/ImageTypes' - upload_request: - $ref: '#/components/schemas/UploadRequest' - ostree: - $ref: '#/components/schemas/OSTree' - size: - x-go-type: uint64 - example: 4294967296 - description: | - Size of image, in bytes. When set to 0 the image size is a minimum - defined by the image type. - snapshot_date: - type: string - description: | - Snapshotted content will be used instead of the official repositories of the - distribution. The snapshot that was made closest to, but before the specified date will - be used. If no snapshots made before the specified date can be found, the snapshot - closest to, but after the specified date will be used. If no snapshots can be found at - all, the request will fail. The format must be YYYY-MM-DD (ISO 8601 extended). - content_template: - type: string - description: | - ID of the content template. A content template and snapshot date cannot both be specified. - If a content template is specified, the snapshot date used will be the one from the content template. - content_template_name: - type: string - description: | - Name of the content template. Used when registering the system to Insights. - aap_registration: - $ref: '#/components/schemas/AAPRegistration' - ImageTypes: - type: string - enum: - - aws - - azure - - edge-commit - - edge-installer - - gcp - - guest-image - - image-installer - - oci - - openshift-virt - - vsphere - - vsphere-ova - - wsl - # backwards compatible aliases - - ami # == aws - - rhel-edge-commit # == edge-commit - - rhel-edge-installer # == edge-installer - - vhd # == azure - ComposesResponse: - required: - - meta - - links - - data - properties: - meta: - $ref: '#/components/schemas/ListResponseMeta' - links: - $ref: '#/components/schemas/ListResponseLinks' - data: - type: array - items: - $ref: '#/components/schemas/ComposesResponseItem' - ComposesResponseItem: - required: - - id - - request - - created_at - properties: - id: - type: string - format: uuid - request: - $ref: "#/components/schemas/ComposeRequest" - created_at: - type: string - image_name: - type: string - client_id: - $ref: '#/components/schemas/ClientId' - blueprint_id: - type: string - format: uuid - nullable: true - blueprint_version: - type: integer - nullable: true - ClientId: - type: string - enum: ["api", "ui"] - default: "api" - ComposeResponse: - required: - - id - properties: - id: - type: string - format: uuid - UploadRequest: - type: object - required: - - type - - options - properties: - type: - $ref: '#/components/schemas/UploadTypes' - options: - anyOf: - - $ref: '#/components/schemas/AWSUploadRequestOptions' - - $ref: '#/components/schemas/AWSS3UploadRequestOptions' - - $ref: '#/components/schemas/GCPUploadRequestOptions' - - $ref: '#/components/schemas/AzureUploadRequestOptions' - - $ref: '#/components/schemas/OCIUploadRequestOptions' - UploadTypes: - type: string - enum: - - aws - - gcp - - azure - - aws.s3 - - oci.objectstorage - AWSUploadRequestOptions: - type: object - properties: - share_with_accounts: - type: array - example: ['123456789012'] - items: - type: string - uniqueItems: true - share_with_sources: - type: array - example: ['12345'] - items: - type: string - uniqueItems: true - AWSS3UploadRequestOptions: - type: object - GCPUploadRequestOptions: - type: object - properties: - share_with_accounts: - type: array - example: [ - 'user:alice@example.com', - 'serviceAccount:my-other-app@appspot.gserviceaccount.com', - 'group:admins@example.com', - 'domain:example.com' - ] - description: | - List of valid Google accounts to share the imported Compute Node image with. - Each string must contain a specifier of the account type. Valid formats are: - - 'user:{emailid}': An email address that represents a specific - Google account. For example, 'alice@example.com'. - - 'serviceAccount:{emailid}': An email address that represents a - service account. For example, 'my-other-app@appspot.gserviceaccount.com'. - - 'group:{emailid}': An email address that represents a Google group. - For example, 'admins@example.com'. - - 'domain:{domain}': The G Suite domain (primary) that represents all - the users of that domain. For example, 'google.com' or 'example.com'. - If not specified, the imported Compute Node image is not shared with any - account. - items: - type: string - uniqueItems: true - AzureUploadRequestOptions: - type: object - required: - - resource_group - properties: - source_id: - type: string - example: '12345' - description: | - ID of the source that will be used to resolve the tenant and subscription IDs. - Do not provide a tenant_id or subscription_id when providing a source_id. - tenant_id: - type: string - example: '5c7ef5b6-1c3f-4da0-a622-0b060239d7d7' - description: | - ID of the tenant where the image should be uploaded. This link explains how - to find it in the Azure Portal: - https://docs.microsoft.com/en-us/azure/active-directory/fundamentals/active-directory-how-to-find-tenant - When providing a tenant_id, also be sure to provide a subscription_id and do not include a source_id. - subscription_id: - type: string - example: '4e5d8b2c-ab24-4413-90c5-612306e809e2' - description: | - ID of subscription where the image should be uploaded. - When providing a subscription_id, also be sure to provide a tenant_id and do not include a source_id. - resource_group: - type: string - example: 'ToucanResourceGroup' - description: | - Name of the resource group where the image should be uploaded. - image_name: - type: string - example: 'LinuxImage' - pattern: '(^[a-zA-Z0-9]$)|(^[a-zA-Z0-9][a-zA-Z0-9_\.-]*[a-zA-Z0-9_]$)' - minLength: 1 - maxLength: 60 - description: | - Name of the created image. - Must begin with a letter or number, end with a letter, number or underscore, and may contain only letters, numbers, underscores, periods, or hyphens. - The total length is limited to 60 characters. - hyper_v_generation: - type: string - enum: - - V1 - - V2 - default: V1 - description: | - Choose the VM Image HyperV generation, different features on Azure are available - depending on the HyperV generation. - OCIUploadRequestOptions: - type: object - OSTree: - type: object - properties: - url: - type: string - contenturl: - type: string - description: | - A URL which, if set, is used for fetching content. Implies that `url` is set as well, - which will be used for metadata only. - ref: - type: string - example: 'rhel/8/x86_64/edge' - parent: - type: string - description: > - Can be either a commit (example: - 02604b2da6e954bd34b8b82a835e5a77d2b60ffa), or a branch-like - reference (example: rhel/8/x86_64/edge) - example: 'rhel/8/x86_64/edge' - rhsm: - type: boolean - description: | - Determines whether a valid subscription manager (candlepin) identity is required to - access this repository. Consumer certificates will be used as client certificates when - fetching metadata and content. - AAPRegistration: - type: object - x-go-name: AAPRegistration - additionalProperties: false - required: - - ansible_controller_url - - job_template_id - - host_config_key - properties: - ansible_controller_url: - type: string - example: "https://aap-gw.example.com" - job_template_id: - type: integer - example: 38 - host_config_key: - type: string - example: "44d7507f2ead49af5fca80aa18fd24bc" - tls_certificate_authority: - type: string - x-go-type-skip-optional-pointer: true - PackagesResponse: - type: object - required: - - meta - - links - - data - properties: - meta: - $ref: '#/components/schemas/ListResponseMeta' - links: - $ref: '#/components/schemas/ListResponseLinks' - data: - type: array - items: - $ref: '#/components/schemas/Package' - Package: - required: - - name - - summary - properties: - name: - type: string - summary: - type: string - ComposeMetadata: - type: object - properties: - packages: - type: array - items: - $ref: '#/components/schemas/PackageMetadata' - description: 'Package list including NEVRA' - ostree_commit: - type: string - description: 'ID (hash) of the built commit' - PackageMetadata: - required: - - type - - name - - version - - release - - arch - - sigmd5 - properties: - type: - type: string - name: - type: string - version: - type: string - release: - type: string - epoch: - type: string - arch: - type: string - sigmd5: - type: string - signature: - type: string - RecommendPackageRequest: - required: - - packages - - recommendedPackages - - distribution - type: object - properties: - packages: - type: array - items: - type: string - recommendedPackages: - type: integer - format: int32 - default: 3 - distribution: - type: string - pattern: '^rhel\d+$' - RecommendationsResponse: - required: - - packages - type: object - properties: - packages: - type: array - items: - type: string - modelVersion: - type: string - ClonesResponse: - required: - - meta - - links - - data - properties: - meta: - $ref: '#/components/schemas/ListResponseMeta' - links: - $ref: '#/components/schemas/ListResponseLinks' - data: - type: array - items: - $ref: '#/components/schemas/ClonesResponseItem' - ClonesResponseItem: - required: - - id - - compose_id - - request - - created_at - properties: - id: - type: string - format: uuid - compose_id: - type: string - format: uuid - description: 'UUID of the parent compose of the clone' - request: - $ref: '#/components/schemas/CloneRequest' - created_at: - type: string - CloneRequest: - oneOf: - - $ref: '#/components/schemas/AWSEC2Clone' - AWSEC2Clone: - type: object - required: - - region - properties: - region: - type: string - description: | - A region as described in - https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html#concepts-regions - share_with_accounts: - type: array - maxItems: 100 - example: ['123456789012'] - description: | - An array of AWS account IDs as described in - https://docs.aws.amazon.com/IAM/latest/UserGuide/console_account-alias.html - items: - type: string - pattern: '^[0-9]{12}$' - share_with_sources: - type: array - example: ['12345'] - items: - type: string - uniqueItems: true - CloneResponse: - required: - - id - properties: - id: - type: string - format: uuid - example: '123e4567-e89b-12d3-a456-426655440000' - DistributionProfileResponse: - type: array - description: | - List of profiles for a given distribution - items: - $ref: '#/components/schemas/DistributionProfileItem' - DistributionProfileItem: - type: string - enum: - - xccdf_org.ssgproject.content_profile_anssi_bp28_enhanced - - xccdf_org.ssgproject.content_profile_anssi_bp28_high - - xccdf_org.ssgproject.content_profile_anssi_bp28_intermediary - - xccdf_org.ssgproject.content_profile_anssi_bp28_minimal - - xccdf_org.ssgproject.content_profile_ccn_advanced - - xccdf_org.ssgproject.content_profile_ccn_basic - - xccdf_org.ssgproject.content_profile_ccn_intermediate - - xccdf_org.ssgproject.content_profile_cis - - xccdf_org.ssgproject.content_profile_cis_server_l1 - - xccdf_org.ssgproject.content_profile_cis_workstation_l1 - - xccdf_org.ssgproject.content_profile_cis_workstation_l2 - - xccdf_org.ssgproject.content_profile_cui - - xccdf_org.ssgproject.content_profile_e8 - - xccdf_org.ssgproject.content_profile_hipaa - - xccdf_org.ssgproject.content_profile_ism_o - - xccdf_org.ssgproject.content_profile_ospp - - xccdf_org.ssgproject.content_profile_pci-dss - - xccdf_org.ssgproject.content_profile_standard - - xccdf_org.ssgproject.content_profile_stig - - xccdf_org.ssgproject.content_profile_stig_gui - - # all customizations and sub-objects - Customizations: - type: object - properties: - containers: - type: array - items: - $ref: '#/components/schemas/Container' - description: Container images to embed into the final artfact - directories: - type: array - items: - $ref: '#/components/schemas/Directory' - description: Directories to create in the final artifact - files: - type: array - items: - $ref: '#/components/schemas/File' - description: Files to create in the final artifact - subscription: - $ref: '#/components/schemas/Subscription' - packages: - type: array - maxItems: 10000 - example: ['postgresql'] - items: - type: string - enabled_modules: - type: array - description: | - List of dnf modules to enable, so that packages can be installed from them. - items: - $ref: '#/components/schemas/Module' - payload_repositories: - type: array - items: - $ref: '#/components/schemas/Repository' - custom_repositories: - type: array - items: - $ref: '#/components/schemas/CustomRepository' - description: List of custom repositories. - openscap: - $ref: '#/components/schemas/OpenSCAP' - filesystem: - type: array - maxItems: 128 - items: - $ref: '#/components/schemas/Filesystem' - users: - type: array - items: - $ref: '#/components/schemas/User' - description: | - List of users that a customer can add, - also specifying their respective groups and SSH keys and/or password - services: - $ref: '#/components/schemas/Services' - hostname: - type: string - description: Configures the hostname - example: myhostname - kernel: - $ref: '#/components/schemas/Kernel' - groups: - type: array - description: List of groups to create - items: - $ref: '#/components/schemas/Group' - timezone: - $ref: '#/components/schemas/Timezone' - locale: - $ref: '#/components/schemas/Locale' - firewall: - $ref: '#/components/schemas/FirewallCustomization' - installation_device: - type: string - description: | - Name of the installation device, currently only useful for the edge-simplified-installer type - example: /dev/sda - fdo: - $ref: '#/components/schemas/FDO' - ignition: - $ref: '#/components/schemas/Ignition' - partitioning_mode: - type: string - enum: - - raw - - lvm - - auto-lvm - description: | - Select how the disk image will be partitioned. 'auto-lvm' will use raw unless - there are one or more mountpoints in which case it will use LVM. 'lvm' always - uses LVM, even when there are no extra mountpoints. 'raw' uses raw partitions - even when there are one or more mountpoints. - fips: - $ref: '#/components/schemas/FIPS' - installer: - $ref: '#/components/schemas/Installer' - cacerts: - $ref: '#/components/schemas/CACertsCustomization' - Container: - type: object - required: - - source - properties: - source: - type: string - description: Reference to the container to embed - example: 'registry.example.com/image:tag' - name: - type: string - description: Name to use for the container from the image - tls_verify: - type: boolean - description: Control TLS verifification - example: true - FirewallCustomization: - type: object - description: Firewalld configuration - additionalProperties: false - properties: - ports: - type: array - description: List of ports (or port ranges) and protocols to open - example: ["22:tcp", "80:tcp", "imap:tcp"] - items: - type: string - services: - type: object - description: Firewalld services to enable or disable - additionalProperties: false - properties: - enabled: - type: array - description: List of services to enable - example: ["ftp", "ntp"] - items: - type: string - disabled: - type: array - description: List of services to disable - example: ["telnet"] - items: - type: string - Directory: - type: object - description: | - A custom directory to create in the final artifact. - required: - - path - properties: - path: - type: string - description: Path to the directory - example: '/etc/mydir' - mode: - type: string - description: Permissions string for the directory in octal format - example: "0755" - user: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Owner of the directory as a user name or a uid - example: 'root' - group: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Group of the directory as a group name or a gid - example: 'root' - ensure_parents: - type: boolean - description: Ensure that the parent directories exist - default: false - File: - type: object - description: | - A custom file to create in the final artifact. - required: - - path - properties: - path: - type: string - description: Path to the file - example: '/etc/myfile' - mode: - type: string - description: Permissions string for the file in octal format - example: "0644" - user: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Owner of the file as a uid or a user name - example: 'root' - group: - oneOf: - - type: string - - type: integer - x-go-type: int64 - description: Group of the file as a gid or a group name - example: 'root' - data: - type: string - description: Contents of the file as plain text - data_encoding: - type: string - enum: ['plain', 'base64'] - description: When data is base64-encoded to prevent Akamai content filter false positives - default: 'plain' - ensure_parents: - type: boolean - description: Ensure that the parent directories exist - example: true - default: false - Kernel: - type: object - additionalProperties: false - properties: - name: - type: string - description: Name of the kernel to use - example: kernel-debug - append: - type: string - description: Appends arguments to the bootloader kernel command line - example: nosmt=force - Services: - type: object - additionalProperties: false - properties: - enabled: - description: List of services to enable by default - type: array - minItems: 1 - items: - type: string - example: "nftables" - disabled: - description: List of services to disable by default - type: array - minItems: 1 - items: - type: string - example: "firewalld" - masked: - description: List of services to mask by default - type: array - minItems: 1 - items: - type: string - example: "telnet" - Timezone: - type: object - description: Timezone configuration - additionalProperties: false - properties: - timezone: - type: string - description: Name of the timezone, defaults to UTC - example: US/Eastern - ntpservers: - type: array - description: List of ntp servers - example: ["0.north-america.pool.ntp.org", "1.north-america.pool.ntp.org"] - items: - type: string - Locale: - type: object - description: Locale configuration - additionalProperties: false - properties: - languages: - type: array - description: | - List of locales to be installed, the first one becomes primary, subsequent ones are secondary - example: ["en_US.UTF-8"] - items: - type: string - keyboard: - type: string - description: Sets the keyboard layout - example: us - FDO: - type: object - additionalProperties: false - description: FIDO device onboard configuration - properties: - manufacturing_server_url: - type: string - diun_pub_key_insecure: - type: string - diun_pub_key_hash: - type: string - diun_pub_key_root_certs: - type: string - FIPS: - type: object - additionalProperties: false - description: System FIPS mode setup - properties: - enabled: - type: boolean - description: Enables the system FIPS mode - default: false - Installer: - type: object - additionalProperties: false - description: Anaconda installer configuration - properties: - unattended: - type: boolean - description: | - Create a kickstart file for a fully automated installation - sudo-nopasswd: - type: array - items: - type: string - description: | - Enable passwordless sudo for users or groups (groups must be prefixed by %) - CACertsCustomization: - type: object - additionalProperties: false - required: - - pem_certs - properties: - pem_certs: - type: array - example: [ '---BEGIN CERTIFICATE---\nMIIC0DCCAbigAwIBAgIUI...\n---END CERTIFICATE---' ] - items: - type: string - Ignition: - type: object - additionalProperties: false - description: Ignition configuration - properties: - embedded: - $ref: '#/components/schemas/IgnitionEmbedded' - firstboot: - $ref: '#/components/schemas/IgnitionFirstboot' - IgnitionEmbedded: - type: object - additionalProperties: false - required: - - config - properties: - config: - type: string - IgnitionFirstboot: - type: object - additionalProperties: false - required: - - url - properties: - url: - type: string - description: Provisioning URL - Group: - type: object - additionalProperties: false - required: - - name - properties: - name: - type: string - description: Name of the group to create - gid: - type: integer - description: Group id of the group to create (optional) - User: - type: object - required: - - name - description: | - At least one of password, ssh_key must be set, validator takes care of it. - On update empty string can be used to remove password or ssh_key, - but at least one of them still must be present. - properties: - name: - type: string - example: "user1" - groups: - type: array - items: - type: string - description: | - List of groups to add the user to. The 'wheel' group should be added explicitly, as the - default value is empty. - example: ['wheel'] - ssh_key: - type: string - example: "ssh-rsa AAAAB3NzaC1" - password: - type: string - format: password - example: "$6$G91SvTj7uVp3xhqj$zVa8nqnJTlewniDII5dmvsBJnj3kloL3CXWdPDu9.e677VoRQd5zB6GKwkDvfGLoRR7NTl5nXLnJywk6IPIvS." - description: | - Plaintext passwords are also supported, they will be hashed and stored using the SHA-512 algorithm. - The password is never returned in the response. - Empty string can be used to remove the password during update but only with ssh_key set. - hasPassword: - type: boolean - description: | - Indicates whether the user has a password set. This flag is read-only. - Filesystem: - type: object - required: - - mountpoint - - min_size - properties: - mountpoint: - type: string - example: '/var' - min_size: - x-go-type: uint64 - example: 2147483648 - description: 'size of the filesystem in bytes' - Subscription: - type: object - required: - - organization - - activation-key - - server-url - - base-url - - insights - properties: - organization: - type: integer - example: 2040324 - activation-key: - type: string - format: password - example: 'my-secret-key' - server-url: - type: string - example: 'subscription.rhsm.redhat.com' - base-url: - type: string - example: http://cdn.redhat.com/ - insights: - type: boolean - example: true - rhc: - type: boolean - default: false - example: true - description: | - Optional flag to use rhc to register the system, which also always enables Insights. - insights_client_proxy: - type: string - format: uri - description: | - Optional value to set proxy option when registering the system to Insights. - OpenSCAP: - oneOf: - - $ref: '#/components/schemas/OpenSCAPProfile' - - $ref: '#/components/schemas/OpenSCAPCompliance' - OpenSCAPCompliance: - type: object - required: - - policy_id - properties: - policy_id: - type: string - format: uuid - example: 'fef25b3c-b970-46da-a4e1-cc4d855b98dc' - description: | - Apply a compliance policy which is defined in the Red Hat Insights Compliance - service. This policy can include tailorings. This only works for RHEL images, and the - policy needs to be available for the specific RHEL version. - OpenSCAPProfile: - type: object - required: - - profile_id - properties: - profile_id: - type: string - example: "xccdf_org.ssgproject.content_profile_cis" - description: | - Uses the OpenSCAP tooling directly to apply a pre-defined profile without tailorings. - profile_name: - type: string - description: "The profile type" - profile_description: - type: string - description: "The longform profile description" - CustomRepository: - type: object - required: - - id - description: | - Repository configuration for custom repositories. - At least one of the 'baseurl', 'mirrorlist', 'metalink' properties must - be specified. If more of them are specified, the order of precedence is - the same as listed above. Id is required. - properties: - id: - type: string - name: - type: string - filename: - type: string - baseurl: - type: array - example: [ 'https://cdn.redhat.com/content/dist/rhel8/8/x86_64/baseos/os/' ] - items: - type: string - format: uri - mirrorlist: - type: string - format: uri - example: 'http://mirrorlist.centos.org/?release=9-stream&arch=aarch64&repo=BaseOS' - metalink: - type: string - format: uri - example: 'https://mirrors.fedoraproject.org/metalink?repo=fedora-32&arch=x86_64' - gpgkey: - type: array - example: [ "-----BEGIN PGP PUBLIC KEY BLOCK-----\n\nmQINBGAcScoBEADLf8YHkezJ6adlMYw7aGGIlJalt8Jj2x/B2K+hIfIuxGtpVj7e\nLRgDU76jaT5pVD5mFMJ3pkeneR/cTmqqQkNyQshX2oQXwEzUSb1CNMCfCGgkX8Q2\nzZkrIcCrF0Q2wrKblaudhU+iVanADsm18YEqsb5AU37dtUrM3QYdWg9R+XiPfV8R\nKBjT03vVBOdMSsY39LaCn6Ip1Ovp8IEo/IeEVY1qmCOPAaK0bJH3ufg4Cueks+TS\nwQWTeCLxuZL6OMXoOPKwvMQfxbg1XD8vuZ0Ktj/cNH2xau0xmsAu9HJpekvOPRxl\nyqtjyZfroVieFypwZgvQwtnnM8/gSEu/JVTrY052mEUT7Ccb74kcHFTFfMklnkG/\n0fU4ARa504H3xj0ktbe3vKcPXoPOuKBVsHSv00UGYAyPeuy+87cU/YEhM7k3SVKj\n6eIZgyiMO0wl1YGDRKculwks9A+ulkg1oTb4s3zmZvP07GoTxW42jaK5WS+NhZee\n860XoVhbc1KpS+jfZojsrEtZ8PbUZ+YvF8RprdWArjHbJk2JpRKAxThxsQAsBhG1\n0Lux2WaMB0g2I5PcMdJ/cqjo08ccrjBXuixWri5iu9MXp8qT/fSzNmsdIgn8/qZK\ni8Qulfu77uqhW/wt2btnitgRsqjhxMujYU4Zb4hktF8hKU/XX742qhL5KwARAQAB\ntDFGZWRvcmEgKDM1KSA8ZmVkb3JhLTM1LXByaW1hcnlAZmVkb3JhcHJvamVjdC5v\ncmc+iQJOBBMBCAA4FiEEeH6mrhFH7uVsQLMM20Y5cZhnxY8FAmAcScoCGw8FCwkI\nBwIGFQoJCAsCBBYCAwECHgECF4AACgkQ20Y5cZhnxY+NYA/7BYpglySAZYHhjyKh\n/+f6zPfVvbH20Eq3kI7OFBN0nLX+BU1muvS+qTuS3WLrB3m3GultpKREJKLtm5ED\n1rGzXAoT1yp9YI8LADdMCCOyjAjsoWU87YUuC+/bnjrTeR2LROCfyPC76W985iOV\nm5S+bsQDw7C2LrldAM4MDuoyZ1SitGaZ4KQLVt+TEa14isYSGCjzo7PY8V3JOk50\ngqWg82N/bm2EzS7T83WEDb1lvj4IlvxgIqKeg11zXYxmrYSZJJCfvzf+lNS6uxgH\njx/J0ylZ2LibGr6GAAyO9UWrAZSwSM0EcjT8wECnxkSDuyqmWwVvNBXuEIV8Oe3Y\nMiU1fJN8sd7DpsFx5M+XdnMnQS+HrjTPKD3mWrlAdnEThdYV8jZkpWhDys3/99eO\nhk0rLny0jNwkauf/iU8Oc6XvMkjLRMJg5U9VKyJuWWtzwXnjMN5WRFBqK4sZomMM\nftbTH1+5ybRW/A3vBbaxRW2t7UzNjczekSZEiaLN9L/HcJCIR1QF8682DdAlEF9d\nk2gQiYSQAaaJ0JJAzHvRkRJLLgK2YQYiHNVy2t3JyFfsram5wSCWOfhPeIyLBTZJ\nvrpNlPbefsT957Tf2BNIugzZrC5VxDSKkZgRh1VGvSIQnCyzkQy6EU2qPpiW59G/\nhPIXZrKocK3KLS9/izJQTRltjMA=\n=PfT7\n-----END PGP PUBLIC KEY BLOCK-----\n" ] - description: 'GPG key used to sign packages in this repository. Can be a gpg key or a URL' - items: - type: string - check_gpg: - type: boolean - check_repo_gpg: - type: boolean - enabled: - type: boolean - priority: - type: integer - ssl_verify: - type: boolean - module_hotfixes: - type: boolean - Repository: - type: object - required: - - rhsm - properties: - id: - type: string - description: | - An ID referring to a repository defined in content sources can be used instead of - 'baseurl', 'mirrorlist' or 'metalink'. - rhsm: - type: boolean - baseurl: - type: string - format: uri - example: 'https://cdn.redhat.com/content/dist/rhel8/8/x86_64/baseos/os/' - mirrorlist: - type: string - format: uri - example: 'http://mirrorlist.centos.org/?release=9-stream&arch=aarch64&repo=BaseOS' - metalink: - type: string - format: uri - example: 'https://mirrors.fedoraproject.org/metalink?repo=fedora-32&arch=x86_64' - gpgkey: - type: string - check_gpg: - type: boolean - check_repo_gpg: - type: boolean - default: false - description: | - Enables gpg verification of the repository metadata - ignore_ssl: - type: boolean - module_hotfixes: - type: boolean - Module: - type: object - required: - - name - - stream - additionalProperties: false - properties: - name: - type: string - example: 'nodejs' - description: | - Name of the module to enable. - stream: - type: string - example: '22' - description: | - Stream to enable. diff --git a/api/schema/provisioning.json b/api/schema/provisioning.json deleted file mode 100644 index e9864c2b..00000000 --- a/api/schema/provisioning.json +++ /dev/null @@ -1,2193 +0,0 @@ -{ - "components": { - "examples": { - "v1.AvailabilityStatusRequest": { - "value": { - "source_id": "463243" - } - }, - "v1.AwsReservationRequestPayloadExample": { - "value": { - "amount": 1, - "image_id": "ami-7846387643232", - "instance_type": "t3.small", - "launch_template_id": "", - "name": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "region": "us-east-1", - "source_id": "654321" - } - }, - "v1.AwsReservationResponsePayloadDoneExample": { - "value": { - "amount": 1, - "aws_reservation_id": "r-3743243324231", - "image_id": "ami-7846387643232", - "instance_type": "t3.small", - "instances": [ - { - "detail": { - "privateipv4": "172.31.36.10", - "privateipv6": "2001:0db8:85a3:0000:0000:8a2e:0370:7334", - "publicdns": "ec2-184-73-141-211.compute-1.amazonaws.com", - "publicipv4": "184.73.141.211" - }, - "instance_id": "i-2324343212" - } - ], - "launch_template_id": "", - "name": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "region": "us-east-1", - "reservation_id": 1305, - "source_id": "654321" - } - }, - "v1.AwsReservationResponsePayloadPendingExample": { - "value": { - "amount": 1, - "aws_reservation_id": "", - "image_id": "ami-7846387643232", - "instance_type": "t3.small", - "instances": [], - "launch_template_id": "", - "name": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "region": "us-east-1", - "reservation_id": 0, - "source_id": "654321" - } - }, - "v1.AzureReservationRequestPayloadExample": { - "value": { - "amount": 1, - "image_id": "composer-api-081fc867-838f-44a5-af03-8b8def808431", - "instance_size": "Basic_A0", - "location": "useast", - "name": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "resource_group": "redhat-hcc", - "source_id": "654321" - } - }, - "v1.AzureReservationResponsePayloadDoneExample": { - "value": { - "amount": 1, - "image_id": "composer-api-081fc867-838f-44a5-af03-8b8def808431", - "instance_size": "Basic_A0", - "instances": [ - { - "detail": { - "privateipv4": "172.22.0.1", - "privateipv6": "", - "publicdns": "", - "publicipv4": "10.0.0.88" - }, - "instance_id": "/subscriptions/4b9d213f-712f-4d17-a483-8a10bbe9df3a/resourceGroups/redhat-deployed/providers/Microsoft.Compute/images/composer-api-92ea98f8-7697-472e-80b1-7454fa0e7fa7" - } - ], - "location": "useast", - "name": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "reservation_id": 1310, - "resource_group": "myCustom Azure RG", - "source_id": "654321" - } - }, - "v1.AzureReservationResponsePayloadPendingExample": { - "value": { - "amount": 1, - "image_id": "composer-api-081fc867-838f-44a5-af03-8b8def808431", - "instance_size": "Basic_A0", - "instances": [], - "location": "useast", - "name": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "reservation_id": 1310, - "resource_group": "myCustom Azure RG", - "source_id": "654321" - } - }, - "v1.GCPReservationRequestPayloadExample": { - "value": { - "amount": 1, - "image_id": "08a48fed-de87-40ab-a571-f64e30bd0aa8", - "launch_template_id": "", - "machine_type": "e2-micro", - "name_pattern": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "source_id": "654321", - "zone": "us-east-4" - } - }, - "v1.GCPReservationResponsePayloadDoneExample": { - "value": { - "amount": 1, - "gcp_operation_name": "operation-1686646674436-5fdff07e43209-66146b7e-f3f65ec5", - "image_id": "08a48fed-de87-40ab-a571-f64e30bd0aa8", - "instances": [ - { - "detail": { - "privateipv4": "10.198.0.2", - "privateipv6": "", - "publicdns": "", - "publicipv4": "10.0.0.88" - }, - "instance_id": "3003942005876582747" - } - ], - "launch_template_id": "4883371230199373111", - "machine_type": "e2-micro", - "name_pattern": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "reservation_id": 1305, - "source_id": "654321", - "zone": "us-east-4" - } - }, - "v1.GCPReservationResponsePayloadPendingExample": { - "value": { - "amount": 1, - "gcp_operation_name": "operation-1686646674436-5fdff07e43209-66146b7e-f3f65ec5", - "image_id": "08a48fed-de87-40ab-a571-f64e30bd0aa8", - "instances": [], - "launch_template_id": "4883371230199373111", - "machine_type": "e2-micro", - "name_pattern": "my-instance", - "poweroff": false, - "pubkey_id": 42, - "reservation_id": 1305, - "source_id": "654321", - "zone": "us-east-4" - } - }, - "v1.GenericReservationResponsePayloadFailureExample": { - "value": { - "created_at": "2013-05-13T19:20:15Z", - "error": "cannot launch ec2 instance: VPCIdNotSpecified: No default VPC for this user. GroupName is only supported for EC2-Classic and default VPC", - "finished_at": "2013-05-13T19:20:25Z", - "id": 1313, - "provider": 1, - "status": "Finished Launch instance(s)", - "step": 2, - "step_titles": [ - "Ensure public key", - "Launch instance(s)", - "Fetch instance(s) description" - ], - "steps": 3, - "success": false - } - }, - "v1.GenericReservationResponsePayloadListExample": { - "value": { - "data": [ - { - "created_at": "2013-05-13T19:20:15Z", - "error": "", - "finished_at": null, - "id": 1310, - "provider": 1, - "status": "Started Ensure public key", - "step": 1, - "step_titles": [ - "Ensure public key", - "Launch instance(s)", - "Fetch instance(s) description" - ], - "steps": 3, - "success": null - }, - { - "created_at": "2013-05-13T19:20:15Z", - "error": "", - "finished_at": "2013-05-13T19:20:25Z", - "id": 1305, - "provider": 1, - "status": "Finished Fetch instance(s) description", - "step": 3, - "step_titles": [ - "Ensure public key", - "Launch instance(s)", - "Fetch instance(s) description" - ], - "steps": 3, - "success": true - }, - { - "created_at": "2013-05-13T19:20:15Z", - "error": "cannot launch ec2 instance: VPCIdNotSpecified: No default VPC for this user. GroupName is only supported for EC2-Classic and default VPC", - "finished_at": "2013-05-13T19:20:25Z", - "id": 1313, - "provider": 1, - "status": "Finished Launch instance(s)", - "step": 2, - "step_titles": [ - "Ensure public key", - "Launch instance(s)", - "Fetch instance(s) description" - ], - "steps": 3, - "success": false - } - ], - "metadata": { - "links": { - "next": "", - "previous": "" - }, - "total": 3 - } - } - }, - "v1.GenericReservationResponsePayloadPendingExample": { - "value": { - "created_at": "2013-05-13T19:20:15Z", - "error": "", - "finished_at": null, - "id": 1310, - "provider": 1, - "status": "Started Ensure public key", - "step": 1, - "step_titles": [ - "Ensure public key", - "Launch instance(s)", - "Fetch instance(s) description" - ], - "steps": 3, - "success": null - } - }, - "v1.GenericReservationResponsePayloadSuccessExample": { - "value": { - "created_at": "2013-05-13T19:20:15Z", - "error": "", - "finished_at": "2013-05-13T19:20:25Z", - "id": 1305, - "provider": 1, - "status": "Finished Fetch instance(s) description", - "step": 3, - "step_titles": [ - "Ensure public key", - "Launch instance(s)", - "Fetch instance(s) description" - ], - "steps": 3, - "success": true - } - }, - "v1.InstanceTypesAWSResponse": { - "value": { - "data": [ - { - "arch": "x86_64", - "cores": 16, - "memory_mib": 65536, - "name": "c5a.8xlarge", - "storage_gb": 0, - "supported": true, - "vcpus": 32 - } - ] - } - }, - "v1.InstanceTypesAzureResponse": { - "value": { - "data": [ - { - "arch": "x86_64", - "azure": { - "gen_v1": true, - "gen_v2": true - }, - "cores": 64, - "memory_mib": 2000000, - "name": "Standard_M128s", - "storage_gb": 4096, - "supported": true, - "vcpus": 128 - } - ] - } - }, - "v1.InstanceTypesGCPResponse": { - "value": { - "data": [ - { - "arch": "x86_64", - "cores": 0, - "memory_mib": 15623, - "name": "e2-highcpu-16", - "storage_gb": 0, - "supported": true, - "vcpus": 16 - } - ] - } - }, - "v1.LaunchTemplateListResponse": { - "value": { - "data": [ - { - "id": "lt-9843797432897342", - "name": "XXL large backend API" - } - ], - "metadata": { - "links": { - "next": "", - "previous": "" - }, - "total": 0 - } - } - }, - "v1.NoopReservationResponsePayloadExample": { - "value": { - "reservation_id": 1310 - } - }, - "v1.PubkeyListResponseExample": { - "value": { - "data": [ - { - "body": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEhnn80ZywmjeBFFOGm+cm+5HUwm62qTVnjKlOdYFLHN lzap", - "fingerprint": "gL/y6MvNmJ8jDXtsL/oMmK8jUuIefN39BBuvYw/Rndk=", - "fingerprint_legacy": "ee:f1:d4:62:99:ab:17:d9:3b:00:66:62:32:b2:55:9e", - "id": 3, - "name": "My key", - "type": "ssh-ed25519" - } - ], - "metadata": { - "links": { - "next": "", - "previous": "/api/provisioning/v1/pubkeys?limit=2\u0026offset=0" - }, - "total": 3 - } - } - }, - "v1.PubkeyRequestExample": { - "value": { - "body": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEhnn80ZywmjeBFFOGm+cm+5HUwm62qTVnjKlOdYFLHN lzap", - "name": "My key" - } - }, - "v1.PubkeyResponseExample": { - "value": { - "body": "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEhnn80ZywmjeBFFOGm+cm+5HUwm62qTVnjKlOdYFLHN lzap", - "fingerprint": "gL/y6MvNmJ8jDXtsL/oMmK8jUuIefN39BBuvYw/Rndk=", - "fingerprint_legacy": "ee:f1:d4:62:99:ab:17:d9:3b:00:66:62:32:b2:55:9e", - "id": 1, - "name": "My key", - "type": "ssh-ed25519" - } - }, - "v1.SourceListResponseExample": { - "value": { - "data": [ - { - "id": "654321", - "name": "My AWS account", - "provider": "aws", - "source_type_id": "", - "status": "available", - "uid": "" - }, - { - "id": "543621", - "name": "My other AWS account", - "provider": "aws", - "source_type_id": "", - "status": "available", - "uid": "" - } - ], - "metadata": { - "links": { - "next": "", - "previous": "/api/provisioning/v1/sources?limit=2\u0026offset=0" - }, - "total": 4 - } - } - }, - "v1.SourceUploadInfoAWSResponse": { - "value": { - "aws": { - "account_id": "78462784632" - }, - "azure": null, - "gcp": null, - "provider": "aws" - } - }, - "v1.SourceUploadInfoAzureResponse": { - "value": { - "aws": null, - "azure": { - "resourcegroups": [ - "MyGroup 1", - "MyGroup 42" - ], - "subscriptionid": "617807e1-e4e0-4855-983c-1e3ce1e49674", - "tenantid": "617807e1-e4e0-481c-983c-be3ce1e49253" - }, - "gcp": null, - "provider": "azure" - } - } - }, - "parameters": { - "Limit": { - "description": "The number of items to return.", - "in": "query", - "name": "limit", - "schema": { - "default": 100, - "type": "integer" - } - }, - "Offset": { - "description": "The number of items to skip before starting to collect the result set.", - "in": "query", - "name": "offset", - "schema": { - "default": 0, - "type": "integer" - } - }, - "Token": { - "description": "The token used for requesting the next page of results; empty token for the first page", - "in": "query", - "name": "token", - "schema": { - "default": "", - "type": "string" - } - } - }, - "responses": { - "BadRequest": { - "content": { - "application/json": { - "examples": { - "error": { - "value": { - "build_time": "2023-04-14_17:15:02", - "edge_id": "", - "environment": "", - "error": "error: bad request: details can be long", - "trace_id": "b57f7b78c", - "version": "df8a489" - } - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ResponseError" - } - } - }, - "description": "The request's parameters are not valid" - }, - "InternalError": { - "content": { - "application/json": { - "examples": { - "error": { - "value": { - "build_time": "2023-04-14_17:15:02", - "edge_id": "", - "environment": "", - "error": "error: this can be pretty long string", - "trace_id": "b57f7b78c", - "version": "df8a489" - } - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ResponseError" - } - } - }, - "description": "The server encountered an internal error" - }, - "NotFound": { - "content": { - "application/json": { - "examples": { - "error": { - "value": { - "build_time": "2023-04-14_17:15:02", - "edge_id": "", - "environment": "", - "error": "error: resource not found: details can be long", - "trace_id": "b57f7b78c", - "version": "df8a489" - } - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ResponseError" - } - } - }, - "description": "The requested resource was not found" - } - }, - "schemas": { - "v1.AWSReservationRequest": { - "properties": { - "amount": { - "format": "int32", - "type": "integer" - }, - "image_id": { - "type": "string" - }, - "instance_type": { - "type": "string" - }, - "launch_template_id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "poweroff": { - "type": "boolean" - }, - "pubkey_id": { - "format": "int64", - "type": "integer" - }, - "region": { - "type": "string" - }, - "source_id": { - "type": "string" - } - }, - "type": "object" - }, - "v1.AWSReservationResponse": { - "properties": { - "amount": { - "format": "int32", - "type": "integer" - }, - "aws_reservation_id": { - "type": "string" - }, - "image_id": { - "type": "string" - }, - "instance_type": { - "type": "string" - }, - "instances": { - "items": { - "properties": { - "detail": { - "properties": { - "private_ipv4": { - "type": "string" - }, - "private_ipv6": { - "type": "string" - }, - "public_dns": { - "type": "string" - }, - "public_ipv4": { - "type": "string" - } - }, - "type": "object" - }, - "instance_id": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "launch_template_id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "poweroff": { - "type": "boolean" - }, - "pubkey_id": { - "format": "int64", - "nullable": true, - "type": "integer" - }, - "region": { - "type": "string" - }, - "reservation_id": { - "format": "int64", - "type": "integer" - }, - "source_id": { - "type": "string" - } - }, - "type": "object" - }, - "v1.AccountIDTypeResponse": { - "properties": { - "aws": { - "nullable": true, - "properties": { - "account_id": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "v1.AvailabilityStatusRequest": { - "properties": { - "source_id": { - "type": "string" - } - }, - "type": "object" - }, - "v1.AzureReservationRequest": { - "properties": { - "amount": { - "format": "int64", - "type": "integer" - }, - "image_id": { - "type": "string" - }, - "instance_size": { - "type": "string" - }, - "location": { - "description": "Location (also known as region) to deploy the VM into, be aware it needs to be the same as the image location. Defaults to the Resource Group location, or 'eastus' when also creating the resource group.", - "type": "string" - }, - "name": { - "description": "Name of the instance, to keep names unique, it will be suffixed with UUID. Optional, defaults to 'redhat-vm''", - "type": "string" - }, - "poweroff": { - "type": "boolean" - }, - "pubkey_id": { - "format": "int64", - "type": "integer" - }, - "resource_group": { - "description": "Azure resource group name to deploy the VM resources into. Optional, defaults to images resource group and when not found to 'redhat-deployed'.", - "type": "string" - }, - "source_id": { - "type": "string" - } - }, - "type": "object" - }, - "v1.AzureReservationResponse": { - "properties": { - "amount": { - "format": "int64", - "type": "integer" - }, - "image_id": { - "type": "string" - }, - "instance_size": { - "type": "string" - }, - "instances": { - "items": { - "properties": { - "detail": { - "properties": { - "private_ipv4": { - "type": "string" - }, - "private_ipv6": { - "type": "string" - }, - "public_dns": { - "type": "string" - }, - "public_ipv4": { - "type": "string" - } - }, - "type": "object" - }, - "instance_id": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "location": { - "type": "string" - }, - "name": { - "type": "string" - }, - "poweroff": { - "type": "boolean" - }, - "pubkey_id": { - "format": "int64", - "nullable": true, - "type": "integer" - }, - "reservation_id": { - "format": "int64", - "type": "integer" - }, - "resource_group": { - "type": "string" - }, - "source_id": { - "type": "string" - } - }, - "type": "object" - }, - "v1.GCPReservationRequest": { - "properties": { - "amount": { - "format": "int64", - "type": "integer" - }, - "image_id": { - "type": "string" - }, - "launch_template_id": { - "type": "string" - }, - "machine_type": { - "type": "string" - }, - "name_pattern": { - "type": "string" - }, - "poweroff": { - "type": "boolean" - }, - "pubkey_id": { - "format": "int64", - "type": "integer" - }, - "source_id": { - "type": "string" - }, - "zone": { - "type": "string" - } - }, - "type": "object" - }, - "v1.GCPReservationResponse": { - "properties": { - "amount": { - "format": "int64", - "type": "integer" - }, - "gcp_operation_name": { - "type": "string" - }, - "image_id": { - "type": "string" - }, - "instances": { - "items": { - "properties": { - "detail": { - "properties": { - "private_ipv4": { - "type": "string" - }, - "private_ipv6": { - "type": "string" - }, - "public_dns": { - "type": "string" - }, - "public_ipv4": { - "type": "string" - } - }, - "type": "object" - }, - "instance_id": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "launch_template_id": { - "type": "string" - }, - "machine_type": { - "type": "string" - }, - "name_pattern": { - "type": "string" - }, - "poweroff": { - "type": "boolean" - }, - "pubkey_id": { - "format": "int64", - "nullable": true, - "type": "integer" - }, - "reservation_id": { - "format": "int64", - "type": "integer" - }, - "source_id": { - "type": "string" - }, - "zone": { - "type": "string" - } - }, - "type": "object" - }, - "v1.GenericReservationResponse": { - "properties": { - "created_at": { - "format": "date-time", - "type": "string" - }, - "error": { - "type": "string" - }, - "finished_at": { - "format": "date-time", - "nullable": true, - "type": "string" - }, - "id": { - "format": "int64", - "type": "integer" - }, - "provider": { - "type": "integer" - }, - "status": { - "type": "string" - }, - "step": { - "format": "int32", - "type": "integer" - }, - "step_titles": { - "items": { - "type": "string" - }, - "type": "array" - }, - "steps": { - "format": "int32", - "type": "integer" - }, - "success": { - "nullable": true, - "type": "boolean" - } - }, - "type": "object" - }, - "v1.InstanceTypeResponse": { - "properties": { - "architecture": { - "type": "string" - }, - "azure": { - "nullable": true, - "properties": { - "gen_v1": { - "type": "boolean" - }, - "gen_v2": { - "type": "boolean" - } - }, - "type": "object" - }, - "cores": { - "format": "int32", - "type": "integer" - }, - "memory_mib": { - "format": "int64", - "type": "integer" - }, - "name": { - "type": "string" - }, - "storage_gb": { - "format": "int64", - "type": "integer" - }, - "supported": { - "type": "boolean" - }, - "vcpus": { - "format": "int32", - "type": "integer" - } - }, - "type": "object" - }, - "v1.LaunchTemplatesResponse": { - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "type": "object" - }, - "v1.ListGenericReservationResponse": { - "properties": { - "data": { - "items": { - "nullable": true, - "properties": { - "created_at": { - "format": "date-time", - "type": "string" - }, - "error": { - "type": "string" - }, - "finished_at": { - "format": "date-time", - "nullable": true, - "type": "string" - }, - "id": { - "format": "int64", - "type": "integer" - }, - "provider": { - "type": "integer" - }, - "status": { - "type": "string" - }, - "step": { - "format": "int32", - "type": "integer" - }, - "step_titles": { - "items": { - "type": "string" - }, - "type": "array" - }, - "steps": { - "format": "int32", - "type": "integer" - }, - "success": { - "nullable": true, - "type": "boolean" - } - }, - "type": "object" - }, - "type": "array" - }, - "metadata": { - "properties": { - "links": { - "properties": { - "next": { - "type": "string" - }, - "previous": { - "type": "string" - } - }, - "type": "object" - }, - "total": { - "type": "integer" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "v1.ListInstaceTypeResponse": { - "properties": { - "data": { - "items": { - "nullable": true, - "properties": { - "architecture": { - "type": "string" - }, - "azure": { - "nullable": true, - "properties": { - "gen_v1": { - "type": "boolean" - }, - "gen_v2": { - "type": "boolean" - } - }, - "type": "object" - }, - "cores": { - "format": "int32", - "type": "integer" - }, - "memory_mib": { - "format": "int64", - "type": "integer" - }, - "name": { - "type": "string" - }, - "storage_gb": { - "format": "int64", - "type": "integer" - }, - "supported": { - "type": "boolean" - }, - "vcpus": { - "format": "int32", - "type": "integer" - } - }, - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "v1.ListLaunchTemplateResponse": { - "properties": { - "data": { - "items": { - "nullable": true, - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "metadata": { - "properties": { - "links": { - "properties": { - "next": { - "type": "string" - }, - "previous": { - "type": "string" - } - }, - "type": "object" - }, - "total": { - "type": "integer" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "v1.ListPubkeyResponse": { - "properties": { - "data": { - "items": { - "nullable": true, - "properties": { - "body": { - "type": "string" - }, - "fingerprint": { - "type": "string" - }, - "fingerprint_legacy": { - "type": "string" - }, - "id": { - "format": "int64", - "type": "integer" - }, - "name": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "metadata": { - "properties": { - "links": { - "properties": { - "next": { - "type": "string" - }, - "previous": { - "type": "string" - } - }, - "type": "object" - }, - "total": { - "type": "integer" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "v1.ListSourceResponse": { - "properties": { - "data": { - "items": { - "nullable": true, - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "provider": { - "description": "One of ('azure', 'aws', 'gcp')", - "type": "string" - }, - "source_type_id": { - "deprecated": true, - "type": "string" - }, - "status": { - "type": "string" - }, - "uid": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "metadata": { - "properties": { - "links": { - "properties": { - "next": { - "type": "string" - }, - "previous": { - "type": "string" - } - }, - "type": "object" - }, - "total": { - "type": "integer" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "v1.NoopReservationResponse": { - "properties": { - "reservation_id": { - "format": "int64", - "type": "integer" - } - }, - "type": "object" - }, - "v1.PubkeyRequest": { - "properties": { - "body": { - "description": "Add a public part of a SSH key pair.", - "type": "string" - }, - "name": { - "description": "Enter the name of the newly created pubkey.", - "type": "string" - } - }, - "type": "object" - }, - "v1.PubkeyResponse": { - "properties": { - "body": { - "type": "string" - }, - "fingerprint": { - "type": "string" - }, - "fingerprint_legacy": { - "type": "string" - }, - "id": { - "format": "int64", - "type": "integer" - }, - "name": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "type": "object" - }, - "v1.ResponseError": { - "properties": { - "build_time": { - "type": "string" - }, - "edge_id": { - "type": "string" - }, - "environment": { - "type": "string" - }, - "error": { - "type": "string" - }, - "msg": { - "type": "string" - }, - "trace_id": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "type": "object" - }, - "v1.SourceResponse": { - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "provider": { - "description": "One of ('azure', 'aws', 'gcp')", - "type": "string" - }, - "source_type_id": { - "deprecated": true, - "type": "string" - }, - "status": { - "type": "string" - }, - "uid": { - "type": "string" - } - }, - "type": "object" - }, - "v1.SourceUploadInfoResponse": { - "properties": { - "aws": { - "nullable": true, - "properties": { - "account_id": { - "type": "string" - } - }, - "type": "object" - }, - "azure": { - "nullable": true, - "properties": { - "resource_groups": { - "items": { - "type": "string" - }, - "type": "array" - }, - "subscription_id": { - "type": "string" - }, - "tenant_id": { - "type": "string" - } - }, - "type": "object" - }, - "gcp": { - "nullable": true - }, - "provider": { - "type": "string" - } - }, - "type": "object" - } - } - }, - "info": { - "description": "Provisioning service API", - "license": { - "name": "GPL-3.0" - }, - "title": "provisioning-api", - "version": "1.13.0" - }, - "openapi": "3.0.0", - "paths": { - "/availability_status/sources": { - "post": { - "description": "Schedules a background operation of Sources availability check. These checks are are performed in separate process at it's own pace. Results are sent via Kafka to Sources. There is no output from this REST operation available, no tracking of jobs is possible.\n", - "operationId": "availabilityStatus", - "requestBody": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.AvailabilityStatusRequest" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.AvailabilityStatusRequest" - } - } - }, - "description": "availability status request with source id", - "required": true - }, - "responses": { - "200": { - "description": "Returned on success, empty response." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Source" - ] - } - }, - "/instance_types/{PROVIDER}": { - "get": { - "description": "Return a list of instance types for particular provider. A region must be provided. A zone must be provided for Azure.\n", - "operationId": "getInstanceTypeListAll", - "parameters": [ - { - "description": "Cloud provider: aws, azure", - "in": "path", - "name": "PROVIDER", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Region to list instance types within. This is required.", - "in": "query", - "name": "region", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "Availability zone (or location) to list instance types within. Not applicable for AWS EC2 as all zones within a region are the same (will lead to an error when used). Required for Azure.", - "in": "query", - "name": "zone", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "aws": { - "$ref": "#/components/examples/v1.InstanceTypesAWSResponse" - }, - "azure": { - "$ref": "#/components/examples/v1.InstanceTypesAzureResponse" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ListInstaceTypeResponse" - } - } - }, - "description": "Return on success. Instance types have a field \"supported\" that indicates whether that particular type is supported by Red Hat. Typically, instances with less than 1.5 GiB RAM are not supported, but other rules may apply.\n" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "InstanceType" - ] - } - }, - "/pubkeys": { - "get": { - "description": "Returns a list of all public keys available in a particular account.\n", - "operationId": "getPubkeyList", - "parameters": [ - { - "$ref": "#/components/parameters/Limit" - }, - { - "$ref": "#/components/parameters/Offset" - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.PubkeyListResponseExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ListPubkeyResponse" - } - } - }, - "description": "OK. Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Pubkey" - ] - }, - "post": { - "description": "Creates a new public key and stores it in the provisioning database. Public keys are uploaded to clouds at the time of launching an instance. Some fields such as type or fingerprint are read-only.\n", - "operationId": "createPubkey", - "requestBody": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.PubkeyRequestExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.PubkeyRequest" - } - } - }, - "description": "request body", - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.PubkeyRequestExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.PubkeyResponse" - } - } - }, - "description": "OK. Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Pubkey" - ] - } - }, - "/pubkeys/{ID}": { - "delete": { - "description": "Deletes SSH keys that were uploaded with the specified public key from all the clouds. If a public key (pubkey) has been uploaded to one or more cloud providers, the deletion request attempts to remove those SSH keys from all associated clouds. Therefore, to delete a public key, the account must possess valid credentials for all cloud accounts to which the pubkey was uploaded. Otherwise, the delete operation fails, and the public key is not removed from the Provisioning database. This operation does not return a response body.\n", - "operationId": "removePubkeyById", - "parameters": [ - { - "description": "Enter the database ID of resource.", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - } - ], - "responses": { - "204": { - "description": "The Pubkey was deleted successfully." - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Pubkey" - ] - }, - "get": { - "description": "Gets details of the specified public key.", - "operationId": "getPubkeyById", - "parameters": [ - { - "description": "Database ID to search for", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.PubkeyResponseExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.PubkeyResponse" - } - } - }, - "description": "OK. Returned on success" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Pubkey" - ] - } - }, - "/reservations": { - "get": { - "description": "A reservation is a way to activate a job, keeps all data needed for a job to start. This operation returns list of all reservations for particular account. To get a reservation with common fields, use /reservations/ID. To get a detailed reservation with all fields which are different per provider, use /reservations/aws/ID. Reservation can be in three states: pending, success, failed. This can be recognized by the success field (null for pending, true for success, false for failure). See the examples.\n", - "operationId": "getReservationsList", - "parameters": [ - { - "$ref": "#/components/parameters/Limit" - }, - { - "$ref": "#/components/parameters/Offset" - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.GenericReservationResponsePayloadListExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ListGenericReservationResponse" - } - } - }, - "description": "Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/aws": { - "post": { - "description": "A reservation is a way to activate a job, keeps all data needed for a job to start. An AWS reservation is a reservation created for an AWS job. Image Builder UUID image is required, the service will also launch any AMI image prefixed with \"ami-\". Optionally, AWS EC2 launch template ID can be provided. All flags set through this endpoint override template values. Public key must exist prior calling this endpoint and ID must be provided, even when AWS EC2 launch template provides ssh-keys. Public key will be always be overwritten. A single account can create maximum of 2 reservations per second.\n", - "operationId": "createAwsReservation", - "requestBody": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.AwsReservationRequestPayloadExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.AWSReservationRequest" - } - } - }, - "description": "aws request body", - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/v1.AWSReservationResponse" - } - } - }, - "description": "Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/aws/{ID}": { - "get": { - "description": "Return an AWS reservation with details by id", - "operationId": "getAWSReservationByID", - "parameters": [ - { - "description": "Reservation ID, must be an AWS reservation otherwise 404 is returned", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "done": { - "$ref": "#/components/examples/v1.AwsReservationResponsePayloadDoneExample" - }, - "pending": { - "$ref": "#/components/examples/v1.AwsReservationResponsePayloadPendingExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.AWSReservationResponse" - } - } - }, - "description": "Returns detailed reservation information for an AWS reservation." - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/azure": { - "post": { - "description": "A reservation is a way to activate a job, keeps all data needed for a job to start. An Azure reservation is a reservation created for an Azure job. Image Builder UUID image is required and needs to be stored under same account as provided by SourceID. A single account can create maximum of 2 reservations per second.\n", - "operationId": "createAzureReservation", - "requestBody": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.AzureReservationRequestPayloadExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.AzureReservationRequest" - } - } - }, - "description": "azure request body", - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/v1.AzureReservationResponse" - } - } - }, - "description": "Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/azure/{ID}": { - "get": { - "description": "Return an Azure reservation with details by id", - "operationId": "getAzureReservationByID", - "parameters": [ - { - "description": "Reservation ID, must be an Azure reservation otherwise 404 is returned", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "done": { - "$ref": "#/components/examples/v1.AzureReservationResponsePayloadDoneExample" - }, - "pending": { - "$ref": "#/components/examples/v1.AzureReservationResponsePayloadPendingExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.AzureReservationResponse" - } - } - }, - "description": "Returns detailed reservation information for an Azure reservation." - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/gcp": { - "post": { - "description": "A reservation is a way to activate a job, keeps all data needed for a job to start. A GCP reservation is a reservation created for a GCP job. Image Builder UUID image is required and needs to be shared with the service account. Furthermore, by specifying the RFC-1035 compatible name pattern for example as \"instance\", instances names will be created in the format: \"instance-#####\". A single account can create maximum of 2 reservations per second.\n", - "operationId": "createGCPReservation", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/v1.GCPReservationRequest" - } - } - }, - "description": "gcp request body", - "required": true - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/v1.GCPReservationResponse" - } - } - }, - "description": "Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/gcp/{ID}": { - "get": { - "description": "Return an GCP reservation with details by id", - "operationId": "getGCPReservationByID", - "parameters": [ - { - "description": "Reservation ID, must be an GCP reservation otherwise 404 is returned", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/v1.GCPReservationResponse" - } - } - }, - "description": "Returns detailed reservation information for an GCP reservation." - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/noop": { - "post": { - "description": "A reservation is a way to activate a job, keeps all data needed for a job to start. A Noop reservation actually does nothing and immediately finish background job. This reservation has no input payload\n", - "operationId": "createNoopReservation", - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.NoopReservationResponsePayloadExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.NoopReservationResponse" - } - } - }, - "description": "Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/reservations/{ID}": { - "get": { - "description": "Return a generic reservation by id", - "operationId": "getReservationByID", - "parameters": [ - { - "description": "Reservation ID", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "failure": { - "$ref": "#/components/examples/v1.GenericReservationResponsePayloadFailureExample" - }, - "pending": { - "$ref": "#/components/examples/v1.GenericReservationResponsePayloadPendingExample" - }, - "success": { - "$ref": "#/components/examples/v1.GenericReservationResponsePayloadSuccessExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.GenericReservationResponse" - } - } - }, - "description": "Returns generic reservation information like status or creation time." - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Reservation" - ] - } - }, - "/sources": { - "get": { - "description": "Cloud credentials are kept in the sources application. This endpoint lists available sources for the particular account per individual type (AWS, Azure, ...). All the fields in the response are optional and can be omitted if Sources application also omits them.\n", - "operationId": "getSourceList", - "parameters": [ - { - "in": "query", - "name": "provider", - "schema": { - "enum": [ - "aws", - "azure", - "gcp" - ], - "type": "string" - } - }, - { - "$ref": "#/components/parameters/Limit" - }, - { - "$ref": "#/components/parameters/Offset" - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.SourceListResponseExample" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ListSourceResponse" - } - } - }, - "description": "Returned on success." - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Source" - ] - } - }, - "/sources/{ID}/launch_templates": { - "get": { - "description": "Return a list of launch templates.\nA launch template is a configuration set with a name that is available through hyperscaler API. When creating reservations, launch template can be provided in order to set additional configuration for instances. In GCP, when using templates, propagated user attributes are not overridden or updated. Only new attributes are added to the instance.\nCurrently AWS and GCP Launch Templates are supported.\n", - "operationId": "getLaunchTemplatesList", - "parameters": [ - { - "description": "Source ID from Sources Database", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - }, - { - "description": "Hyperscaler region", - "in": "query", - "name": "region", - "required": true, - "schema": { - "type": "string" - } - }, - { - "$ref": "#/components/parameters/Token" - }, - { - "$ref": "#/components/parameters/Limit" - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "example": { - "$ref": "#/components/examples/v1.LaunchTemplateListResponse" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.ListLaunchTemplateResponse" - } - } - }, - "description": "Return on success." - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Source" - ] - } - }, - "/sources/{ID}/upload_info": { - "get": { - "description": "Provides all necessary information to upload an image for given Source. Typically, this is account number, subscription ID but some hyperscaler types also provide additional data.\nThe response contains \"provider\" field which can be one of aws, azure or gcp and then exactly one field named \"aws\", \"azure\" or \"gcp\". Enum is not used due to limitation of the language (Go).\nSome types may perform more than one calls (e.g. Azure) so latency might be increased. Caching of static information is performed to improve latency of consequent calls.\n", - "operationId": "getSourceUploadInfo", - "parameters": [ - { - "description": "Source ID from Sources Database", - "in": "path", - "name": "ID", - "required": true, - "schema": { - "format": "int64", - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "examples": { - "aws": { - "$ref": "#/components/examples/v1.SourceUploadInfoAWSResponse" - }, - "azure": { - "$ref": "#/components/examples/v1.SourceUploadInfoAzureResponse" - } - }, - "schema": { - "$ref": "#/components/schemas/v1.SourceUploadInfoResponse" - } - } - }, - "description": "Return on success." - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "Source" - ] - } - } - }, - "servers": [ - { - "description": "Local development", - "url": "http://0.0.0.0:{port}/api/{applicationName}", - "variables": { - "applicationName": { - "default": "provisioning" - }, - "port": { - "default": "8000" - } - } - } - ], - "tags": [ - { - "description": "A pubkey represents the SSH public portion of a key pair with a name and body. Public key types and fingerprints are detected during their creation process. Two types are supported: RSA and ssh-ed25519. Fingerprints are calculated in two ways: using the standard SHA method and the legacy MD5 method, which is available under the fingerprint_legacy field. Each public key has a unique name and body and helps in verifying the uniqueness of the keys. Using this API, you can perform the following operations.\n", - "name": "Pubkey" - }, - { - "description": "A reservation represents a request for launching one or more instances from a single image. This reservation triggers a background job, that will Launch set amount of instances with the same configuration. The configuration decides target provider, instance size and ssh pubkey to use for the default user.\n", - "name": "Reservation" - }, - { - "description": "A Source represents a connection with public cloud account. These endpoints serve as convenient way to read information about available Sources to deploy instances into. The source of through is different application called Sources.\n", - "name": "Source" - } - ] -} diff --git a/api/schema/rhsm.json b/api/schema/rhsm.json deleted file mode 100644 index 7a98d48b..00000000 --- a/api/schema/rhsm.json +++ /dev/null @@ -1 +0,0 @@ -{"basePath":"/management/v2","consumes":["application/json"],"definitions":{"APIPageParam":{"description":"APIPageParam details the pagination parameters in APIResponse","properties":{"count":{"type":"integer"},"limit":{"type":"integer"},"offset":{"type":"integer"}},"type":"object"},"ActivationKeys":{"properties":{"additionalRepositories":{"items":{"$ref":"#/definitions/AdditionalRepositories"},"type":"array"},"description":{"type":"string"},"id":{"type":"string"},"name":{"type":"string"},"releaseVersion":{"type":"string"},"role":{"type":"string"},"serviceLevel":{"type":"string"},"updatedAt":{"type":"string"},"usage":{"type":"string"}},"type":"object"},"AdditionalRepositories":{"properties":{"repositoryLabel":{"type":"string"}},"type":"object"},"AvailableRepositories":{"properties":{"architecture":{"type":"string"},"default":{"type":"string"},"engineeringProduct":{"type":"string"},"repositoryLabel":{"type":"string"},"repositoryName":{"type":"string"},"rpmType":{"type":"string"}},"type":"object"},"Capacity":{"properties":{"name":{"type":"string"},"quantity":{"type":"string"}},"type":"object"},"Date":{"description":"Date format used in API responses.","example":"2006-01-02T15:04:05.000Z","type":"string"},"EntitlementsAttached":{"description":"Details of all the entitlements attached and their status.","properties":{"reason":{"type":"string"},"valid":{"type":"boolean"},"value":{"items":{"$ref":"#/definitions/EntitlementsAttachedValue"},"type":"array"}},"type":"object"},"EntitlementsAttachedValue":{"description":"Detail of each entitlement attached","properties":{"contractNumber":{"type":"string"},"endDate":{"$ref":"#/definitions/Date"},"entitlementQuantity":{"type":"integer"},"id":{"type":"string"},"sku":{"type":"string"},"startDate":{"$ref":"#/definitions/Date"},"subscriptionName":{"type":"string"}},"type":"object"},"ErrorDetails":{"description":"ErrorDetails details the Error in ErrorResponse","properties":{"code":{"type":"integer"},"message":{"type":"string"}},"type":"object"},"EusProductList":{"properties":{"configurations":{"items":{"properties":{"repositories":{"items":{"type":"string"},"type":"array"},"version":{"type":"string"}},"type":"object"},"type":"array"},"engID":{"type":"integer"},"name":{"type":"string"}},"title":"List of RHEL EUS product-repo mappings","type":"object"},"Manifest":{"properties":{"entitlementQuantity":{"type":"integer"},"name":{"type":"string"},"simpleContentAccess":{"type":"string"},"type":{"type":"string"},"url":{"type":"string"},"uuid":{"type":"string"},"version":{"type":"string"}},"title":"Manifest is an entity that consumes entitlements. Also referred as a Distributor.","type":"object"},"ManifestDetails":{"description":"details of a manifest","properties":{"createdBy":{"type":"string"},"createdDate":{"$ref":"#/definitions/Date"},"entitlementsAttached":{"$ref":"#/definitions/EntitlementsAttached"},"entitlementsAttachedQuantity":{"type":"integer"},"lastModified":{"$ref":"#/definitions/Date"},"name":{"type":"string"},"simpleContentAccess":{"type":"string"},"type":{"type":"string"},"uuid":{"type":"string"},"version":{"type":"string"}},"type":"object"},"ManifestSummary":{"description":"details of a manifest","properties":{"contentAccessMode":{"type":"string"},"createdBy":{"type":"string"},"createdDate":{"$ref":"#/definitions/Date"},"entitlementsAttachedQuantity":{"type":"integer"},"lastModified":{"$ref":"#/definitions/Date"},"name":{"type":"string"},"type":{"type":"string"},"uuid":{"type":"string"},"version":{"type":"string"}},"type":"object"},"ManifestVersion":{"description":"List of satellite version","properties":{"description":{"type":"string"},"value":{"type":"string"}},"type":"object"},"OrgSimpleContentAccess":{"properties":{"id":{"type":"string"},"simpleContentAccess":{"type":"string"},"simpleContentAccessCapable":{"type":"boolean"},"systemPurposeAttributes":{"$ref":"#/definitions/SystemPurposeAttributes"}},"title":"Organization Simple Content Access details.","type":"object"},"PoolDetail":{"description":"PoolDetail is an entry in the system/allocation pools listing","properties":{"contractNumber":{"type":"string"},"endDate":{"$ref":"#/definitions/Date"},"entitlementsAvailable":{"type":"integer"},"id":{"type":"string"},"serviceLevel":{"type":"string"},"sku":{"type":"string"},"startDate":{"$ref":"#/definitions/Date"},"subscriptionName":{"type":"string"},"subscriptionNumber":{"type":"string"}},"type":"object"},"ProductList":{"properties":{"capacity":{"$ref":"#/definitions/Capacity"},"name":{"type":"boolean"},"productLine":{"type":"string"},"productName":{"type":"string"},"providedProducts":{"items":{"type":"number"},"type":"array"},"quantity":{"type":"integer"},"serviceLevel":{"type":"string"},"serviceType":{"type":"string"},"sku":{"type":"string"},"subscriptions":{"items":{"properties":{"contractNumber":{"type":"string"},"endDate":{"type":"string"},"number":{"type":"string"},"quantity":{"type":"string"},"startDate":{"type":"string"},"status":{"type":"string"}},"type":"object"},"type":"array"},"usage":{"type":"string"},"virtLimit":{"type":"string"}},"title":"List of products from subscriptions","type":"object"},"StatusCount":{"properties":{"active":{"type":"integer"},"expired":{"type":"integer"},"expiringSoon":{"type":"integer"},"futureDated":{"type":"integer"}},"title":"Status counts of user's subscriptions","type":"object"},"SystemPurposeAttributes":{"description":"System purpose settings available to an organization","properties":{"roles":{"items":{"type":"string"},"type":"array"},"serviceLevel":{"items":{"type":"string"},"type":"array"},"usage":{"items":{"type":"string"},"type":"array"}},"type":"object"},"exportJobResponse":{"properties":{"exportID":{"type":"string"},"href":{"type":"string"}},"type":"object"},"exportResponse":{"properties":{"exportJobID":{"type":"string"},"href":{"type":"string"}},"type":"object"},"ongoingExportJobResponse":{"properties":{"message":{"type":"string"}},"type":"object"},"poolsListMock":{"properties":{"body":{"items":{"$ref":"#/definitions/PoolDetail"},"type":"array"},"pagination":{"$ref":"#/definitions/APIPageParam"}},"type":"object"}},"host":"api.access.redhat.com","info":{"contact":{"url":"https://access.redhat.com/support/cases/"},"description":"API for Red Hat Subscription Management","title":"RHSM-API","version":"2"},"paths":{"/activation_keys":{"get":{"description":"Returns a list of activation keys on the account including service level, role, additionalRepositories, usage, and release version (if applicable). Additional Repositories and release version will be an empty set in case it is not set.","operationId":"listActivationKeys","responses":{"200":{"description":"Array of activation keys","schema":{"properties":{"body":{"items":{"$ref":"#/definitions/ActivationKeys"},"type":"array"}},"type":"object"}},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List activation keys","tags":["activationKey"]},"post":{"description":"Creates an activation key by name, release version and system purpose attributes, that are service level, role and usage. In the request body, \"name\" should be present and unique and can only contain letters, numbers, underscores, or hyphens. The response will have name and additionalRepositories as fixed fields. AdditionalRepositories field will always be empty for a new activation key. Role, serviceLevel, usage, releaseVersion and description are conditional fields, will be present in response only when they have values.","operationId":"createActivationKeys","parameters":[{"description":"Create an activation key","in":"body","name":"activationKey","schema":{"properties":{"additionalRepositories":{"items":{"properties":{"repositoryLabel":{"type":"string"}},"type":"object"},"type":"array"},"description":{"description":"should be 255 characters or shorter","type":"string"},"name":{"description":"Name should be present, unique and can only contain letters, numbers, underscores, or hyphens","type":"string"},"releaseVersion":{"type":"string"},"role":{"type":"string"},"serviceLevel":{"type":"string"},"usage":{"type":"string"}},"required":["name"],"type":"object"}}],"responses":{"200":{"description":"Activation key","schema":{"properties":{"body":{"$ref":"#/definitions/ActivationKeys"}},"type":"object"}},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Create activation key","tags":["activationKey"]}},"/activation_keys/{name}":{"delete":{"description":"Removes the activation key from the account based on activation key name","operationId":"removeActivationKeys","parameters":[{"in":"path","name":"name","required":true,"type":"string"}],"responses":{"204":{"description":"successfully removed"},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Delete activation key","tags":["activationKey"]},"get":{"description":"Get activation key by name","operationId":"showActivationKey","parameters":[{"in":"path","name":"name","required":true,"type":"string"}],"responses":{"200":{"description":"Activation key","schema":{"properties":{"body":{"$ref":"#/definitions/ActivationKeys"}},"type":"object"}},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Get activation key","tags":["activationKey"]},"put":{"description":"Updates an existing activation key with one or more fields as provided in request. It also returns additionalRepositories field which will be empty set when it is empty","operationId":"updateActivationKeys","parameters":[{"in":"path","name":"name","required":true,"type":"string"},{"description":"Update an activation key","in":"body","name":"activationKey","schema":{"properties":{"description":{"type":"string"},"releaseVersion":{"type":"string"},"role":{"type":"string"},"serviceLevel":{"type":"string"},"usage":{"type":"string"}},"type":"object"}}],"responses":{"200":{"description":"Activation key","schema":{"properties":{"body":{"$ref":"#/definitions/ActivationKeys"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Update activation key","tags":["activationKey"]}},"/activation_keys/{name}/additional_repositories":{"delete":{"description":"Removes the additional repositories from an activation key by providing activation key name and repository labels","operationId":"removeActivationKeyAdditionalRepositories","parameters":[{"in":"path","name":"name","required":true,"type":"string"},{"in":"body","name":"additionalRepositories","schema":{"items":{"$ref":"#/definitions/AdditionalRepositories"},"type":"array"}}],"responses":{"204":{"$ref":"#/responses/NoContent"},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Delete Additional Repositories","tags":["activationKey"]},"post":{"description":"Add additional repositories to an activation key by providing activation key name and repository labels. Customers can use any respositories listed in the `/v2/activation_keys/{name}/available_repositories` endpoint (use attribute `repositoryLabel`). Empty value is not supported and maximum length of repository label allowed is upto 255 characters.","operationId":"addAdditionalRepositories","parameters":[{"in":"path","name":"name","required":true,"type":"string"},{"description":"Add Additional repositories","in":"body","name":"activationKey","schema":{"items":{"$ref":"#/definitions/AdditionalRepositories"},"type":"array"}}],"responses":{"200":{"description":"list of additional repositories","schema":{"properties":{"body":{"items":{"$ref":"#/definitions/AdditionalRepositories"},"type":"array"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Add Additional Repositories","tags":["activationKey"]}},"/activation_keys/{name}/available_repositories":{"get":{"description":"Returns the list of RPM repositories available to an activation key that can be added as an additional repository. Available repositories are calculated by negating the additional repositories from the set of total RPM repositories. It can be an empty set if there are no RPM repositories or all of the repositories are already added to an activation key.","operationId":"listAvailableRepositories","parameters":[{"in":"path","name":"name","required":true,"type":"string"},{"description":"max number of results you want","in":"query","name":"limit","type":"integer"},{"description":"index from which you want next items","in":"query","name":"offset","type":"integer"},{"description":"Filters available repos based off default status","enum":["Disabled"],"in":"query","name":"default","type":"string"},{"description":"Repository name to search by","in":"query","name":"repo_name","type":"string"},{"description":"Repository label to search by","in":"query","name":"repo_label","type":"string"},{"description":"Comma separated list of architectures to search by","in":"query","name":"architecture","type":"string"},{"description":"Field to search by. Supported options are repo_name and repo_label. Must be used in combination with sort_direction","in":"query","name":"sort_by","type":"string"},{"description":"Direction to sort available repositories by. Supported options are asc and desc. Must be used in combination with sort_by","in":"query","name":"sort_direction","type":"string"},{"description":"Comma separated list of rpm types to filter by","in":"query","name":"rpm_type","type":"string"}],"responses":{"200":{"description":"list of available repositories","schema":{"properties":{"body":{"items":{"$ref":"#/definitions/AvailableRepositories"},"type":"array"},"pagination":{"$ref":"#/definitions/APIPageParam"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List Available Repositories","tags":["activationKey"]}},"/manifests":{"get":{"description":"The default and max number of results in a response are 100.\nSatellite 6.0 or higher versions are only supported.","operationId":"listManifests","parameters":[{"description":"max number of results you want","in":"query","name":"limit","type":"integer"},{"description":"index from which you want next items","in":"query","name":"offset","type":"integer"}],"responses":{"200":{"description":"list of manifests","schema":{"properties":{"body":{"items":{"$ref":"#/definitions/Manifest"},"type":"array"},"pagination":{"$ref":"#/definitions/APIPageParam"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List all manifests for a user","tags":["manifest"]},"post":{"description":"Create Manifest by name and version(optional).\nCustomers can use any version listed in the `/v2/manifests/versions`\nendpoint (use attribute `value`).\nIf no version is specified, it will take the latest available version\n for Manifest.","operationId":"createManifest","parameters":[{"description":"must be less than 100 characters and use only numbers, letters, underscores, hyphens, and periods","in":"query","name":"Name","required":true,"type":"string"},{"in":"query","name":"version","type":"string"}],"responses":{"200":{"description":"Success","schema":{"properties":{"body":{"$ref":"#/definitions/ManifestSummary"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Create Manifest","tags":["manifest"]}},"/manifests/versions":{"get":{"description":"Returns list of Satellite version 6.0 and above","operationId":"listVersionsManifest","responses":{"200":{"description":"list of Satellite version","schema":{"properties":{"body":{"items":{"$ref":"#/definitions/ManifestVersion"},"type":"array"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List Satellite versions","tags":["manifest"]}},"/manifests/{uuid}":{"delete":{"description":"The default success response will be 204\n\nSystem, RHUI, Hypervisor, SAM are unsupported manifet types","operationId":"removeManifest","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"},{"description":"Deleting a subscription manifest can have significant impacts on your hosts and activation keys.\nWe require a force parameter to make sure the delete operation is intentional.","enum":[true],"in":"query","name":"force","required":true,"type":"boolean"}],"responses":{"204":{"description":"Successfully removed"},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"},"504":{"$ref":"#/responses/GatewayTimeout"}},"summary":"Remove manifest profile","tags":["manifest"]},"get":{"description":"System, RHUI, Hypervisor, SAM are unsupported manifest types","operationId":"showManifest","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"},{"description":"Show more details about a manifest","enum":["entitlements"],"in":"query","maxItems":1,"name":"include","type":"string"}],"responses":{"200":{"description":"success response","schema":{"properties":{"body":{"$ref":"#/definitions/ManifestDetails"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Get an Manifest by UUID","tags":["manifest"]},"put":{"description":"Allows to update simpleContentAccess for Satellite of version 6.3 and\nabove\nPossible value for simpleContentAccess are:\n\n- enabled\n- disabled","operationId":"updateManifest","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"},{"in":"body","name":"manifest","schema":{"properties":{"simpleContentAccess":{"type":"string"}},"required":["simpleContentAccess"],"type":"object"}}],"responses":{"204":{"$ref":"#/responses/NoContent"},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Update a manifest","tags":["manifest"]}},"/manifests/{uuid}/entitlements":{"post":{"description":"Satellite 5.6 or higher versions are only supported.","operationId":"attachEntitlementManifest","parameters":[{"in":"query","maxItems":1,"minItems":1,"name":"pool","required":true,"type":"string"},{"description":"quantity you want to attach","in":"query","name":"quantity","type":"integer"},{"in":"path","name":"uuid","required":true,"type":"string"}],"responses":{"200":{"description":"Success","schema":{"properties":{"body":{"$ref":"#/definitions/ManifestDetails"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"},"504":{"$ref":"#/responses/GatewayTimeout"}},"summary":"Attach entitlement to Manifest","tags":["manifest"]}},"/manifests/{uuid}/entitlements/{EntitlementID}":{"delete":{"description":"The default success response will be 204.","operationId":"removeManifestEntitlement","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"},{"in":"path","name":"EntitlementID","required":true,"type":"string"}],"responses":{"204":{"description":"successfully removed"},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Remove entitlement from the manifest","tags":["manifest"]},"put":{"description":"The default success response will be 200.\n\nSystem, RHUI, Hypervisor, SAM are unsupported manifest types","operationId":"updateEntitlementManifest","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"},{"in":"path","name":"EntitlementID","required":true,"type":"string"},{"description":"maxItem: quantity must be less than or equal to the maximum number of allowed entitlements in the entitlement pool\nminItem: 1","in":"query","name":"quantity","type":"integer"}],"responses":{"200":{"description":"Success response","schema":{"properties":{"body":{"$ref":"#/definitions/ManifestDetails"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Update attached entitlement to manifest","tags":["manifest"]}},"/manifests/{uuid}/export":{"get":{"description":"Starts job to generate export for a manifest. To check the status of the export job visit the href in the response.\n\nSatellite 6.0 or higher versions are only supported.","operationId":"exportManifest","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"}],"responses":{"200":{"description":"ExportManifest200 is the success response","schema":{"properties":{"body":{"$ref":"#/definitions/exportResponse"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Trigger manifest export","tags":["manifest"]}},"/manifests/{uuid}/export/{ExportID}":{"get":{"description":"Success response contains a zip file. The link is one-time download and expires after one try. Trigger export job to get another download link.\n\nContent-Type: application/zip","operationId":"getExportManifest","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"},{"in":"path","name":"ExportID","required":true,"type":"string"}],"produces":["application/zip"],"responses":{"200":{"description":"GetExportManifest200 is the success response","schema":{"items":{"type":"integer"},"type":"array"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Download manifest","tags":["manifest"]}},"/manifests/{uuid}/exportJob/{ExportJobID}":{"get":{"description":"Returns export download link in response.","operationId":"exportJobManifest","parameters":[{"in":"path","name":"uuid","required":true,"type":"string"},{"in":"path","name":"ExportJobID","required":true,"type":"string"}],"responses":{"200":{"description":"ExportJobManifest200 is the success response","schema":{"properties":{"body":{"$ref":"#/definitions/exportJobResponse"}},"type":"object"}},"202":{"description":"AcceptedExportJob202 is a response for accepted and in progress job","schema":{"properties":{"body":{"$ref":"#/definitions/ongoingExportJobResponse"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"406":{"$ref":"#/responses/NotAcceptable"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Check status of manifest export","tags":["manifest"]}},"/manifests/{uuid}/pools":{"get":{"description":"Satellite 5.6 or higher versions are only supported.","operationId":"listManifestPools","parameters":[{"description":"max number of results you want","in":"query","name":"limit","type":"integer"},{"description":"index from which you want next items","in":"query","name":"offset","type":"integer"},{"description":"include future dated pools for satellite 6.3 or higher","enum":[true],"in":"query","name":"future","type":"boolean"},{"in":"path","name":"uuid","required":true,"type":"string"}],"responses":{"200":{"description":"list of pools available for the manifest","schema":{"$ref":"#/definitions/poolsListMock"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List all pools for a manifest","tags":["manifest"]}},"/organization":{"get":{"description":"Show Simple Content Access details of user's organization","operationId":"checkOrgSCACapability","parameters":[{"description":"Request for system purpose attributes in response","in":"query","name":"include","type":"string"}],"responses":{"200":{"description":"Organization details","schema":{"properties":{"body":{"$ref":"#/definitions/OrgSimpleContentAccess"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"404":{"$ref":"#/responses/NotFound"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Get details of the user's organization","tags":["organization"]}},"/products":{"get":{"description":"Get list of all the products of user's subscription. The products are from subscriptions that have not expired or expired within last 30 days.\n","operationId":"listProducts","parameters":[{"description":"Filters products based on subscription status","enum":["expired","expiringSoon","active","futureDated"],"in":"query","name":"status","type":"string"},{"description":"Request additional attributes per product in response","enum":["providedProducts"],"in":"query","name":"include","type":"string"},{"description":"Filters products based on the comma separated list of engineering product oids passed. When multiple values are passed, the products matching with all the oids within their providedProducts will be returned\n","in":"query","name":"oids","type":"string"}],"responses":{"200":{"description":"Product list","schema":{"properties":{"body":{"items":{"$ref":"#/definitions/ProductList"},"type":"array"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List all the products from user's subscription","tags":["products"]}},"/products/RHEL/extended-update-support-products":{"get":{"description":"Returns the list of currently supported RHEL product-repo mappings for Extended Update Support","responses":{"200":{"description":"Extended Update Support versions","schema":{"properties":{"body":{"items":{"$ref":"#/definitions/EusProductList"},"type":"array"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List RHEL EUS products","tags":["products"]}},"/products/RHEL/extended-update-support-versions":{"get":{"description":"Returns the list of currently supported RHEL versions for Extended Update Support","responses":{"200":{"description":"Extended Update Support versions","schema":{"properties":{"body":{"items":{"type":"string"},"type":"array"}},"type":"object"}},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"List RHEL EUS versions","tags":["products"]}},"/products/export":{"get":{"description":"Export a csv file of all subscriptions","produces":["text/csv"],"responses":{"200":{"description":"Export","examples":{"text/csv":"Name,SKU,Service level,Support type,Capacity name,Capacity quantity,Contract number,Quantity,Start date,End date,Status (Active, Expired, Future Dated)\nExample Name, Example SKU, Example Service level, Example Support type, Example Capacity name, Example Contract number, Example Quantity, Example Start date, Example End date, Example Status\n"},"schema":{"type":"file"}},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Export subscriptions","tags":["products"]}},"/products/status":{"get":{"description":"Get counts of user's subscriptions by status such as\n- active\n- expired\n- expiring soon\n- future dated ","operationId":"statusCounts","responses":{"200":{"description":"Status counts","schema":{"properties":{"body":{"$ref":"#/definitions/StatusCount"}},"type":"object"}},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Get user's subscription quantities by status","tags":["products"]}},"/products/{SKU}":{"get":{"description":"Get a single product by SKU","operationId":"showProduct","parameters":[{"description":"SKU of the product to show","in":"path","name":"SKU","required":true,"type":"string"}],"responses":{"200":{"description":"Product","schema":{"properties":{"body":{"$ref":"#/definitions/ProductList"}},"type":"object"}},"400":{"$ref":"#/responses/BadRequest"},"401":{"$ref":"#/responses/Unauthorized"},"403":{"$ref":"#/responses/Forbidden"},"500":{"$ref":"#/responses/InternalServerError"}},"summary":"Show product","tags":["products"]}}},"produces":["application/json"],"responses":{"BadRequest":{"description":"BadRequest error","schema":{"properties":{"error":{"$ref":"#/definitions/ErrorDetails"}},"type":"object"}},"Forbidden":{"description":"Forbidden error","schema":{"properties":{"error":{"$ref":"#/definitions/ErrorDetails"}},"type":"object"}},"GatewayTimeout":{"description":"GatewayTimeout error","schema":{"properties":{"error":{"$ref":"#/definitions/ErrorDetails"}},"type":"object"}},"InternalServerError":{"description":"InternalServerError error","schema":{"properties":{"error":{"$ref":"#/definitions/ErrorDetails"}},"type":"object"}},"NoContent":{"description":"No Content"},"NotAcceptable":{"description":"NotAcceptable error","schema":{"properties":{"error":{"$ref":"#/definitions/ErrorDetails"}},"type":"object"}},"NotFound":{"description":"NotFound error","schema":{"properties":{"error":{"$ref":"#/definitions/ErrorDetails"}},"type":"object"}},"Unauthorized":{"description":"Unauthorized error","schema":{"properties":{"error":{"$ref":"#/definitions/ErrorDetails"}},"type":"object"}}},"schemes":["https"],"swagger":"2.0"} \ No newline at end of file diff --git a/package.json b/package.json index 65d3cbea..189e4a79 100644 --- a/package.json +++ b/package.json @@ -115,9 +115,7 @@ "test:cockpit": "src/test/cockpit-tests.sh", "build": "fec build", "build:cockpit": "webpack --config cockpit/webpack.config.ts", - "api": "npm-run-all api:pull api:generate", - "api:generate": "bash api/codegen.sh", - "api:pull": "bash api/pull.sh", + "api": "bash api/codegen.sh", "verify": "npm-run-all build lint test", "postinstall": "ts-patch install", "circular": "madge --circular ./src --extensions js,ts,tsx", diff --git a/src/Components/ImagesTable/Instance.tsx b/src/Components/ImagesTable/Instance.tsx index 28a903bf..4f1526c2 100644 --- a/src/Components/ImagesTable/Instance.tsx +++ b/src/Components/ImagesTable/Instance.tsx @@ -31,7 +31,10 @@ import { MODAL_ANCHOR, SEARCH_INPUT, } from '../../constants'; -import { useGetBlueprintsQuery, useGetComposeStatusQuery } from '../../store/backendApi'; +import { + useGetBlueprintsQuery, + useGetComposeStatusQuery, +} from '../../store/backendApi'; import { selectBlueprintSearchInput, selectSelectedBlueprintId, @@ -109,7 +112,7 @@ const ProvisioningLink = ({ scope: 'provisioning', module: './ProvisioningWizard', }, - {} + {}, ); const { permissions, isLoading: isLoadingPermission } = @@ -118,7 +121,7 @@ const ProvisioningLink = ({ // Recomputing this value on every render made the modal crash. Using a state // helps avoiding this situation as the value is only set the first time. const [appendTo] = useState( - document.querySelector(MODAL_ANCHOR) as HTMLElement + document.querySelector(MODAL_ANCHOR) as HTMLElement, ); const selectedBlueprintId = useAppSelector(selectSelectedBlueprintId); @@ -129,10 +132,10 @@ const ProvisioningLink = ({ { selectFromResult: ({ data }) => ({ selectedBlueprintVersion: data?.data.find( - (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId + (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId, )?.version, }), - } + }, ); if ( @@ -262,7 +265,7 @@ export const OciInstance = ({ compose, isExpired }: OciInstancePropTypes) => { if (options && !isOciUploadStatus(options)) { throw TypeError( - `Error: options must be of type OciUploadStatus, not ${typeof options}.` + `Error: options must be of type OciUploadStatus, not ${typeof options}.`, ); } @@ -389,7 +392,6 @@ export const AwsS3Instance = ({ 'rhel-edge-installer': '', vhd: '', oci: '', - 'openshift-virt': '.tar', }; const status = composeStatus?.image_status.status; @@ -397,7 +399,7 @@ export const AwsS3Instance = ({ if (options && !isAwss3UploadStatus(options)) { throw TypeError( - `Error: options must be of type Awss3UploadStatus, not ${typeof options}.` + `Error: options must be of type Awss3UploadStatus, not ${typeof options}.`, ); } diff --git a/src/constants.ts b/src/constants.ts index 35dc9f72..792946a4 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -77,7 +77,6 @@ export const targetOptions: { [key in ImageTypes]: string } = { 'rhel-edge-installer': 'RHEL Edge Installer', vhd: '', oci: 'Oracle Cloud Infrastructure', - 'openshift-virt': 'OpenShift Virtualization', }; export const UNIT_KIB = 1024 ** 1; diff --git a/src/store/cockpit/composerCloudApi.ts b/src/store/cockpit/composerCloudApi.ts index ec20eecf..23ef7545 100644 --- a/src/store/cockpit/composerCloudApi.ts +++ b/src/store/cockpit/composerCloudApi.ts @@ -370,6 +370,9 @@ export type Subscription = { /** Optional value to register with a template when using rhc to register the system with Insights. */ template_name?: string | undefined; + /** Optional value used to specify the patch host when registering the system with Insights. + */ + patch_url?: string | undefined; }; export type Module = { /** Name of the module to enable. diff --git a/src/store/service/edgeApi.ts b/src/store/service/edgeApi.ts index 16c55889..809f1d56 100644 --- a/src/store/service/edgeApi.ts +++ b/src/store/service/edgeApi.ts @@ -82,7 +82,7 @@ const injectedRtkApi = api.injectEndpoints({ query: (queryArg) => ({ url: `/images`, method: "POST", - body: queryArg.modelsCreateImageApi, + body: queryArg.createImage, }), }), checkImageName: build.mutation< @@ -92,7 +92,7 @@ const injectedRtkApi = api.injectEndpoints({ query: (queryArg) => ({ url: `/images/checkImageName`, method: "POST", - body: queryArg.modelsCreateImageApi, + body: queryArg.createImage, }), }), createInstallerForImage: build.mutation< @@ -102,7 +102,7 @@ const injectedRtkApi = api.injectEndpoints({ query: (queryArg) => ({ url: `/images/${queryArg.imageId}/installer`, method: "POST", - body: queryArg.modelsCreateImageApi, + body: queryArg.createImage, }), }), createKickStartForImage: build.mutation< @@ -112,7 +112,7 @@ const injectedRtkApi = api.injectEndpoints({ query: (queryArg) => ({ url: `/images/${queryArg.imageId}/kickstart`, method: "POST", - body: queryArg.modelsCreateImageApi, + body: queryArg.createImage, }), }), getMetadataForImage: build.query< @@ -134,7 +134,7 @@ const injectedRtkApi = api.injectEndpoints({ query: (queryArg) => ({ url: `/images/${queryArg.imageId}/retry`, method: "POST", - body: queryArg.modelsCreateImageApi, + body: queryArg.createImage, }), }), createImageUpdate: build.mutation< @@ -144,7 +144,7 @@ const injectedRtkApi = api.injectEndpoints({ query: (queryArg) => ({ url: `/images/${queryArg.imageId}/update`, method: "POST", - body: queryArg.modelsCreateImageApi, + body: queryArg.createImage, }), }), getImageByOstree: build.query< @@ -239,13 +239,13 @@ export type GetAllImagesApiArg = { export type CreateImageApiResponse = /** status 200 OK */ ImageResponse; export type CreateImageApiArg = { /** request body */ - modelsCreateImageApi: ModelsCreateImageApi; + createImage: CreateImage; }; export type CheckImageNameApiResponse = /** status 200 OK */ ModelsSuccessPlaceholderResponse; export type CheckImageNameApiArg = { /** request body */ - modelsCreateImageApi: ModelsCreateImageApi; + createImage: CreateImage; }; export type CreateInstallerForImageApiResponse = /** status 200 OK */ ModelsSuccessPlaceholderResponse; @@ -253,7 +253,7 @@ export type CreateInstallerForImageApiArg = { /** Image ID */ imageId: number; /** request body */ - modelsCreateImageApi: ModelsCreateImageApi; + createImage: CreateImage; }; export type CreateKickStartForImageApiResponse = /** status 200 OK */ ModelsSuccessPlaceholderResponse; @@ -261,7 +261,7 @@ export type CreateKickStartForImageApiArg = { /** Image ID */ imageId: number; /** request body */ - modelsCreateImageApi: ModelsCreateImageApi; + createImage: CreateImage; }; export type GetMetadataForImageApiResponse = /** status 200 OK */ ModelsSuccessPlaceholderResponse; @@ -281,7 +281,7 @@ export type RetryCreateImageApiArg = { /** Image ID */ imageId: number; /** request body */ - modelsCreateImageApi: ModelsCreateImageApi; + createImage: CreateImage; }; export type CreateImageUpdateApiResponse = /** status 200 OK */ ModelsSuccessPlaceholderResponse; @@ -289,7 +289,7 @@ export type CreateImageUpdateApiArg = { /** Image ID */ imageId: number; /** request body */ - modelsCreateImageApi: ModelsCreateImageApi; + createImage: CreateImage; }; export type GetImageByOstreeApiResponse = /** status 200 OK */ ModelsSuccessPlaceholderResponse; @@ -558,7 +558,7 @@ export type ImageResponse = { /** storing for logging reference on resume */ request_id?: string | undefined; }; -export type ModelsCreateImageApi = object; +export type CreateImage = object; export const { useListAllImageSetsQuery, useGetImageSetsViewQuery, diff --git a/src/store/service/imageBuilderApi.ts b/src/store/service/imageBuilderApi.ts index 520efe19..1db44d17 100644 --- a/src/store/service/imageBuilderApi.ts +++ b/src/store/service/imageBuilderApi.ts @@ -462,7 +462,6 @@ export type ImageTypes = | "guest-image" | "image-installer" | "oci" - | "openshift-virt" | "vsphere" | "vsphere-ova" | "wsl" @@ -552,10 +551,11 @@ export type OsTree = { rhsm?: boolean | undefined; }; export type AapRegistration = { - ansible_controller_url: string; - job_template_id: number; + ansible_callback_url: string; host_config_key: string; tls_certificate_authority?: string | undefined; + /** When true, indicates the user has confirmed that HTTPS callback URL does not require a CA certificate for verification */ + skip_tls_verification?: boolean | undefined; }; export type ImageRequest = { /** CPU architecture of the image, x86_64 and aarch64 are currently supported. @@ -679,6 +679,65 @@ export type Filesystem = { /** size of the filesystem in bytes */ min_size: any; }; +export type Minsize = string; +export type FilesystemTyped = { + type?: "plain" | undefined; + /** The partition type GUID for GPT partitions. For DOS partitions, this field can be used to set the (2 hex digit) partition type. If not set, the type will be automatically set based on the mountpoint or the payload type. + */ + part_type?: string | undefined; + minsize?: Minsize | undefined; + mountpoint?: string | undefined; + label?: string | undefined; + /** The filesystem type. Swap partitions must have an empty mountpoint. + */ + fs_type: "ext4" | "xfs" | "vfat" | "swap"; +}; +export type BtrfsSubvolume = { + /** The name of the subvolume, which defines the location (path) on the root volume + */ + name: string; + /** Mountpoint for the subvolume + */ + mountpoint: string; +}; +export type BtrfsVolume = { + type: "btrfs"; + /** The partition type GUID for GPT partitions. For DOS partitions, this field can be used to set the (2 hex digit) partition type. If not set, the type will be automatically set based on the mountpoint or the payload type. + */ + part_type?: string | undefined; + minsize?: Minsize | undefined; + subvolumes: BtrfsSubvolume[]; +}; +export type LogicalVolume = { + name?: string | undefined; + minsize?: Minsize | undefined; + /** Mountpoint for the logical volume + */ + mountpoint?: string | undefined; + label?: string | undefined; + /** The filesystem type for the logical volume. Swap LVs must have an empty mountpoint. + */ + fs_type: "ext4" | "xfs" | "vfat" | "swap"; +}; +export type VolumeGroup = { + type: "lvm"; + /** The partition type GUID for GPT partitions. For DOS partitions, this field can be used to set the (2 hex digit) partition type. If not set, the type will be automatically set based on the mountpoint or the payload type. + */ + part_type?: string | undefined; + /** Volume group name (will be automatically generated if omitted) + */ + name?: string | undefined; + minsize?: Minsize | undefined; + logical_volumes: LogicalVolume[]; +}; +export type Partition = FilesystemTyped | BtrfsVolume | VolumeGroup; +export type Disk = { + /** Type of the partition table + */ + type?: ("gpt" | "dos") | undefined; + minsize?: Minsize | undefined; + partitions: Partition[]; +}; export type User = { name: string; /** List of groups to add the user to. The 'wheel' group should be added explicitly, as the @@ -785,6 +844,7 @@ export type Customizations = { custom_repositories?: CustomRepository[] | undefined; openscap?: OpenScap | undefined; filesystem?: Filesystem[] | undefined; + disk?: Disk | undefined; /** List of users that a customer can add, also specifying their respective groups and SSH keys and/or password */ @@ -864,7 +924,7 @@ export type BlueprintExportResponse = { export type ComposeResponse = { id: string; }; -export type ClientId = "api" | "ui"; +export type ClientId = "api" | "ui" | "mcp"; export type ComposeRequest = { distribution: Distributions; image_name?: string | undefined; From 3d39065ad073c8d1a0a501ca2f7776a002fc5bae Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Wed, 23 Jul 2025 10:32:33 +0100 Subject: [PATCH 014/123] README: update api generation Since our codegen tool supports pulling in OpenAPI schemas from a url, we no longer download the OpenAPI schema files. Update the README to reflect the changes. --- README.md | 33 +++++++++++---------------------- 1 file changed, 11 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index d47731ef..500e1d02 100644 --- a/README.md +++ b/README.md @@ -128,19 +128,15 @@ see the [osbuild-getting-started project](https://github.com/osbuild/osbuild-get API slice definitions are programmatically generated using the [@rtk-query/codegen-openapi](https://redux-toolkit.js.org/rtk-query/usage/code-generation) package. -OpenAPI schema for the endpoints are stored in `/api/schema`. Their -corresponding configuration files are stored in `/api/config`. Each endpoint -has a corresponding empty API slice and generated API slice which are stored in -`/src/store`. +The OpenAPI schema are imported during code generation. OpenAPI configuration files are +stored in `/api/config`. Each endpoint has a corresponding empty API slice and generated API +slice which are stored in `/src/store`. ### Add a new API schema For a hypothetical API called foobar -1. Download the foobar API OpenAPI json or yaml representation under -`api/schema/foobar.json` - -2. Create a new "empty" API file under `src/store/emptyFoobarApi.ts` that has following +1. Create a new "empty" API file under `src/store/emptyFoobarApi.ts` that has following content: ```typescript @@ -156,19 +152,19 @@ export const emptyFoobarApi = createApi({ }); ``` -3. Declare new constant `FOOBAR_API` with the API url in `src/constants.ts` +2. Declare new constant `FOOBAR_API` with the API url in `src/constants.ts` ```typescript export const FOOBAR_API = 'api/foobar/v1' ``` -4. Create the config file for code generation in `api/config/foobar.ts` containing: +3. Create the config file for code generation in `api/config/foobar.ts` containing: ```typescript import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { - schemaFile: '../schema/foobar.json', + schemaFile: 'URL_TO_THE_OPENAPI_SCHEMA', apiFile: '../../src/store/emptyFoobarApi.ts', apiImport: 'emptyEdgeApi', outputFile: '../../src/store/foobarApi.ts', @@ -178,14 +174,7 @@ const config: ConfigFile = { }; ``` -5. Update the `api.sh` script by adding a new line for npx to generate the code: - -```bash -npx @rtk-query/codegen-openapi ./api/config/foobar.ts & -``` - - -6. Update the `eslint.config.js` file by adding the generated code path to the ignores array: +4. Update the `eslint.config.js` file by adding the generated code path to the ignores array: ``` ignores: [ @@ -194,7 +183,7 @@ ignores: [ ] ``` -7. run api generation +5. run api generation ```bash npm run api @@ -355,12 +344,12 @@ Follow these steps to find and paste the certification file into the 'Keychain A npm ci ``` -3. Download the Playwright browsers with +3. Download the Playwright browsers with ```bash npx playwright install ``` -4. Start the local development stage server by running +4. Start the local development stage server by running ```bash npm run start:stage ``` From 5c1f9dbbddc70e7ead335accbc3ab86140591a3e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 24 Jul 2025 04:23:25 +0000 Subject: [PATCH 015/123] build(deps): bump @patternfly/react-code-editor from 6.1.0 to 6.3.0 Bumps [@patternfly/react-code-editor](https://github.com/patternfly/patternfly-react) from 6.1.0 to 6.3.0. - [Release notes](https://github.com/patternfly/patternfly-react/releases) - [Commits](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-code-editor@6.1.0...@patternfly/react-code-editor@6.3.0) --- updated-dependencies: - dependency-name: "@patternfly/react-code-editor" dependency-version: 6.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 96 +++++++++++++++++++++++++++++++++++++++-------- package.json | 2 +- 2 files changed, 82 insertions(+), 16 deletions(-) diff --git a/package-lock.json b/package-lock.json index 723352d0..576978fc 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,7 +11,7 @@ "dependencies": { "@ltd/j-toml": "1.38.0", "@patternfly/patternfly": "6.3.0", - "@patternfly/react-code-editor": "6.1.0", + "@patternfly/react-code-editor": "6.3.0", "@patternfly/react-core": "6.1.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.0", @@ -3786,21 +3786,58 @@ "license": "MIT" }, "node_modules/@patternfly/react-code-editor": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-code-editor/-/react-code-editor-6.1.0.tgz", - "integrity": "sha512-ae04+DdkgXFn3wEzvNCncNa78ZK3Swh5ng8p7yqFrD6lhW69NoJf+DdQlHi8gM8Qy05DNnIemSbQWpWLpInyzw==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-code-editor/-/react-code-editor-6.3.0.tgz", + "integrity": "sha512-2G0LId2KuuMcFZJRLDcRMfMHWRFG/sbMPXyD8yIi/2LPtAh/JFHbbDCzQXveQzaFhwXxVyVdCrCmbgn4SDYDlQ==", "license": "MIT", "dependencies": { "@monaco-editor/react": "^4.6.0", - "@patternfly/react-core": "^6.1.0", - "@patternfly/react-icons": "^6.1.0", - "@patternfly/react-styles": "^6.1.0", + "@patternfly/react-core": "^6.3.0", + "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-styles": "^6.3.0", "react-dropzone": "14.3.5", "tslib": "^2.8.1" }, "peerDependencies": { - "react": "^17 || ^18", - "react-dom": "^17 || ^18" + "react": "^17 || ^18 || ^19", + "react-dom": "^17 || ^18 || ^19" + } + }, + "node_modules/@patternfly/react-code-editor/node_modules/@patternfly/react-core": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", + "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", + "license": "MIT", + "dependencies": { + "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-styles": "^6.3.0", + "@patternfly/react-tokens": "^6.3.0", + "focus-trap": "7.6.4", + "react-dropzone": "^14.3.5", + "tslib": "^2.8.1" + }, + "peerDependencies": { + "react": "^17 || ^18 || ^19", + "react-dom": "^17 || ^18 || ^19" + } + }, + "node_modules/@patternfly/react-code-editor/node_modules/@patternfly/react-icons": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", + "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", + "license": "MIT", + "peerDependencies": { + "react": "^17 || ^18 || ^19", + "react-dom": "^17 || ^18 || ^19" + } + }, + "node_modules/@patternfly/react-code-editor/node_modules/focus-trap": { + "version": "7.6.4", + "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", + "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", + "license": "MIT", + "dependencies": { + "tabbable": "^6.2.0" } }, "node_modules/@patternfly/react-component-groups": { @@ -22334,16 +22371,45 @@ "integrity": "sha512-I/Z0uuaVYfv9QqNAP2/iCGUGhUb0idatNTfFLQk0VnUi2hSMgznDogvAjmlVtZu2DW0P0FymS0oo5EjL+uW6Dg==" }, "@patternfly/react-code-editor": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-code-editor/-/react-code-editor-6.1.0.tgz", - "integrity": "sha512-ae04+DdkgXFn3wEzvNCncNa78ZK3Swh5ng8p7yqFrD6lhW69NoJf+DdQlHi8gM8Qy05DNnIemSbQWpWLpInyzw==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-code-editor/-/react-code-editor-6.3.0.tgz", + "integrity": "sha512-2G0LId2KuuMcFZJRLDcRMfMHWRFG/sbMPXyD8yIi/2LPtAh/JFHbbDCzQXveQzaFhwXxVyVdCrCmbgn4SDYDlQ==", "requires": { "@monaco-editor/react": "^4.6.0", - "@patternfly/react-core": "^6.1.0", - "@patternfly/react-icons": "^6.1.0", - "@patternfly/react-styles": "^6.1.0", + "@patternfly/react-core": "^6.3.0", + "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-styles": "^6.3.0", "react-dropzone": "14.3.5", "tslib": "^2.8.1" + }, + "dependencies": { + "@patternfly/react-core": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", + "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", + "requires": { + "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-styles": "^6.3.0", + "@patternfly/react-tokens": "^6.3.0", + "focus-trap": "7.6.4", + "react-dropzone": "^14.3.5", + "tslib": "^2.8.1" + } + }, + "@patternfly/react-icons": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", + "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", + "requires": {} + }, + "focus-trap": { + "version": "7.6.4", + "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", + "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", + "requires": { + "tabbable": "^6.2.0" + } + } } }, "@patternfly/react-component-groups": { diff --git a/package.json b/package.json index 189e4a79..bf4c66ec 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,7 @@ "dependencies": { "@ltd/j-toml": "1.38.0", "@patternfly/patternfly": "6.3.0", - "@patternfly/react-code-editor": "6.1.0", + "@patternfly/react-code-editor": "6.3.0", "@patternfly/react-core": "6.1.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.0", From b8dc0e60c9b83c3e3885e42f2de0becceed80d5a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 24 Jul 2025 07:16:11 +0000 Subject: [PATCH 016/123] build(deps): bump axios from 1.10.0 to 1.11.0 Bumps [axios](https://github.com/axios/axios) from 1.10.0 to 1.11.0. - [Release notes](https://github.com/axios/axios/releases) - [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md) - [Commits](https://github.com/axios/axios/compare/v1.10.0...v1.11.0) --- updated-dependencies: - dependency-name: axios dependency-version: 1.11.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 576978fc..d7473d4d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7141,13 +7141,13 @@ } }, "node_modules/axios": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.10.0.tgz", - "integrity": "sha512-/1xYAC4MP/HEG+3duIhFr4ZQXR4sQXOIe+o6sdqzeykGLx6Upp/1p8MHqhINOvGeP7xyNHe7tsiJByc4SSVUxw==", + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.11.0.tgz", + "integrity": "sha512-1Lx3WLFQWm3ooKDYZD1eXmoGO9fxYQjrycfHFC8P0sCfQVXyROp0p9PFWBehewBOdCwHc+f/b8I0fMto5eSfwA==", "license": "MIT", "dependencies": { "follow-redirects": "^1.15.6", - "form-data": "^4.0.0", + "form-data": "^4.0.4", "proxy-from-env": "^1.1.0" } }, @@ -24533,12 +24533,12 @@ "dev": true }, "axios": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.10.0.tgz", - "integrity": "sha512-/1xYAC4MP/HEG+3duIhFr4ZQXR4sQXOIe+o6sdqzeykGLx6Upp/1p8MHqhINOvGeP7xyNHe7tsiJByc4SSVUxw==", + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.11.0.tgz", + "integrity": "sha512-1Lx3WLFQWm3ooKDYZD1eXmoGO9fxYQjrycfHFC8P0sCfQVXyROp0p9PFWBehewBOdCwHc+f/b8I0fMto5eSfwA==", "requires": { "follow-redirects": "^1.15.6", - "form-data": "^4.0.0", + "form-data": "^4.0.4", "proxy-from-env": "^1.1.0" } }, From 42d96edd00705828946d40d2b2ea6a2005520357 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Wed, 23 Jul 2025 15:09:40 +0200 Subject: [PATCH 017/123] test: Remove typing delay for locale test `Step Locale - unknown option is disabled` was quite flaky recently. Removing typing delay from the userEvent actions should solve the issue. --- .../Components/CreateImageWizard/steps/Locale/Locale.test.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx b/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx index 06411911..97b63798 100644 --- a/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx @@ -82,7 +82,7 @@ const selectLanguages = async () => { }; const searchForKeyboard = async (keyboard: string) => { - const user = userEvent.setup(); + const user = userEvent.setup({ delay: null }); const keyboardDropdown = await screen.findByPlaceholderText( /select a keyboard/i ); @@ -90,7 +90,7 @@ const searchForKeyboard = async (keyboard: string) => { }; const selectKeyboard = async () => { - const user = userEvent.setup(); + const user = userEvent.setup({ delay: null }); const usKeyboard = await screen.findByRole('option', { name: 'us' }); await waitFor(() => user.click(usKeyboard)); }; From 6f9a34c97200ce49d8525e4684cf0ebd297f3563 Mon Sep 17 00:00:00 2001 From: Michal Gold <mgold@redhat.com> Date: Thu, 19 Jun 2025 13:23:43 +0200 Subject: [PATCH 018/123] profileSelector: Prevent wizard refresh on Enter key in OpenSCAP profile selector Added event.preventDefault() in onKeyDown handler to stop default form submission behavior when hitting Enter in the typeahead filter. Also implemented auto-selection of single filtered results on Enter. --- .../Oscap/components/ProfileSelector.tsx | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index 60fe0936..b7a755ab 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -274,6 +274,27 @@ const ProfileSelector = () => { } }; + const onKeyDown = (event: React.KeyboardEvent) => { + if (event.key === 'Enter') { + event.preventDefault(); + + if (!isOpen) { + setIsOpen(true); + } else if (selectOptions.length === 1) { + const singleProfile = selectOptions[0]; + const selection: OScapSelectOptionValueType = { + profileID: singleProfile.id, + toString: () => singleProfile.name || '', + }; + + setInputValue(singleProfile.name || ''); + setFilterValue(''); + applyChanges(selection); + setIsOpen(false); + } + } + }; + const applyChanges = (selection: OScapSelectOptionValueType) => { if (selection.profileID === undefined) { // handle user has selected 'None' case @@ -337,6 +358,7 @@ const ProfileSelector = () => { value={profileID ? profileID : inputValue} onClick={onInputClick} onChange={onTextInputChange} + onKeyDown={onKeyDown} autoComplete="off" placeholder="None" isExpanded={isOpen} From 825e3beac1f1424c94962597dfaf4b81ba527019 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Jul 2025 04:21:22 +0000 Subject: [PATCH 019/123] build(deps-dev): bump @types/node from 24.0.13 to 24.1.0 Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 24.0.13 to 24.1.0. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) --- updated-dependencies: - dependency-name: "@types/node" dependency-version: 24.1.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index d7473d4d..d48f96ed 100644 --- a/package-lock.json +++ b/package-lock.json @@ -48,7 +48,7 @@ "@testing-library/jest-dom": "6.6.3", "@testing-library/react": "16.3.0", "@testing-library/user-event": "14.6.1", - "@types/node": "24.0.13", + "@types/node": "24.1.0", "@types/react": "18.3.12", "@types/react-dom": "18.3.1", "@types/react-redux": "7.1.34", @@ -5673,9 +5673,9 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "24.0.13", - "resolved": "https://registry.npmjs.org/@types/node/-/node-24.0.13.tgz", - "integrity": "sha512-Qm9OYVOFHFYg3wJoTSrz80hoec5Lia/dPp84do3X7dZvLikQvM1YpmvTBEdIr/e+U8HTkFjLHLnl78K/qjf+jQ==", + "version": "24.1.0", + "resolved": "https://registry.npmjs.org/@types/node/-/node-24.1.0.tgz", + "integrity": "sha512-ut5FthK5moxFKH2T1CUOC6ctR67rQRvvHdFLCD2Ql6KXmMuCrjsSsRI9UsLCm9M18BMwClv4pn327UvB7eeO1w==", "license": "MIT", "dependencies": { "undici-types": "~7.8.0" @@ -23540,9 +23540,9 @@ "dev": true }, "@types/node": { - "version": "24.0.13", - "resolved": "https://registry.npmjs.org/@types/node/-/node-24.0.13.tgz", - "integrity": "sha512-Qm9OYVOFHFYg3wJoTSrz80hoec5Lia/dPp84do3X7dZvLikQvM1YpmvTBEdIr/e+U8HTkFjLHLnl78K/qjf+jQ==", + "version": "24.1.0", + "resolved": "https://registry.npmjs.org/@types/node/-/node-24.1.0.tgz", + "integrity": "sha512-ut5FthK5moxFKH2T1CUOC6ctR67rQRvvHdFLCD2Ql6KXmMuCrjsSsRI9UsLCm9M18BMwClv4pn327UvB7eeO1w==", "requires": { "undici-types": "~7.8.0" } diff --git a/package.json b/package.json index bf4c66ec..7d128670 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "@testing-library/jest-dom": "6.6.3", "@testing-library/react": "16.3.0", "@testing-library/user-event": "14.6.1", - "@types/node": "24.0.13", + "@types/node": "24.1.0", "@types/react": "18.3.12", "@types/react-dom": "18.3.1", "@types/react-redux": "7.1.34", From 6bf800d4d93c98bdb347e9e8091a94b7260202b7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Jul 2025 04:21:59 +0000 Subject: [PATCH 020/123] build(deps-dev): bump @patternfly/react-icons from 6.1.0 to 6.3.0 Bumps [@patternfly/react-icons](https://github.com/patternfly/patternfly-react) from 6.1.0 to 6.3.0. - [Release notes](https://github.com/patternfly/patternfly-react/releases) - [Commits](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-icons@6.1.0...@patternfly/react-icons@6.3.0) --- updated-dependencies: - dependency-name: "@patternfly/react-icons" dependency-version: 6.3.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 66 ++++++++++++----------------------------------- package.json | 2 +- 2 files changed, 18 insertions(+), 50 deletions(-) diff --git a/package-lock.json b/package-lock.json index d48f96ed..0022c8d8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -38,7 +38,7 @@ "@babel/preset-typescript": "7.27.1", "@currents/playwright": "1.15.2", "@eslint/js": "9.31.0", - "@patternfly/react-icons": "6.1.0", + "@patternfly/react-icons": "6.3.0", "@playwright/test": "1.51.1", "@redhat-cloud-services/eslint-config-redhat-cloud-services": "3.0.0", "@redhat-cloud-services/frontend-components-config": "6.3.8", @@ -3793,7 +3793,7 @@ "dependencies": { "@monaco-editor/react": "^4.6.0", "@patternfly/react-core": "^6.3.0", - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "react-dropzone": "14.3.5", "tslib": "^2.8.1" @@ -3809,7 +3809,7 @@ "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", "license": "MIT", "dependencies": { - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", "focus-trap": "7.6.4", @@ -3821,16 +3821,6 @@ "react-dom": "^17 || ^18 || ^19" } }, - "node_modules/@patternfly/react-code-editor/node_modules/@patternfly/react-icons": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", - "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", - "license": "MIT", - "peerDependencies": { - "react": "^17 || ^18 || ^19", - "react-dom": "^17 || ^18 || ^19" - } - }, "node_modules/@patternfly/react-code-editor/node_modules/focus-trap": { "version": "7.6.4", "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", @@ -3876,13 +3866,13 @@ } }, "node_modules/@patternfly/react-icons": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.1.0.tgz", - "integrity": "sha512-V1w/j19YmOgvh72IRRf1p07k+u4M5+9P+o/IxunlF0fWzLDX4Hf+utBI11A8cRfUzpQN7eLw/vZIS3BLM8Ge3Q==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", + "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", "license": "MIT", "peerDependencies": { - "react": "^17 || ^18", - "react-dom": "^17 || ^18" + "react": "^17 || ^18 || ^19", + "react-dom": "^17 || ^18 || ^19" } }, "node_modules/@patternfly/react-styles": { @@ -3898,7 +3888,7 @@ "license": "MIT", "dependencies": { "@patternfly/react-core": "^6.3.0", - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", "lodash": "^4.17.21", @@ -3915,7 +3905,7 @@ "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", "license": "MIT", "dependencies": { - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", "focus-trap": "7.6.4", @@ -3927,16 +3917,6 @@ "react-dom": "^17 || ^18 || ^19" } }, - "node_modules/@patternfly/react-table/node_modules/@patternfly/react-icons": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", - "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", - "license": "MIT", - "peerDependencies": { - "react": "^17 || ^18 || ^19", - "react-dom": "^17 || ^18 || ^19" - } - }, "node_modules/@patternfly/react-table/node_modules/focus-trap": { "version": "7.6.4", "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", @@ -22377,7 +22357,7 @@ "requires": { "@monaco-editor/react": "^4.6.0", "@patternfly/react-core": "^6.3.0", - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "react-dropzone": "14.3.5", "tslib": "^2.8.1" @@ -22388,7 +22368,7 @@ "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", "requires": { - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", "focus-trap": "7.6.4", @@ -22396,12 +22376,6 @@ "tslib": "^2.8.1" } }, - "@patternfly/react-icons": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", - "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", - "requires": {} - }, "focus-trap": { "version": "7.6.4", "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", @@ -22438,9 +22412,9 @@ } }, "@patternfly/react-icons": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.1.0.tgz", - "integrity": "sha512-V1w/j19YmOgvh72IRRf1p07k+u4M5+9P+o/IxunlF0fWzLDX4Hf+utBI11A8cRfUzpQN7eLw/vZIS3BLM8Ge3Q==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", + "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", "requires": {} }, "@patternfly/react-styles": { @@ -22454,7 +22428,7 @@ "integrity": "sha512-klC0HKZvKhrRRJX8j1bLmfvzJyMeqpwbKeV7np9Ggvvh79IxWpBBKX2XbJkjHtl+sCwIVN1VZatil3HGba5CZQ==", "requires": { "@patternfly/react-core": "^6.3.0", - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", "lodash": "^4.17.21", @@ -22466,7 +22440,7 @@ "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", "requires": { - "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", "focus-trap": "7.6.4", @@ -22474,12 +22448,6 @@ "tslib": "^2.8.1" } }, - "@patternfly/react-icons": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-icons/-/react-icons-6.3.0.tgz", - "integrity": "sha512-W39JyqKW1UL6/YGuinDnpjbhmmLAfuxVrgDcdFBaK4D7D1iqkkqrDMV8zIzmV/RkodJ79xRnucYhYb2RukG4RA==", - "requires": {} - }, "focus-trap": { "version": "7.6.4", "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", diff --git a/package.json b/package.json index 7d128670..5a84a4c5 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,7 @@ "@babel/preset-typescript": "7.27.1", "@currents/playwright": "1.15.2", "@eslint/js": "9.31.0", - "@patternfly/react-icons": "6.1.0", + "@patternfly/react-icons": "6.3.0", "@playwright/test": "1.51.1", "@redhat-cloud-services/eslint-config-redhat-cloud-services": "3.0.0", "@redhat-cloud-services/frontend-components-config": "6.3.8", From 661fd29a5e10c68378af765f38f346fd524e4976 Mon Sep 17 00:00:00 2001 From: Gianluca Zuccarelli <gianlucazuccarelli@gmail.com> Date: Wed, 23 Jul 2025 10:43:11 +0100 Subject: [PATCH 021/123] playwright: add timeout for cockpit tests Playwright at times is making assertions before the osbuild-worker file is loaded. This is causing some flakiness in the tests, adding a timeout before some of the assertions should hopefully remove some of the flakiness. --- playwright/test.spec.ts | 32 ++++++++++++------- .../CloudProviderConfig/AWSConfig.tsx | 15 ++++++--- .../CloudProviderConfig.tsx | 16 ++++++++-- 3 files changed, 44 insertions(+), 19 deletions(-) diff --git a/playwright/test.spec.ts b/playwright/test.spec.ts index 86572a17..0f46028e 100644 --- a/playwright/test.spec.ts +++ b/playwright/test.spec.ts @@ -87,7 +87,7 @@ test.describe.serial('test', () => { await frame.getByRole('button', { name: 'Create blueprint' }).click(); await expect( - frame.locator('.pf-v6-c-card__title-text').getByText(blueprintName) + frame.locator('.pf-v6-c-card__title-text').getByText(blueprintName), ).toBeVisible(); }); @@ -196,14 +196,16 @@ test.describe.serial('test', () => { const switchInput = frame.locator('#aws-config-switch'); await expect(switchInput).toBeVisible(); - // the test is a little bit flaky, if it fails the first time - // while setting the configs, the second time the config should - // already be loaded and visible, if it is go back to the landing page - // https://github.com/osbuild/image-builder-frontend/issues/3429 + // introduce a wait time, since it takes some time to load the + // worker config file. + await page.waitForTimeout(1000); + + // If this test fails for any reason, the config should already be loaded + // and visible on the retury. If it is go back to the landing page if (await switchInput.isChecked()) { await frame.getByRole('button', { name: 'Cancel' }).click(); await expect( - frame.getByRole('heading', { name: 'All images' }) + frame.getByRole('heading', { name: 'All images' }), ).toBeVisible(); } else { const switchToggle = frame.locator('.pf-v6-c-switch'); @@ -217,7 +219,7 @@ test.describe.serial('test', () => { await frame.getByPlaceholder('Path to AWS credentials').fill(credentials); await frame.getByRole('button', { name: 'Submit' }).click(); await expect( - frame.getByRole('heading', { name: 'All images' }) + frame.getByRole('heading', { name: 'All images' }), ).toBeVisible(); } @@ -225,6 +227,11 @@ test.describe.serial('test', () => { .getByRole('button', { name: 'Configure Cloud Providers' }) .click(); await expect(header).toBeVisible(); + + // introduce a wait time, since it takes some time to load the + // worker config file. + await page.waitForTimeout(1500); + await expect(frame.locator('#aws-config-switch')).toBeChecked(); await expect(frame.getByPlaceholder('AWS bucket')).toHaveValue(bucket); @@ -241,6 +248,7 @@ test.describe.serial('test', () => { expect(parsed.aws?.credentials).toBe(credentials); }); + const cockpitBlueprintname = uuidv4(); test('cockpit cloud upload', async ({ page }) => { if (isHosted()) { return; @@ -266,8 +274,10 @@ test.describe.serial('test', () => { await frame.getByRole('button', { name: 'Back', exact: true }).click(); frame.getByRole('heading', { name: 'Details' }); - await frame.getByTestId('blueprint').fill(blueprintName); - await expect(frame.getByTestId('blueprint')).toHaveValue(blueprintName); + await frame.getByTestId('blueprint').fill(cockpitBlueprintname); + await expect(frame.getByTestId('blueprint')).toHaveValue( + cockpitBlueprintname, + ); await frame.getByRole('button', { name: 'Next', exact: true }).click(); await frame.getByRole('button', { name: 'Create blueprint' }).click(); @@ -276,10 +286,10 @@ test.describe.serial('test', () => { await frame .getByRole('textbox', { name: 'Search input' }) - .fill(blueprintName); + .fill(cockpitBlueprintname); // the clickable blueprint cards are a bit awkward, so use the // button's id instead - await frame.locator(`button[id="${blueprintName}"]`).click(); + await frame.locator(`button[id="${cockpitBlueprintname}"]`).click(); await frame.getByTestId('blueprint-build-image-menu-option').click(); // make sure the image is present diff --git a/src/Components/CloudProviderConfig/AWSConfig.tsx b/src/Components/CloudProviderConfig/AWSConfig.tsx index 1051767a..076ccc5f 100644 --- a/src/Components/CloudProviderConfig/AWSConfig.tsx +++ b/src/Components/CloudProviderConfig/AWSConfig.tsx @@ -1,4 +1,4 @@ -import React, { useState } from 'react'; +import React, { useEffect, useState } from 'react'; import { Button, @@ -38,7 +38,7 @@ type ToggleGroupProps = Omit<FormGroupProps<boolean>, 'isDisabled'>; const AWSConfigToggle = ({ value, onChange }: ToggleGroupProps) => { const handleChange = ( _event: React.FormEvent<HTMLInputElement>, - checked: boolean + checked: boolean, ) => { onChange(checked); }; @@ -159,18 +159,23 @@ const AWSCredsPath = ({ }; type AWSConfigProps = { - isEnabled: boolean; + enabled: boolean; + setEnabled: (enabled: boolean) => void; reinit: (config: AWSWorkerConfig | undefined) => void; refetch: () => Promise<{ data?: WorkerConfigResponse | undefined; }>; }; -export const AWSConfig = ({ isEnabled, refetch, reinit }: AWSConfigProps) => { +export const AWSConfig = ({ + enabled, + setEnabled, + refetch, + reinit, +}: AWSConfigProps) => { const dispatch = useAppDispatch(); const bucket = useAppSelector(selectAWSBucketName); const credentials = useAppSelector(selectAWSCredsPath); - const [enabled, setEnabled] = useState<boolean>(isEnabled); const onToggle = async (v: boolean) => { if (v) { diff --git a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx index e5897a09..ed5523a4 100644 --- a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx +++ b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx @@ -1,4 +1,9 @@ -import React, { MouseEventHandler, useCallback, useEffect } from 'react'; +import React, { + MouseEventHandler, + useCallback, + useEffect, + useState, +} from 'react'; import { Button, @@ -68,6 +73,7 @@ export const CloudProviderConfig = () => { const dispatch = useAppDispatch(); const config = useAppSelector(selectAWSConfig); const handleClose = () => navigate(resolveRelPath('')); + const [enabled, setEnabled] = useState<boolean>(false); const [updateConfig] = useUpdateWorkerConfigMutation(); const { data, error, refetch, isLoading } = useGetWorkerConfigQuery({}); @@ -76,9 +82,12 @@ export const CloudProviderConfig = () => { (config: AWSWorkerConfig | undefined) => { if (!config) { dispatch(reinitializeAWSConfig()); + setEnabled(false); return; } + setEnabled(true); + const { bucket, credentials } = config; if (bucket && bucket !== '') { dispatch(changeAWSBucketName(bucket)); @@ -88,7 +97,7 @@ export const CloudProviderConfig = () => { dispatch(changeAWSCredsPath(credentials)); } }, - [dispatch] + [dispatch, setEnabled], ); useEffect(() => { @@ -126,7 +135,8 @@ export const CloudProviderConfig = () => { <AWSConfig refetch={refetch} reinit={initAWSConfig} - isEnabled={!!(data?.aws && Object.keys(data.aws).length > 0)} + enabled={enabled} + setEnabled={setEnabled} /> </WizardStep> </Wizard> From 4d051eecde78f0009ee047c84a28c73bfa294112 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Jul 2025 06:51:57 +0000 Subject: [PATCH 022/123] build(deps-dev): bump eslint-plugin-playwright from 2.2.0 to 2.2.1 Bumps [eslint-plugin-playwright](https://github.com/playwright-community/eslint-plugin-playwright) from 2.2.0 to 2.2.1. - [Release notes](https://github.com/playwright-community/eslint-plugin-playwright/releases) - [Changelog](https://github.com/playwright-community/eslint-plugin-playwright/blob/main/CHANGELOG.md) - [Commits](https://github.com/playwright-community/eslint-plugin-playwright/compare/v2.2.0...v2.2.1) --- updated-dependencies: - dependency-name: eslint-plugin-playwright dependency-version: 2.2.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 13 +++++++------ package.json | 2 +- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/package-lock.json b/package-lock.json index 0022c8d8..93d08bc8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -68,7 +68,7 @@ "eslint-plugin-import": "2.32.0", "eslint-plugin-jest-dom": "5.5.0", "eslint-plugin-jsx-a11y": "6.10.2", - "eslint-plugin-playwright": "2.2.0", + "eslint-plugin-playwright": "2.2.1", "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", @@ -9745,12 +9745,11 @@ } }, "node_modules/eslint-plugin-playwright": { - "version": "2.2.0", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-playwright/-/eslint-plugin-playwright-2.2.1.tgz", + "integrity": "sha512-vYGKs9Y0H2A7tvvuKBF11w2aJa7diS9JRJbo/3Y5nU12RRgZummSUKvfZbickRdNVmt65R4lSrWn8Nyali2a3w==", "dev": true, "license": "MIT", - "workspaces": [ - "examples" - ], "dependencies": { "globals": "^13.23.0" }, @@ -26239,7 +26238,9 @@ } }, "eslint-plugin-playwright": { - "version": "2.2.0", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/eslint-plugin-playwright/-/eslint-plugin-playwright-2.2.1.tgz", + "integrity": "sha512-vYGKs9Y0H2A7tvvuKBF11w2aJa7diS9JRJbo/3Y5nU12RRgZummSUKvfZbickRdNVmt65R4lSrWn8Nyali2a3w==", "dev": true, "requires": { "globals": "^13.23.0" diff --git a/package.json b/package.json index 5a84a4c5..4a7280b4 100644 --- a/package.json +++ b/package.json @@ -66,7 +66,7 @@ "eslint-plugin-import": "2.32.0", "eslint-plugin-jest-dom": "5.5.0", "eslint-plugin-jsx-a11y": "6.10.2", - "eslint-plugin-playwright": "2.2.0", + "eslint-plugin-playwright": "2.2.1", "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", From 67a0f86ddeab26a5a0075f34c759276d9b5698bd Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Fri, 25 Jul 2025 13:51:11 +0200 Subject: [PATCH 023/123] ESLint: Set `no-unused-vars` rule to error This rule should output error instead of just a warning. --- eslint.config.js | 8 +++++++- src/Components/CloudProviderConfig/AWSConfig.tsx | 2 +- src/test/mocks/cockpit/cockpitFile.ts | 2 +- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/eslint.config.js b/eslint.config.js index cb0480e1..269a5115 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -111,7 +111,13 @@ module.exports = defineConfig([ '@typescript-eslint/no-require-imports': 'error', 'disable-autofix/@typescript-eslint/no-unnecessary-condition': 'warn', 'no-unused-vars': 'off', // disable js rule in favor of @typescript-eslint's rule - '@typescript-eslint/no-unused-vars': 'warn', + '@typescript-eslint/no-unused-vars': [ + 'error', + { + argsIgnorePattern: '^_', + varsIgnorePattern: '^_', + }, + ], 'jsx-a11y/no-autofocus': 'off', }, settings: { diff --git a/src/Components/CloudProviderConfig/AWSConfig.tsx b/src/Components/CloudProviderConfig/AWSConfig.tsx index 076ccc5f..4bd2404d 100644 --- a/src/Components/CloudProviderConfig/AWSConfig.tsx +++ b/src/Components/CloudProviderConfig/AWSConfig.tsx @@ -1,4 +1,4 @@ -import React, { useEffect, useState } from 'react'; +import React from 'react'; import { Button, diff --git a/src/test/mocks/cockpit/cockpitFile.ts b/src/test/mocks/cockpit/cockpitFile.ts index b8bbe452..612d9f7e 100644 --- a/src/test/mocks/cockpit/cockpitFile.ts +++ b/src/test/mocks/cockpit/cockpitFile.ts @@ -31,7 +31,7 @@ export const getLastBlueprintReq = () => { return lastRequest.blueprints[lastRequest.blueprints.length - 1]; }; -export const cockpitFile = (filepath: string, options?: object) => { +export const cockpitFile = (filepath: string, _options?: object) => { return { read: (): Promise<string> => { const file = path.parse(filepath); From 5b7b8daa4dcf9e32e2b296d0bc687f2fd64cabcc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Jul 2025 06:19:39 +0000 Subject: [PATCH 024/123] build(deps): bump @redhat-cloud-services/frontend-components Bumps [@redhat-cloud-services/frontend-components](https://github.com/RedHatInsights/frontend-components) from 6.1.0 to 6.1.1. - [Release notes](https://github.com/RedHatInsights/frontend-components/releases) - [Changelog](https://github.com/RedHatInsights/frontend-components/blob/master/CHANGELOG.md) - [Commits](https://github.com/RedHatInsights/frontend-components/compare/@redhat-cloud-services/frontend-components-6.1.0...@redhat-cloud-services/frontend-components-6.1.1) --- updated-dependencies: - dependency-name: "@redhat-cloud-services/frontend-components" dependency-version: 6.1.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 93d08bc8..d04fdc41 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14,7 +14,7 @@ "@patternfly/react-code-editor": "6.3.0", "@patternfly/react-core": "6.1.0", "@patternfly/react-table": "6.3.0", - "@redhat-cloud-services/frontend-components": "6.1.0", + "@redhat-cloud-services/frontend-components": "6.1.1", "@redhat-cloud-services/frontend-components-notifications": "6.1.0", "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", @@ -4044,9 +4044,9 @@ } }, "node_modules/@redhat-cloud-services/frontend-components": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components/-/frontend-components-6.1.0.tgz", - "integrity": "sha512-uLZfNCJIRxpiI15io9a0Y4/FuDSFEqAeLU6DMefs3Z0WdpvWEWJcoDZ7d4tiD1qCpbyfqMb4Luk98I5dZBznEw==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components/-/frontend-components-6.1.1.tgz", + "integrity": "sha512-p6nqk6pLL8nnxxIzfyQd5K6yW4EBqNZlAlgWmgSttwuuPAzHTDHFtutTvtCMK/hzlyfTnyGgjRMe2TL+wXrEcQ==", "license": "Apache-2.0", "dependencies": { "@patternfly/react-component-groups": "^6.0.0", @@ -22516,9 +22516,9 @@ } }, "@redhat-cloud-services/frontend-components": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components/-/frontend-components-6.1.0.tgz", - "integrity": "sha512-uLZfNCJIRxpiI15io9a0Y4/FuDSFEqAeLU6DMefs3Z0WdpvWEWJcoDZ7d4tiD1qCpbyfqMb4Luk98I5dZBznEw==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components/-/frontend-components-6.1.1.tgz", + "integrity": "sha512-p6nqk6pLL8nnxxIzfyQd5K6yW4EBqNZlAlgWmgSttwuuPAzHTDHFtutTvtCMK/hzlyfTnyGgjRMe2TL+wXrEcQ==", "requires": { "@patternfly/react-component-groups": "^6.0.0", "@redhat-cloud-services/frontend-components-utilities": "^6.0.0", diff --git a/package.json b/package.json index 4a7280b4..a0958dce 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "@patternfly/react-code-editor": "6.3.0", "@patternfly/react-core": "6.1.0", "@patternfly/react-table": "6.3.0", - "@redhat-cloud-services/frontend-components": "6.1.0", + "@redhat-cloud-services/frontend-components": "6.1.1", "@redhat-cloud-services/frontend-components-notifications": "6.1.0", "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", From f4e872548c67e0f440d8ab4c4fb5eb127b307531 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 28 Jul 2025 06:51:29 +0000 Subject: [PATCH 025/123] build(deps): bump @sentry/webpack-plugin from 4.0.0 to 4.0.1 Bumps [@sentry/webpack-plugin](https://github.com/getsentry/sentry-javascript-bundler-plugins) from 4.0.0 to 4.0.1. - [Release notes](https://github.com/getsentry/sentry-javascript-bundler-plugins/releases) - [Changelog](https://github.com/getsentry/sentry-javascript-bundler-plugins/blob/main/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-javascript-bundler-plugins/compare/4.0.0...4.0.1) --- updated-dependencies: - dependency-name: "@sentry/webpack-plugin" dependency-version: 4.0.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 46 +++++++++++++++++++++++----------------------- package.json | 2 +- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/package-lock.json b/package-lock.json index d04fdc41..a27960fd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,7 +19,7 @@ "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", - "@sentry/webpack-plugin": "4.0.0", + "@sentry/webpack-plugin": "4.0.1", "@unleash/proxy-client-react": "5.0.0", "classnames": "2.5.1", "jwt-decode": "4.0.0", @@ -4770,9 +4770,9 @@ } }, "node_modules/@sentry/babel-plugin-component-annotate": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.0.tgz", - "integrity": "sha512-1sozj4esnQBhJ2QO4imiLMl1858StkLjUxFF1KxgX/X1uEL/QlW2MYL8CKzbLeACy1SkR9h4V8GXSZvCnci5Dw==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.1.tgz", + "integrity": "sha512-wjxM5Gqms71tfPntejHix3sUJBFW/v04P0iPUDyvi30slbSlNnyOajwBPNDv+VE5Y6OANV8UV1IOksMaGW1n4Q==", "license": "MIT", "engines": { "node": ">= 14" @@ -4798,13 +4798,13 @@ } }, "node_modules/@sentry/bundler-plugin-core": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.0.tgz", - "integrity": "sha512-dTdbcctT5MJUwdbttZm2zomO+ui1F062ZIkogHeHqlA938Fwd1+9JIJ328+XL4XdcUG2yiFAZBWUPW3bYwoN9A==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.1.tgz", + "integrity": "sha512-V3k9nkh1eHHPw5wNnwCAYlR1yEMNaM1XkPtHj43vIWdy9cqqCGeRnGC8h+m4q61JdzGwZDufOhzs095Ib6TukA==", "license": "MIT", "dependencies": { "@babel/core": "^7.18.5", - "@sentry/babel-plugin-component-annotate": "4.0.0", + "@sentry/babel-plugin-component-annotate": "4.0.1", "@sentry/cli": "^2.49.0", "dotenv": "^16.3.1", "find-up": "^5.0.0", @@ -5088,12 +5088,12 @@ } }, "node_modules/@sentry/webpack-plugin": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.0.tgz", - "integrity": "sha512-Uhfjqnuxv4eYIt0GbPAdlFPum3BtasNhQrO3OJuVQRYRq21En7ARKXISoOhZHMo4tRRiiv+3npKYmpzHTALbQg==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.1.tgz", + "integrity": "sha512-LQkg6bEuneFNFtsXFViPujzEs/2SKqdIxYlEVr7cmPx0OhupViiA3TU+8UlgP4piqZWKDdMrlKuG3oTGMzdHww==", "license": "MIT", "dependencies": { - "@sentry/bundler-plugin-core": "4.0.0", + "@sentry/bundler-plugin-core": "4.0.1", "unplugin": "1.0.1", "uuid": "^9.0.0" }, @@ -22961,9 +22961,9 @@ } }, "@sentry/babel-plugin-component-annotate": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.0.tgz", - "integrity": "sha512-1sozj4esnQBhJ2QO4imiLMl1858StkLjUxFF1KxgX/X1uEL/QlW2MYL8CKzbLeACy1SkR9h4V8GXSZvCnci5Dw==" + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.1.tgz", + "integrity": "sha512-wjxM5Gqms71tfPntejHix3sUJBFW/v04P0iPUDyvi30slbSlNnyOajwBPNDv+VE5Y6OANV8UV1IOksMaGW1n4Q==" }, "@sentry/browser": { "version": "7.120.3", @@ -22981,12 +22981,12 @@ } }, "@sentry/bundler-plugin-core": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.0.tgz", - "integrity": "sha512-dTdbcctT5MJUwdbttZm2zomO+ui1F062ZIkogHeHqlA938Fwd1+9JIJ328+XL4XdcUG2yiFAZBWUPW3bYwoN9A==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.1.tgz", + "integrity": "sha512-V3k9nkh1eHHPw5wNnwCAYlR1yEMNaM1XkPtHj43vIWdy9cqqCGeRnGC8h+m4q61JdzGwZDufOhzs095Ib6TukA==", "requires": { "@babel/core": "^7.18.5", - "@sentry/babel-plugin-component-annotate": "4.0.0", + "@sentry/babel-plugin-component-annotate": "4.0.1", "@sentry/cli": "^2.49.0", "dotenv": "^16.3.1", "find-up": "^5.0.0", @@ -23134,11 +23134,11 @@ } }, "@sentry/webpack-plugin": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.0.tgz", - "integrity": "sha512-Uhfjqnuxv4eYIt0GbPAdlFPum3BtasNhQrO3OJuVQRYRq21En7ARKXISoOhZHMo4tRRiiv+3npKYmpzHTALbQg==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.1.tgz", + "integrity": "sha512-LQkg6bEuneFNFtsXFViPujzEs/2SKqdIxYlEVr7cmPx0OhupViiA3TU+8UlgP4piqZWKDdMrlKuG3oTGMzdHww==", "requires": { - "@sentry/bundler-plugin-core": "4.0.0", + "@sentry/bundler-plugin-core": "4.0.1", "unplugin": "1.0.1", "uuid": "^9.0.0" }, diff --git a/package.json b/package.json index a0958dce..ef822057 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,7 @@ "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", - "@sentry/webpack-plugin": "4.0.0", + "@sentry/webpack-plugin": "4.0.1", "@unleash/proxy-client-react": "5.0.0", "classnames": "2.5.1", "jwt-decode": "4.0.0", From 9f3ad9903706e779cf27f1c607b2693e84e3bf5d Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Mon, 28 Jul 2025 10:57:19 +0200 Subject: [PATCH 026/123] test: Remove delay for .upload user method This sets delay to null for `uploadFile` helper, meaning there's no delay for the `.upload` user method now. --- .../steps/Registration/Registration.test.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx b/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx index f6968a02..d4c2bb7c 100644 --- a/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx @@ -108,7 +108,7 @@ const addSatelliteRegistrationCommandViaKeyDown = async (command: string) => { }; const uploadFile = async (scriptName: string): Promise<void> => { - const user = userEvent.setup(); + const user = userEvent.setup({ delay: null}); const fileInput: HTMLElement | null = // eslint-disable-next-line testing-library/no-node-access document.querySelector('input[type="file"]'); @@ -432,7 +432,7 @@ describe('Registration request generated correctly', () => { expect(nextButton).toBeDisabled(); await uploadFile(CERTIFICATE); - expect(nextButton).toBeDisabled(); + await waitFor(() => expect(nextButton).toBeDisabled()); await addSatelliteRegistrationCommandViaKeyDown( SATELLITE_COMMAND_EXPIRED_TOKEN ); @@ -443,11 +443,11 @@ describe('Registration request generated correctly', () => { await waitFor(() => expect(expiredTokenHelper).toBeInTheDocument()); await addSatelliteRegistrationCommandViaKeyDown(SATELLITE_COMMAND); - expect(nextButton).toBeEnabled(); + await waitFor(() => expect(nextButton).toBeEnabled()); await addSatelliteRegistrationCommandViaKeyDown( SATELLITE_COMMAND_NO_EXPIRATION ); - expect(nextButton).toBeEnabled(); + await waitFor(() => expect(nextButton).toBeEnabled()); }); }); From ad5ea22da8367a9aca7cde105cb95e97bcd18284 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 29 Jul 2025 08:44:42 +0200 Subject: [PATCH 027/123] Update API This adds changes from `npm api`. --- src/store/cockpit/composerCloudApi.ts | 1 + src/store/service/imageBuilderApi.ts | 16 ++++++++-------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/src/store/cockpit/composerCloudApi.ts b/src/store/cockpit/composerCloudApi.ts index 23ef7545..36be0f46 100644 --- a/src/store/cockpit/composerCloudApi.ts +++ b/src/store/cockpit/composerCloudApi.ts @@ -134,6 +134,7 @@ export type ImageTypes = | "azure-cvm" | "azure-eap7-rhui" | "azure-rhui" + | "azure-sapapps-rhui" | "azure-sap-rhui" | "edge-commit" | "edge-container" diff --git a/src/store/service/imageBuilderApi.ts b/src/store/service/imageBuilderApi.ts index 1db44d17..58144231 100644 --- a/src/store/service/imageBuilderApi.ts +++ b/src/store/service/imageBuilderApi.ts @@ -550,13 +550,6 @@ export type OsTree = { */ rhsm?: boolean | undefined; }; -export type AapRegistration = { - ansible_callback_url: string; - host_config_key: string; - tls_certificate_authority?: string | undefined; - /** When true, indicates the user has confirmed that HTTPS callback URL does not require a CA certificate for verification */ - skip_tls_verification?: boolean | undefined; -}; export type ImageRequest = { /** CPU architecture of the image, x86_64 and aarch64 are currently supported. */ @@ -582,7 +575,6 @@ export type ImageRequest = { /** Name of the content template. Used when registering the system to Insights. */ content_template_name?: string | undefined; - aap_registration?: AapRegistration | undefined; }; export type Container = { /** Reference to the container to embed */ @@ -830,6 +822,13 @@ export type Installer = { export type CaCertsCustomization = { pem_certs: string[]; }; +export type AapRegistration = { + ansible_callback_url: string; + host_config_key: string; + tls_certificate_authority?: string | undefined; + /** When true, indicates the user has confirmed that HTTPS callback URL does not require a CA certificate for verification */ + skip_tls_verification?: boolean | undefined; +}; export type Customizations = { containers?: Container[] | undefined; directories?: Directory[] | undefined; @@ -872,6 +871,7 @@ export type Customizations = { fips?: Fips | undefined; installer?: Installer | undefined; cacerts?: CaCertsCustomization | undefined; + aap_registration?: AapRegistration | undefined; }; export type BlueprintMetadata = { parent_id: string | null; From 2c3efe4c04850cf3466994c1ae8bbfe0ebb86625 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Mon, 28 Jul 2025 15:25:24 +0200 Subject: [PATCH 028/123] Wizard: Resolve FSC lint warnings This resolves lint warnings for File System Configuration step. --- .../steps/FileSystem/components/FileSystemConfiguration.tsx | 4 ++-- .../steps/FileSystem/components/FileSystemTable.tsx | 2 +- src/Components/CreateImageWizard/steps/FileSystem/index.tsx | 5 ++--- .../CreateImageWizard/steps/Review/ReviewStepTextLists.tsx | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx index dd24d4f8..763577dd 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx @@ -58,8 +58,8 @@ const FileSystemConfiguration = () => { <Content> <Content component={ContentVariants.h3}>Configure partitions</Content> </Content> - {partitions?.find((partition) => - partition?.mountpoint?.includes('/usr') + {partitions.find((partition) => + partition.mountpoint.includes('/usr') ) && <UsrSubDirectoriesDisabled />} <Content> <Content> diff --git a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx index 93e3aa76..4e269537 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx @@ -520,7 +520,7 @@ const FileSystemTable = () => { onDragLeave={onDragLeave} ref={bodyRef} > - {partitions && + {partitions.length > 0 && partitions.map((partition) => ( <Row onDrop={onDrop} diff --git a/src/Components/CreateImageWizard/steps/FileSystem/index.tsx b/src/Components/CreateImageWizard/steps/FileSystem/index.tsx index 5aae227e..39b3fb0d 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/index.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/index.tsx @@ -9,6 +9,7 @@ import FileSystemPartition from './components/FileSystemPartition'; import { useAppSelector } from '../../../../store/hooks'; import { selectFileSystemConfigurationType } from '../../../../store/wizardSlice'; import { useHasSpecificTargetOnly } from '../../utilities/hasSpecificTargetOnly'; + export type FileSystemConfigurationType = 'automatic' | 'manual'; const FileSystemStep = () => { @@ -30,13 +31,11 @@ const FileSystemStep = () => { <FileSystemPartition /> <FileSystemAutomaticPartition /> </> - ) : fileSystemConfigurationType === 'manual' ? ( + ) : ( <> <FileSystemPartition /> <FileSystemConfiguration /> </> - ) : ( - fileSystemConfigurationType === 'oscap' && <FileSystemConfiguration /> )} </Form> ); diff --git a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx index 03fc4b01..ce0c76ec 100644 --- a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx +++ b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx @@ -202,7 +202,7 @@ type MinSizeProps = { export const MinSize = ({ partitions }: MinSizeProps) => { let minSize = ''; - if (partitions) { + if (partitions.length > 0) { let size = 0; for (const partition of partitions) { size += Number(partition.min_size) * getConversionFactor(partition.unit); From e52b43bdb794da2b69e82bb90ab399a84bab2fe8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 29 Jul 2025 08:18:07 +0000 Subject: [PATCH 029/123] build(deps): bump @redhat-cloud-services/frontend-components-notifications Bumps [@redhat-cloud-services/frontend-components-notifications](https://github.com/RedHatInsights/frontend-components) from 6.1.0 to 6.1.1. - [Release notes](https://github.com/RedHatInsights/frontend-components/releases) - [Changelog](https://github.com/RedHatInsights/frontend-components/blob/master/CHANGELOG.md) - [Commits](https://github.com/RedHatInsights/frontend-components/compare/@redhat-cloud-services/frontend-components-notifications-6.1.0...@redhat-cloud-services/frontend-components-notifications-6.1.1) --- updated-dependencies: - dependency-name: "@redhat-cloud-services/frontend-components-notifications" dependency-version: 6.1.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index a27960fd..a0f515dc 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,7 +15,7 @@ "@patternfly/react-core": "6.1.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", - "@redhat-cloud-services/frontend-components-notifications": "6.1.0", + "@redhat-cloud-services/frontend-components-notifications": "6.1.1", "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", @@ -4220,9 +4220,9 @@ } }, "node_modules/@redhat-cloud-services/frontend-components-notifications": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.0.tgz", - "integrity": "sha512-8jsS5VfuZvfCHQDRqW6vKvukBt7Oral3nCO/hhNv1WxxN9fZvLZbPV8OvYFK/50ekLvK5upFoXYFRU9Lbawb8w==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.1.tgz", + "integrity": "sha512-pP0KCFdWnOoVO2IWwcqKv+MOJvoZCWX9wxS+ejdvGzaTbu2CZb+w6E1hCL9O7MWdWatUSxtdOWtpbTsbPKt3nw==", "license": "Apache-2.0", "dependencies": { "@redhat-cloud-services/frontend-components": "^6.0.0", @@ -22637,9 +22637,9 @@ } }, "@redhat-cloud-services/frontend-components-notifications": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.0.tgz", - "integrity": "sha512-8jsS5VfuZvfCHQDRqW6vKvukBt7Oral3nCO/hhNv1WxxN9fZvLZbPV8OvYFK/50ekLvK5upFoXYFRU9Lbawb8w==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.1.tgz", + "integrity": "sha512-pP0KCFdWnOoVO2IWwcqKv+MOJvoZCWX9wxS+ejdvGzaTbu2CZb+w6E1hCL9O7MWdWatUSxtdOWtpbTsbPKt3nw==", "requires": { "@redhat-cloud-services/frontend-components": "^6.0.0", "@redhat-cloud-services/frontend-components-utilities": "^6.0.0" diff --git a/package.json b/package.json index ef822057..177af366 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "@patternfly/react-core": "6.1.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", - "@redhat-cloud-services/frontend-components-notifications": "6.1.0", + "@redhat-cloud-services/frontend-components-notifications": "6.1.1", "@redhat-cloud-services/frontend-components-utilities": "6.1.0", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", From a8f21a7a9093d41d153d8cb752c9649ba4475a26 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 29 Jul 2025 08:18:11 +0000 Subject: [PATCH 030/123] build(deps): bump @unleash/proxy-client-react from 5.0.0 to 5.0.1 Bumps [@unleash/proxy-client-react](https://github.com/Unleash/unleash-proxy-react) from 5.0.0 to 5.0.1. - [Release notes](https://github.com/Unleash/unleash-proxy-react/releases) - [Changelog](https://github.com/Unleash/proxy-client-react/blob/main/Changelog.md) - [Commits](https://github.com/Unleash/unleash-proxy-react/compare/v5.0.0...v5.0.1) --- updated-dependencies: - dependency-name: "@unleash/proxy-client-react" dependency-version: 5.0.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index a0f515dc..cb519517 100644 --- a/package-lock.json +++ b/package-lock.json @@ -20,7 +20,7 @@ "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", "@sentry/webpack-plugin": "4.0.1", - "@unleash/proxy-client-react": "5.0.0", + "@unleash/proxy-client-react": "5.0.1", "classnames": "2.5.1", "jwt-decode": "4.0.0", "lodash": "4.17.21", @@ -6085,9 +6085,9 @@ } }, "node_modules/@unleash/proxy-client-react": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/@unleash/proxy-client-react/-/proxy-client-react-5.0.0.tgz", - "integrity": "sha512-f00yLXSdA2ifB1RvqD1T4Il3Yk0CjVibKYS4cdOeLb6LhyH4kIeyJwtQO1slUrKRUy8VBt8Hmm2Rh1JEGlkfSQ==", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/@unleash/proxy-client-react/-/proxy-client-react-5.0.1.tgz", + "integrity": "sha512-F/IDo853ghZkGreLWg4fSVSM4NiLg5aZb1Kvr4vG29u5/PB0JLKNgNVdadt+qrlkI1GMzmP7IuFXSnv9A0McRw==", "license": "Apache-2.0", "engines": { "node": ">=16.0.0" @@ -23789,9 +23789,9 @@ } }, "@unleash/proxy-client-react": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/@unleash/proxy-client-react/-/proxy-client-react-5.0.0.tgz", - "integrity": "sha512-f00yLXSdA2ifB1RvqD1T4Il3Yk0CjVibKYS4cdOeLb6LhyH4kIeyJwtQO1slUrKRUy8VBt8Hmm2Rh1JEGlkfSQ==", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/@unleash/proxy-client-react/-/proxy-client-react-5.0.1.tgz", + "integrity": "sha512-F/IDo853ghZkGreLWg4fSVSM4NiLg5aZb1Kvr4vG29u5/PB0JLKNgNVdadt+qrlkI1GMzmP7IuFXSnv9A0McRw==", "requires": {} }, "@vitejs/plugin-react": { diff --git a/package.json b/package.json index 177af366..101f5874 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,7 @@ "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", "@sentry/webpack-plugin": "4.0.1", - "@unleash/proxy-client-react": "5.0.0", + "@unleash/proxy-client-react": "5.0.1", "classnames": "2.5.1", "jwt-decode": "4.0.0", "lodash": "4.17.21", From 8524e8e374998ddc918ee2e52aeb4829f5c43bdf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 29 Jul 2025 09:17:40 +0000 Subject: [PATCH 031/123] build(deps): bump @patternfly/react-core from 6.1.0 to 6.3.0 Bumps [@patternfly/react-core](https://github.com/patternfly/patternfly-react) from 6.1.0 to 6.3.0. - [Release notes](https://github.com/patternfly/patternfly-react/releases) - [Commits](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@6.1.0...@patternfly/react-core@6.3.0) --- updated-dependencies: - dependency-name: "@patternfly/react-core" dependency-version: 6.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 156 ++++++++++------------------------------------ package.json | 2 +- 2 files changed, 33 insertions(+), 125 deletions(-) diff --git a/package-lock.json b/package-lock.json index cb519517..228859e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,7 +12,7 @@ "@ltd/j-toml": "1.38.0", "@patternfly/patternfly": "6.3.0", "@patternfly/react-code-editor": "6.3.0", - "@patternfly/react-core": "6.1.0", + "@patternfly/react-core": "6.3.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", "@redhat-cloud-services/frontend-components-notifications": "6.1.1", @@ -3792,7 +3792,7 @@ "license": "MIT", "dependencies": { "@monaco-editor/react": "^4.6.0", - "@patternfly/react-core": "^6.3.0", + "@patternfly/react-core": "6.3.0", "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "react-dropzone": "14.3.5", @@ -3803,33 +3803,6 @@ "react-dom": "^17 || ^18 || ^19" } }, - "node_modules/@patternfly/react-code-editor/node_modules/@patternfly/react-core": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", - "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", - "license": "MIT", - "dependencies": { - "@patternfly/react-icons": "6.3.0", - "@patternfly/react-styles": "^6.3.0", - "@patternfly/react-tokens": "^6.3.0", - "focus-trap": "7.6.4", - "react-dropzone": "^14.3.5", - "tslib": "^2.8.1" - }, - "peerDependencies": { - "react": "^17 || ^18 || ^19", - "react-dom": "^17 || ^18 || ^19" - } - }, - "node_modules/@patternfly/react-code-editor/node_modules/focus-trap": { - "version": "7.6.4", - "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", - "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", - "license": "MIT", - "dependencies": { - "tabbable": "^6.2.0" - } - }, "node_modules/@patternfly/react-component-groups": { "version": "6.1.0", "resolved": "https://registry.npmjs.org/@patternfly/react-component-groups/-/react-component-groups-6.1.0.tgz", @@ -3848,21 +3821,21 @@ } }, "node_modules/@patternfly/react-core": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.1.0.tgz", - "integrity": "sha512-zj0lJPZxQanXKD8ae2kYnweT0kpp1CzpHYAkaBjTrw2k6ZMfr/UPlp0/ugCjWEokBqh79RUADLkKJJPce/yoSQ==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", + "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", "license": "MIT", "dependencies": { - "@patternfly/react-icons": "^6.1.0", - "@patternfly/react-styles": "^6.1.0", - "@patternfly/react-tokens": "^6.1.0", - "focus-trap": "7.6.2", + "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-styles": "^6.3.0", + "@patternfly/react-tokens": "^6.3.0", + "focus-trap": "7.6.4", "react-dropzone": "^14.3.5", "tslib": "^2.8.1" }, "peerDependencies": { - "react": "^17 || ^18", - "react-dom": "^17 || ^18" + "react": "^17 || ^18 || ^19", + "react-dom": "^17 || ^18 || ^19" } }, "node_modules/@patternfly/react-icons": { @@ -3887,7 +3860,7 @@ "integrity": "sha512-klC0HKZvKhrRRJX8j1bLmfvzJyMeqpwbKeV7np9Ggvvh79IxWpBBKX2XbJkjHtl+sCwIVN1VZatil3HGba5CZQ==", "license": "MIT", "dependencies": { - "@patternfly/react-core": "^6.3.0", + "@patternfly/react-core": "6.3.0", "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", @@ -3899,33 +3872,6 @@ "react-dom": "^17 || ^18 || ^19" } }, - "node_modules/@patternfly/react-table/node_modules/@patternfly/react-core": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", - "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", - "license": "MIT", - "dependencies": { - "@patternfly/react-icons": "6.3.0", - "@patternfly/react-styles": "^6.3.0", - "@patternfly/react-tokens": "^6.3.0", - "focus-trap": "7.6.4", - "react-dropzone": "^14.3.5", - "tslib": "^2.8.1" - }, - "peerDependencies": { - "react": "^17 || ^18 || ^19", - "react-dom": "^17 || ^18 || ^19" - } - }, - "node_modules/@patternfly/react-table/node_modules/focus-trap": { - "version": "7.6.4", - "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", - "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", - "license": "MIT", - "dependencies": { - "tabbable": "^6.2.0" - } - }, "node_modules/@patternfly/react-tokens": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/@patternfly/react-tokens/-/react-tokens-6.3.0.tgz", @@ -10611,7 +10557,9 @@ "license": "ISC" }, "node_modules/focus-trap": { - "version": "7.6.2", + "version": "7.6.4", + "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", + "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", "license": "MIT", "dependencies": { "tabbable": "^6.2.0" @@ -18000,6 +17948,8 @@ }, "node_modules/tabbable": { "version": "6.2.0", + "resolved": "https://registry.npmjs.org/tabbable/-/tabbable-6.2.0.tgz", + "integrity": "sha512-Cat63mxsVJlzYvN51JmVXIgNoUokrIaT2zLclCXjRd8boZ0004U4KCs/sToJ75C6sdlByWxpYnb5Boif1VSFew==", "license": "MIT" }, "node_modules/table": { @@ -22355,34 +22305,11 @@ "integrity": "sha512-2G0LId2KuuMcFZJRLDcRMfMHWRFG/sbMPXyD8yIi/2LPtAh/JFHbbDCzQXveQzaFhwXxVyVdCrCmbgn4SDYDlQ==", "requires": { "@monaco-editor/react": "^4.6.0", - "@patternfly/react-core": "^6.3.0", + "@patternfly/react-core": "6.3.0", "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "react-dropzone": "14.3.5", "tslib": "^2.8.1" - }, - "dependencies": { - "@patternfly/react-core": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", - "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", - "requires": { - "@patternfly/react-icons": "6.3.0", - "@patternfly/react-styles": "^6.3.0", - "@patternfly/react-tokens": "^6.3.0", - "focus-trap": "7.6.4", - "react-dropzone": "^14.3.5", - "tslib": "^2.8.1" - } - }, - "focus-trap": { - "version": "7.6.4", - "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", - "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", - "requires": { - "tabbable": "^6.2.0" - } - } } }, "@patternfly/react-component-groups": { @@ -22398,14 +22325,14 @@ } }, "@patternfly/react-core": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.1.0.tgz", - "integrity": "sha512-zj0lJPZxQanXKD8ae2kYnweT0kpp1CzpHYAkaBjTrw2k6ZMfr/UPlp0/ugCjWEokBqh79RUADLkKJJPce/yoSQ==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", + "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", "requires": { - "@patternfly/react-icons": "^6.1.0", - "@patternfly/react-styles": "^6.1.0", - "@patternfly/react-tokens": "^6.1.0", - "focus-trap": "7.6.2", + "@patternfly/react-icons": "^6.3.0", + "@patternfly/react-styles": "^6.3.0", + "@patternfly/react-tokens": "^6.3.0", + "focus-trap": "7.6.4", "react-dropzone": "^14.3.5", "tslib": "^2.8.1" } @@ -22426,35 +22353,12 @@ "resolved": "https://registry.npmjs.org/@patternfly/react-table/-/react-table-6.3.0.tgz", "integrity": "sha512-klC0HKZvKhrRRJX8j1bLmfvzJyMeqpwbKeV7np9Ggvvh79IxWpBBKX2XbJkjHtl+sCwIVN1VZatil3HGba5CZQ==", "requires": { - "@patternfly/react-core": "^6.3.0", + "@patternfly/react-core": "6.3.0", "@patternfly/react-icons": "6.3.0", "@patternfly/react-styles": "^6.3.0", "@patternfly/react-tokens": "^6.3.0", "lodash": "^4.17.21", "tslib": "^2.8.1" - }, - "dependencies": { - "@patternfly/react-core": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/@patternfly/react-core/-/react-core-6.3.0.tgz", - "integrity": "sha512-TM+pLwLd5DzaDlOQhqeju9H9QUFQypQiNwXQLNIxOV5r3fmKh4NTp2Av/8WmFkpCj8mejDOfp4TNxoU1zdjCkQ==", - "requires": { - "@patternfly/react-icons": "6.3.0", - "@patternfly/react-styles": "^6.3.0", - "@patternfly/react-tokens": "^6.3.0", - "focus-trap": "7.6.4", - "react-dropzone": "^14.3.5", - "tslib": "^2.8.1" - } - }, - "focus-trap": { - "version": "7.6.4", - "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", - "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", - "requires": { - "tabbable": "^6.2.0" - } - } } }, "@patternfly/react-tokens": { @@ -26748,7 +26652,9 @@ "dev": true }, "focus-trap": { - "version": "7.6.2", + "version": "7.6.4", + "resolved": "https://registry.npmjs.org/focus-trap/-/focus-trap-7.6.4.tgz", + "integrity": "sha512-xx560wGBk7seZ6y933idtjJQc1l+ck+pI3sKvhKozdBV1dRZoKhkW5xoCaFv9tQiX5RH1xfSxjuNu6g+lmN/gw==", "requires": { "tabbable": "^6.2.0" } @@ -31431,7 +31337,9 @@ } }, "tabbable": { - "version": "6.2.0" + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/tabbable/-/tabbable-6.2.0.tgz", + "integrity": "sha512-Cat63mxsVJlzYvN51JmVXIgNoUokrIaT2zLclCXjRd8boZ0004U4KCs/sToJ75C6sdlByWxpYnb5Boif1VSFew==" }, "table": { "version": "6.9.0", diff --git a/package.json b/package.json index 101f5874..312425d5 100644 --- a/package.json +++ b/package.json @@ -10,7 +10,7 @@ "@ltd/j-toml": "1.38.0", "@patternfly/patternfly": "6.3.0", "@patternfly/react-code-editor": "6.3.0", - "@patternfly/react-core": "6.1.0", + "@patternfly/react-core": "6.3.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", "@redhat-cloud-services/frontend-components-notifications": "6.1.1", From 09febf80612f41d537fab97b4f15465815ef6bf1 Mon Sep 17 00:00:00 2001 From: "red-hat-konflux[bot]" <126015336+red-hat-konflux[bot]@users.noreply.github.com> Date: Tue, 29 Jul 2025 05:40:00 +0000 Subject: [PATCH 032/123] chore(deps): update build-tools digest to 37ab5d0 Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com> --- build-tools | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-tools b/build-tools index 07aeb0dd..37ab5d09 160000 --- a/build-tools +++ b/build-tools @@ -1 +1 @@ -Subproject commit 07aeb0dd02b76bd1c9c309b8ec0e96893e0ebe49 +Subproject commit 37ab5d095e703e5d34e3f02f1040ab5b002d56fe From 730554dc84afc6787dacb193d0e73d51f608057b Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 29 Jul 2025 13:25:57 +0200 Subject: [PATCH 033/123] Wizard: Add fetch and error state or target environments This renders an empty state with a spinner when fetching target environments and alert when there's an issue. --- .../components/TargetEnvironment.tsx | 30 +++++++++++++++---- .../steps/Services/Services.test.tsx | 2 -- 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx index e6b121dc..029f7678 100644 --- a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx +++ b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx @@ -1,16 +1,19 @@ import React, { MouseEventHandler, useEffect } from 'react'; import { + Alert, Button, Card, CardHeader, Checkbox, Content, + EmptyState, Flex, FlexItem, FormGroup, Gallery, Popover, + Spinner, Title, } from '@patternfly/react-core'; import { ExternalLinkAltIcon, HelpIcon } from '@patternfly/react-icons'; @@ -92,11 +95,9 @@ const TargetEnvironment = () => { const environments = useAppSelector(selectImageTypes); const distribution = useAppSelector(selectDistribution); - const { data } = useGetArchitecturesQuery({ + const { data, isFetching, isError } = useGetArchitecturesQuery({ distribution: distribution, }); - // TODO: Handle isFetching state (add skeletons) - // TODO: Handle isError state (very unlikely...) const dispatch = useAppDispatch(); const prefetchSources = provisioningApi.usePrefetch('getSourceList'); @@ -104,6 +105,9 @@ const TargetEnvironment = () => { useEffect(() => { prefetchActivationKeys(); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps }, []); const supportedEnvironments = data?.find( @@ -137,6 +141,22 @@ const TargetEnvironment = () => { ); }; + if (isFetching) { + return <EmptyState titleText="Loading target environments" headingLevel="h6" icon={Spinner} /> + }; + + if (isError) { + return ( + <Alert + title="Couldn't fetch target environments" + variant="danger" + isInline + > + Target environments couldn't be loaded, please refresh the page or try again later. + </Alert> + ) + }; + return ( <FormGroup isRequired={true} @@ -200,7 +220,7 @@ const TargetEnvironment = () => { label={<small>Private cloud</small>} className="pf-v6-u-mt-sm" > - {supportedEnvironments?.includes('vsphere-ova') && ( + {supportedEnvironments.includes('vsphere-ova') && ( <Checkbox name="vsphere-checkbox-ova" aria-label="VMware vSphere checkbox OVA" @@ -239,7 +259,7 @@ const TargetEnvironment = () => { isChecked={environments.includes('vsphere-ova')} /> )} - {supportedEnvironments?.includes('vsphere') && ( + {supportedEnvironments.includes('vsphere') && ( <Checkbox className="pf-v6-u-mt-sm" name="vsphere-checkbox-vmdk" diff --git a/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx b/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx index 8a2c9106..0255fdc5 100644 --- a/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx @@ -360,5 +360,3 @@ describe('Services edit mode', () => { expect(receivedRequest).toEqual(expectedRequest); }); }); - -// TO DO 'Services step' -> 'revisit step button on Review works' From d5877b256c33b1d54cffd1a774ba164632b42afe Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 29 Jul 2025 13:59:10 +0200 Subject: [PATCH 034/123] test: Add test for failing fetching of target environments This adds a test to check that the appropriate alert gets rendered. --- .../steps/ImageOutput/ImageOutput.test.tsx | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx b/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx index 51cf6452..ab295707 100644 --- a/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx @@ -1,12 +1,14 @@ import type { Router as RemixRouter } from '@remix-run/router'; import { screen, waitFor, within } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; +import { http, HttpResponse } from 'msw'; import { AARCH64, CENTOS_9, CREATE_BLUEPRINT, EDIT_BLUEPRINT, + IMAGE_BUILDER_API, RHEL_10, RHEL_8, RHEL_9, @@ -25,6 +27,7 @@ import { rhel9CreateBlueprintRequest, x86_64CreateBlueprintRequest, } from '../../../../fixtures/editMode'; +import { server } from '../../../../mocks/server'; import { blueprintRequest, clickNext, @@ -310,6 +313,17 @@ describe('Step Image output', () => { await clickNext(); // Review await verifyNameInReviewStep('Red Velvet'); }); + + test('alert gets rendered when fetching target environments fails', async () => { + server.use( + http.get(`${IMAGE_BUILDER_API}/architectures/${RHEL_10}`, () => { + return new HttpResponse(null, { status: 404 }); + }) + ); + + await renderCreateMode(); + await screen.findByText(/Couldn't fetch target environments/); + }); }); describe('Check that the target filtering is in accordance to mock content', () => { From c026102dd3a674fa79a7ec6f646bfd135a2a8d01 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anna=20V=C3=ADtov=C3=A1?= <avitova@redhat.com> Date: Thu, 5 Jun 2025 14:50:32 +0200 Subject: [PATCH 035/123] Compliance: refactor clearPackage duplicate --- .../steps/Oscap/components/PolicySelector.tsx | 13 +++++-------- .../steps/Oscap/components/ProfileSelector.tsx | 14 +++++--------- .../Oscap/components/useSelectorHandlers.tsx | 16 ++++++++++++++++ 3 files changed, 26 insertions(+), 17 deletions(-) create mode 100644 src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx index 2b225a27..e9b40f0a 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx @@ -9,6 +9,8 @@ import { } from '@patternfly/react-core'; import { v4 as uuidv4 } from 'uuid'; +import { useSelectorHandlers } from './useSelectorHandlers'; + import { PolicyRead, usePoliciesQuery, @@ -91,6 +93,7 @@ const PolicySelector = () => { const hasWslTargetOnly = useHasSpecificTargetOnly('wsl'); const dispatch = useAppDispatch(); const [isOpen, setIsOpen] = useState(false); + const { clearCompliancePackages } = useSelectorHandlers(); const { data: policies, @@ -143,7 +146,7 @@ const PolicySelector = () => { policyTitle: undefined, }) ); - clearOscapPackages(currentProfileData?.packages || []); + clearCompliancePackages(currentProfileData?.packages || []); dispatch(changeFileSystemConfigurationType('automatic')); handleServices(undefined); dispatch(clearKernelAppend()); @@ -153,7 +156,7 @@ const PolicySelector = () => { oldOscapPackages: string[], newOscapPackages: string[] ) => { - clearOscapPackages(oldOscapPackages); + clearCompliancePackages(oldOscapPackages); for (const pkg of newOscapPackages) { dispatch( @@ -166,12 +169,6 @@ const PolicySelector = () => { } }; - const clearOscapPackages = (oscapPackages: string[]) => { - for (const pkg of oscapPackages) { - dispatch(removePackage(pkg)); - } - }; - const handlePartitions = (oscapPartitions: Filesystem[]) => { dispatch(clearPartitions()); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index b7a755ab..360e7a06 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -17,6 +17,8 @@ import { import { TimesIcon } from '@patternfly/react-icons'; import { v4 as uuidv4 } from 'uuid'; +import { useSelectorHandlers } from './useSelectorHandlers'; + import { useBackendPrefetch, useGetOscapCustomizationsQuery, @@ -42,7 +44,6 @@ import { changeMaskedServices, clearKernelAppend, clearPartitions, - removePackage, selectComplianceProfileID, selectComplianceType, selectDistribution, @@ -81,6 +82,7 @@ const ProfileSelector = () => { >([]); const complianceType = useAppSelector(selectComplianceType); const prefetchProfile = useBackendPrefetch('getOscapCustomizations'); + const { clearCompliancePackages } = useSelectorHandlers(); const { data: profiles, @@ -181,7 +183,7 @@ const ProfileSelector = () => { policyTitle: undefined, }) ); - clearOscapPackages(currentProfileData?.packages || []); + clearCompliancePackages(currentProfileData?.packages || []); dispatch(changeFileSystemConfigurationType('automatic')); handleServices(undefined); dispatch(clearKernelAppend()); @@ -193,7 +195,7 @@ const ProfileSelector = () => { oldOscapPackages: string[], newOscapPackages: string[] ) => { - clearOscapPackages(oldOscapPackages); + clearCompliancePackages(oldOscapPackages); for (const pkg of newOscapPackages) { dispatch( @@ -206,12 +208,6 @@ const ProfileSelector = () => { } }; - const clearOscapPackages = (oscapPackages: string[]) => { - for (const pkg of oscapPackages) { - dispatch(removePackage(pkg)); - } - }; - const handlePartitions = (oscapPartitions: Filesystem[]) => { dispatch(clearPartitions()); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx new file mode 100644 index 00000000..23941d8f --- /dev/null +++ b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx @@ -0,0 +1,16 @@ +import { useAppDispatch } from '../../../../../store/hooks'; +import { removePackage } from '../../../../../store/wizardSlice'; + +export const useSelectorHandlers = () => { + const dispatch = useAppDispatch(); + + const clearCompliancePackages = (oscapPackages: string[]) => { + for (const pkg of oscapPackages) { + dispatch(removePackage(pkg)); + } + }; + + return { + clearCompliancePackages, + }; +}; From 128abcb98fa39be2544f2f40f433505b4da8bf83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anna=20V=C3=ADtov=C3=A1?= <avitova@redhat.com> Date: Thu, 5 Jun 2025 14:58:19 +0200 Subject: [PATCH 036/123] Compliance: refactor handlePackages duplicate --- .../steps/Oscap/components/PolicySelector.tsx | 26 +++++-------------- .../Oscap/components/ProfileSelector.tsx | 25 +++++------------- .../Oscap/components/useSelectorHandlers.tsx | 21 ++++++++++++++- 3 files changed, 32 insertions(+), 40 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx index e9b40f0a..774efb21 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx @@ -24,7 +24,6 @@ import { } from '../../../../../store/imageBuilderApi'; import { addKernelArg, - addPackage, addPartition, changeCompliance, changeDisabledServices, @@ -93,7 +92,7 @@ const PolicySelector = () => { const hasWslTargetOnly = useHasSpecificTargetOnly('wsl'); const dispatch = useAppDispatch(); const [isOpen, setIsOpen] = useState(false); - const { clearCompliancePackages } = useSelectorHandlers(); + const { clearCompliancePackages, handlePackages } = useSelectorHandlers(); const { data: policies, @@ -152,23 +151,6 @@ const PolicySelector = () => { dispatch(clearKernelAppend()); }; - const handlePackages = ( - oldOscapPackages: string[], - newOscapPackages: string[] - ) => { - clearCompliancePackages(oldOscapPackages); - - for (const pkg of newOscapPackages) { - dispatch( - addPackage({ - name: pkg, - summary: 'Required by chosen compliance policy', - repository: 'distro', - }) - ); - } - }; - const handlePartitions = (oscapPartitions: Filesystem[]) => { dispatch(clearPartitions()); @@ -226,7 +208,11 @@ const PolicySelector = () => { const oscapPartitions = response.filesystem || []; const newOscapPackages = response.packages || []; handlePartitions(oscapPartitions); - handlePackages(oldOscapPackages, newOscapPackages); + handlePackages( + oldOscapPackages, + newOscapPackages, + 'Required by chosen compliance policy' + ); handleServices(response.services); handleKernelAppend(response.kernel?.append); dispatch( diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index 360e7a06..0c469db1 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -82,7 +82,7 @@ const ProfileSelector = () => { >([]); const complianceType = useAppSelector(selectComplianceType); const prefetchProfile = useBackendPrefetch('getOscapCustomizations'); - const { clearCompliancePackages } = useSelectorHandlers(); + const { clearCompliancePackages, handlePackages } = useSelectorHandlers(); const { data: profiles, @@ -191,23 +191,6 @@ const ProfileSelector = () => { setFilterValue(''); }; - const handlePackages = ( - oldOscapPackages: string[], - newOscapPackages: string[] - ) => { - clearCompliancePackages(oldOscapPackages); - - for (const pkg of newOscapPackages) { - dispatch( - addPackage({ - name: pkg, - summary: 'Required by chosen OpenSCAP profile', - repository: 'distro', - }) - ); - } - }; - const handlePartitions = (oscapPartitions: Filesystem[]) => { dispatch(clearPartitions()); @@ -309,7 +292,11 @@ const ProfileSelector = () => { const oscapPartitions = response.filesystem || []; const newOscapPackages = response.packages || []; handlePartitions(oscapPartitions); - handlePackages(oldOscapPackages, newOscapPackages); + handlePackages( + oldOscapPackages, + newOscapPackages, + 'Required by chosen OpenSCAP profile' + ); handleServices(response.services); handleKernelAppend(response.kernel?.append); dispatch( diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx index 23941d8f..1d81249d 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx @@ -1,5 +1,5 @@ import { useAppDispatch } from '../../../../../store/hooks'; -import { removePackage } from '../../../../../store/wizardSlice'; +import { addPackage, removePackage } from '../../../../../store/wizardSlice'; export const useSelectorHandlers = () => { const dispatch = useAppDispatch(); @@ -10,7 +10,26 @@ export const useSelectorHandlers = () => { } }; + const handlePackages = ( + oldOscapPackages: string[], + newOscapPackages: string[], + reason: string + ) => { + clearCompliancePackages(oldOscapPackages); + + for (const pkg of newOscapPackages) { + dispatch( + addPackage({ + name: pkg, + summary: reason, + repository: 'distro', + }) + ); + } + }; + return { clearCompliancePackages, + handlePackages, }; }; From 9da490ad525624b111c5cb19864c7d2945b03587 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anna=20V=C3=ADtov=C3=A1?= <avitova@redhat.com> Date: Thu, 5 Jun 2025 15:03:20 +0200 Subject: [PATCH 037/123] Compliance: refactor handleServices duplicate --- .../steps/Oscap/components/PolicySelector.tsx | 14 ++------------ .../steps/Oscap/components/ProfileSelector.tsx | 14 ++------------ .../Oscap/components/useSelectorHandlers.tsx | 16 +++++++++++++++- 3 files changed, 19 insertions(+), 25 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx index 774efb21..7b11e7f4 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx @@ -18,7 +18,6 @@ import { import { useAppDispatch, useAppSelector } from '../../../../../store/hooks'; import { Filesystem, - Services, useGetOscapCustomizationsForPolicyQuery, useLazyGetOscapCustomizationsForPolicyQuery, } from '../../../../../store/imageBuilderApi'; @@ -26,13 +25,9 @@ import { addKernelArg, addPartition, changeCompliance, - changeDisabledServices, - changeEnabledServices, changeFileSystemConfigurationType, - changeMaskedServices, clearKernelAppend, clearPartitions, - removePackage, selectCompliancePolicyID, selectCompliancePolicyTitle, selectDistribution, @@ -92,7 +87,8 @@ const PolicySelector = () => { const hasWslTargetOnly = useHasSpecificTargetOnly('wsl'); const dispatch = useAppDispatch(); const [isOpen, setIsOpen] = useState(false); - const { clearCompliancePackages, handlePackages } = useSelectorHandlers(); + const { clearCompliancePackages, handlePackages, handleServices } = + useSelectorHandlers(); const { data: policies, @@ -173,12 +169,6 @@ const PolicySelector = () => { } }; - const handleServices = (services: Services | undefined) => { - dispatch(changeEnabledServices(services?.enabled || [])); - dispatch(changeMaskedServices(services?.masked || [])); - dispatch(changeDisabledServices(services?.disabled || [])); - }; - const handleKernelAppend = (kernelAppend: string | undefined) => { dispatch(clearKernelAppend()); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index 0c469db1..f6f6f1df 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -31,17 +31,12 @@ import { Filesystem, OpenScap, OpenScapProfile, - Services, } from '../../../../../store/imageBuilderApi'; import { addKernelArg, - addPackage, addPartition, changeCompliance, - changeDisabledServices, - changeEnabledServices, changeFileSystemConfigurationType, - changeMaskedServices, clearKernelAppend, clearPartitions, selectComplianceProfileID, @@ -82,7 +77,8 @@ const ProfileSelector = () => { >([]); const complianceType = useAppSelector(selectComplianceType); const prefetchProfile = useBackendPrefetch('getOscapCustomizations'); - const { clearCompliancePackages, handlePackages } = useSelectorHandlers(); + const { clearCompliancePackages, handlePackages, handleServices } = + useSelectorHandlers(); const { data: profiles, @@ -213,12 +209,6 @@ const ProfileSelector = () => { } }; - const handleServices = (services: Services | undefined) => { - dispatch(changeEnabledServices(services?.enabled || [])); - dispatch(changeMaskedServices(services?.masked || [])); - dispatch(changeDisabledServices(services?.disabled || [])); - }; - const handleKernelAppend = (kernelAppend: string | undefined) => { dispatch(clearKernelAppend()); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx index 1d81249d..c5cca3da 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx @@ -1,5 +1,12 @@ import { useAppDispatch } from '../../../../../store/hooks'; -import { addPackage, removePackage } from '../../../../../store/wizardSlice'; +import { Services } from '../../../../../store/imageBuilderApi'; +import { + addPackage, + changeDisabledServices, + changeEnabledServices, + changeMaskedServices, + removePackage, +} from '../../../../../store/wizardSlice'; export const useSelectorHandlers = () => { const dispatch = useAppDispatch(); @@ -28,8 +35,15 @@ export const useSelectorHandlers = () => { } }; + const handleServices = (services: Services | undefined) => { + dispatch(changeEnabledServices(services?.enabled || [])); + dispatch(changeMaskedServices(services?.masked || [])); + dispatch(changeDisabledServices(services?.disabled || [])); + }; + return { clearCompliancePackages, handlePackages, + handleServices, }; }; From 96da1817df28269a0b039175af84ce8425bea0c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anna=20V=C3=ADtov=C3=A1?= <avitova@redhat.com> Date: Thu, 5 Jun 2025 15:08:37 +0200 Subject: [PATCH 038/123] Compliance: refactor handlePartitions duplicate --- .../steps/Oscap/components/PolicySelector.tsx | 36 ++++--------------- .../Oscap/components/ProfileSelector.tsx | 34 ++++-------------- .../Oscap/components/useSelectorHandlers.tsx | 32 ++++++++++++++++- 3 files changed, 43 insertions(+), 59 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx index 7b11e7f4..76e7b040 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx @@ -7,7 +7,6 @@ import { Select, SelectOption, } from '@patternfly/react-core'; -import { v4 as uuidv4 } from 'uuid'; import { useSelectorHandlers } from './useSelectorHandlers'; @@ -17,24 +16,19 @@ import { } from '../../../../../store/complianceApi'; import { useAppDispatch, useAppSelector } from '../../../../../store/hooks'; import { - Filesystem, useGetOscapCustomizationsForPolicyQuery, useLazyGetOscapCustomizationsForPolicyQuery, } from '../../../../../store/imageBuilderApi'; import { addKernelArg, - addPartition, changeCompliance, changeFileSystemConfigurationType, clearKernelAppend, - clearPartitions, selectCompliancePolicyID, selectCompliancePolicyTitle, selectDistribution, } from '../../../../../store/wizardSlice'; import { useHasSpecificTargetOnly } from '../../../utilities/hasSpecificTargetOnly'; -import { parseSizeUnit } from '../../../utilities/parseSizeUnit'; -import { Partition, Units } from '../../FileSystem/components/FileSystemTable'; import { removeBetaFromRelease } from '../removeBetaFromRelease'; type ComplianceSelectOptionPropType = { @@ -87,8 +81,12 @@ const PolicySelector = () => { const hasWslTargetOnly = useHasSpecificTargetOnly('wsl'); const dispatch = useAppDispatch(); const [isOpen, setIsOpen] = useState(false); - const { clearCompliancePackages, handlePackages, handleServices } = - useSelectorHandlers(); + const { + clearCompliancePackages, + handlePackages, + handlePartitions, + handleServices, + } = useSelectorHandlers(); const { data: policies, @@ -147,28 +145,6 @@ const PolicySelector = () => { dispatch(clearKernelAppend()); }; - const handlePartitions = (oscapPartitions: Filesystem[]) => { - dispatch(clearPartitions()); - - const newPartitions = oscapPartitions.map((filesystem) => { - const [size, unit] = parseSizeUnit(filesystem.min_size); - const partition: Partition = { - mountpoint: filesystem.mountpoint, - min_size: size.toString(), - unit: unit as Units, - id: uuidv4(), - }; - return partition; - }); - - if (newPartitions.length > 0) { - dispatch(changeFileSystemConfigurationType('manual')); - for (const partition of newPartitions) { - dispatch(addPartition(partition)); - } - } - }; - const handleKernelAppend = (kernelAppend: string | undefined) => { dispatch(clearKernelAppend()); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index f6f6f1df..bb12144e 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -15,7 +15,6 @@ import { TextInputGroupUtilities, } from '@patternfly/react-core'; import { TimesIcon } from '@patternfly/react-icons'; -import { v4 as uuidv4 } from 'uuid'; import { useSelectorHandlers } from './useSelectorHandlers'; @@ -28,17 +27,14 @@ import { import { useAppDispatch, useAppSelector } from '../../../../../store/hooks'; import { DistributionProfileItem, - Filesystem, OpenScap, OpenScapProfile, } from '../../../../../store/imageBuilderApi'; import { addKernelArg, - addPartition, changeCompliance, changeFileSystemConfigurationType, clearKernelAppend, - clearPartitions, selectComplianceProfileID, selectComplianceType, selectDistribution, @@ -77,8 +73,12 @@ const ProfileSelector = () => { >([]); const complianceType = useAppSelector(selectComplianceType); const prefetchProfile = useBackendPrefetch('getOscapCustomizations'); - const { clearCompliancePackages, handlePackages, handleServices } = - useSelectorHandlers(); + const { + clearCompliancePackages, + handlePackages, + handlePartitions, + handleServices, + } = useSelectorHandlers(); const { data: profiles, @@ -187,28 +187,6 @@ const ProfileSelector = () => { setFilterValue(''); }; - const handlePartitions = (oscapPartitions: Filesystem[]) => { - dispatch(clearPartitions()); - - const newPartitions = oscapPartitions.map((filesystem) => { - const [size, unit] = parseSizeUnit(filesystem.min_size); - const partition: Partition = { - mountpoint: filesystem.mountpoint, - min_size: size.toString(), - unit: unit as Units, - id: uuidv4(), - }; - return partition; - }); - - if (newPartitions.length > 0) { - dispatch(changeFileSystemConfigurationType('manual')); - for (const partition of newPartitions) { - dispatch(addPartition(partition)); - } - } - }; - const handleKernelAppend = (kernelAppend: string | undefined) => { dispatch(clearKernelAppend()); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx index c5cca3da..9b58948c 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx @@ -1,12 +1,19 @@ +import { v4 as uuidv4 } from 'uuid'; + import { useAppDispatch } from '../../../../../store/hooks'; -import { Services } from '../../../../../store/imageBuilderApi'; +import { Filesystem, Services } from '../../../../../store/imageBuilderApi'; import { addPackage, + addPartition, changeDisabledServices, changeEnabledServices, + changeFileSystemConfigurationType, changeMaskedServices, + clearPartitions, removePackage, } from '../../../../../store/wizardSlice'; +import { parseSizeUnit } from '../../../utilities/parseSizeUnit'; +import { Partition, Units } from '../../FileSystem/components/FileSystemTable'; export const useSelectorHandlers = () => { const dispatch = useAppDispatch(); @@ -35,6 +42,28 @@ export const useSelectorHandlers = () => { } }; + const handlePartitions = (oscapPartitions: Filesystem[]) => { + dispatch(clearPartitions()); + + const newPartitions = oscapPartitions.map((filesystem) => { + const [size, unit] = parseSizeUnit(filesystem.min_size); + const partition: Partition = { + mountpoint: filesystem.mountpoint, + min_size: size.toString(), + unit: unit as Units, + id: uuidv4(), + }; + return partition; + }); + + if (newPartitions.length > 0) { + dispatch(changeFileSystemConfigurationType('manual')); + for (const partition of newPartitions) { + dispatch(addPartition(partition)); + } + } + }; + const handleServices = (services: Services | undefined) => { dispatch(changeEnabledServices(services?.enabled || [])); dispatch(changeMaskedServices(services?.masked || [])); @@ -45,5 +74,6 @@ export const useSelectorHandlers = () => { clearCompliancePackages, handlePackages, handleServices, + handlePartitions, }; }; From cfa8cbcb28dc1b3ef0720fab8e970a0c9aa458ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anna=20V=C3=ADtov=C3=A1?= <avitova@redhat.com> Date: Thu, 5 Jun 2025 15:13:15 +0200 Subject: [PATCH 039/123] Compliance: refactor handleKernelAppend duplicate --- .../steps/Oscap/components/PolicySelector.tsx | 13 +------------ .../steps/Oscap/components/ProfileSelector.tsx | 15 +-------------- .../Oscap/components/useSelectorHandlers.tsx | 14 ++++++++++++++ 3 files changed, 16 insertions(+), 26 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx index 76e7b040..25586d37 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx @@ -20,7 +20,6 @@ import { useLazyGetOscapCustomizationsForPolicyQuery, } from '../../../../../store/imageBuilderApi'; import { - addKernelArg, changeCompliance, changeFileSystemConfigurationType, clearKernelAppend, @@ -83,6 +82,7 @@ const PolicySelector = () => { const [isOpen, setIsOpen] = useState(false); const { clearCompliancePackages, + handleKernelAppend, handlePackages, handlePartitions, handleServices, @@ -145,17 +145,6 @@ const PolicySelector = () => { dispatch(clearKernelAppend()); }; - const handleKernelAppend = (kernelAppend: string | undefined) => { - dispatch(clearKernelAppend()); - - if (kernelAppend) { - const kernelArgsArray = kernelAppend.split(' '); - for (const arg of kernelArgsArray) { - dispatch(addKernelArg(arg)); - } - } - }; - const applyChanges = (selection: ComplianceSelectOptionValueType) => { if (selection.policyID === undefined) { // handle user has selected 'None' case diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index bb12144e..64859ed5 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -31,7 +31,6 @@ import { OpenScapProfile, } from '../../../../../store/imageBuilderApi'; import { - addKernelArg, changeCompliance, changeFileSystemConfigurationType, clearKernelAppend, @@ -40,8 +39,6 @@ import { selectDistribution, } from '../../../../../store/wizardSlice'; import { useHasSpecificTargetOnly } from '../../../utilities/hasSpecificTargetOnly'; -import { parseSizeUnit } from '../../../utilities/parseSizeUnit'; -import { Partition, Units } from '../../FileSystem/components/FileSystemTable'; import { removeBetaFromRelease } from '../removeBetaFromRelease'; type OScapSelectOptionValueType = { @@ -75,6 +72,7 @@ const ProfileSelector = () => { const prefetchProfile = useBackendPrefetch('getOscapCustomizations'); const { clearCompliancePackages, + handleKernelAppend, handlePackages, handlePartitions, handleServices, @@ -187,17 +185,6 @@ const ProfileSelector = () => { setFilterValue(''); }; - const handleKernelAppend = (kernelAppend: string | undefined) => { - dispatch(clearKernelAppend()); - - if (kernelAppend) { - const kernelArgsArray = kernelAppend.split(' '); - for (const arg of kernelArgsArray) { - dispatch(addKernelArg(arg)); - } - } - }; - const onInputClick = () => { if (!isOpen) { setIsOpen(true); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx index 9b58948c..53fb74f1 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx @@ -3,12 +3,14 @@ import { v4 as uuidv4 } from 'uuid'; import { useAppDispatch } from '../../../../../store/hooks'; import { Filesystem, Services } from '../../../../../store/imageBuilderApi'; import { + addKernelArg, addPackage, addPartition, changeDisabledServices, changeEnabledServices, changeFileSystemConfigurationType, changeMaskedServices, + clearKernelAppend, clearPartitions, removePackage, } from '../../../../../store/wizardSlice'; @@ -24,6 +26,17 @@ export const useSelectorHandlers = () => { } }; + const handleKernelAppend = (kernelAppend: string | undefined) => { + dispatch(clearKernelAppend()); + + if (kernelAppend) { + const kernelArgsArray = kernelAppend.split(' '); + for (const arg of kernelArgsArray) { + dispatch(addKernelArg(arg)); + } + } + }; + const handlePackages = ( oldOscapPackages: string[], newOscapPackages: string[], @@ -72,6 +85,7 @@ export const useSelectorHandlers = () => { return { clearCompliancePackages, + handleKernelAppend, handlePackages, handleServices, handlePartitions, From ceec85209ca30e402b207eda6e7c7a24aba8fc77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anna=20V=C3=ADtov=C3=A1?= <avitova@redhat.com> Date: Tue, 29 Jul 2025 14:00:45 +0200 Subject: [PATCH 040/123] Playwright: OSCAP basic test not altering things added by OSCAP --- eslint.config.js | 6 + playwright/Customizations/OpenSCAP.spec.ts | 191 +++++++++++++++++++++ 2 files changed, 197 insertions(+) create mode 100644 playwright/Customizations/OpenSCAP.spec.ts diff --git a/eslint.config.js b/eslint.config.js index 269a5115..0f786976 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -151,6 +151,12 @@ module.exports = defineConfig([ ...pluginPlaywright.configs.recommended.rules, 'playwright/no-conditional-in-test': 'off', 'playwright/no-conditional-expect': 'off', + "playwright/no-skipped-test": [ + "error", + { + "allowConditional": true + } + ] }, }, ]); diff --git a/playwright/Customizations/OpenSCAP.spec.ts b/playwright/Customizations/OpenSCAP.spec.ts new file mode 100644 index 00000000..7784cc12 --- /dev/null +++ b/playwright/Customizations/OpenSCAP.spec.ts @@ -0,0 +1,191 @@ +import { expect } from '@playwright/test'; +import { v4 as uuidv4 } from 'uuid'; + +import { test } from '../fixtures/cleanup'; +import { isHosted } from '../helpers/helpers'; +import { ensureAuthenticated } from '../helpers/login'; +import { ibFrame, navigateToLandingPage } from '../helpers/navHelpers'; +import { + createBlueprint, + deleteBlueprint, + exportBlueprint, + fillInDetails, + fillInImageOutputGuest, + importBlueprint, + registerLater, +} from '../helpers/wizardHelpers'; + +test('Create a blueprint with OpenSCAP customization', async ({ + page, + cleanup, +}) => { + const blueprintName = 'test-' + uuidv4(); + test.skip(!isHosted(), 'Exporting is not available in the plugin'); + // Delete the blueprint after the run fixture + await cleanup.add(() => deleteBlueprint(page, blueprintName)); + + await ensureAuthenticated(page); + + // Navigate to IB landing page and get the frame + await navigateToLandingPage(page); + const frame = await ibFrame(page); + + await test.step('Select RHEL 9 and go to optional steps in Wizard', async () => { + await frame.getByRole('button', { name: 'Create image blueprint' }).click(); + await frame.getByTestId('release_select').click(); + await frame + .getByRole('option', { + name: 'Red Hat Enterprise Linux (RHEL) 9 Full support ends: May 2027 | Maintenance', + }) + .click(); + await frame.getByRole('checkbox', { name: 'Virtualization' }).click(); + await frame.getByRole('button', { name: 'Next' }).click(); + await registerLater(frame); + }); + + await test.step('Select only OpenSCAP, and check if dependencies are preselected', async () => { + await frame.getByRole('button', { name: 'Compliance' }).click(); + await frame.getByRole('textbox', { name: 'Type to filter' }).fill('cis'); + await frame + .getByRole('option', { + name: 'CIS Red Hat Enterprise Linux 9 Benchmark for Level 1 - Server This profile', + }) + .click(); + await frame + .getByRole('button', { name: 'File system configuration' }) + .click(); + await expect( + frame + .getByRole('row', { + name: 'Draggable row draggable button /tmp xfs 1 GiB', + }) + .getByRole('button') + .nth(3) + ).toBeVisible(); + await frame.getByRole('button', { name: 'Additional packages' }).click(); + await frame.getByRole('button', { name: 'Selected (9)' }).click(); + await expect(frame.getByRole('gridcell', { name: 'aide' })).toBeVisible(); + await expect(frame.getByRole('gridcell', { name: 'chrony' })).toBeVisible(); + await expect(frame.getByRole('gridcell', { name: 'cronie' })).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'firewalld' }) + ).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'libpwquality' }) + ).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'libselinux' }) + ).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'nftables' }) + ).toBeVisible(); + await expect(frame.getByRole('gridcell', { name: 'sudo' })).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'systemd-journal-remote' }) + ).toBeVisible(); + await frame.getByRole('button', { name: 'Systemd services' }).click(); + await expect( + frame.getByText('Required by OpenSCAPcrondfirewalldsystemd-journald') + ).toBeVisible(); + await frame.getByPlaceholder('Add masked service').fill('nftables'); + await frame.getByPlaceholder('Add masked service').press('Enter'); + await expect( + frame.getByText('Masked service already exists') + ).toBeVisible(); + await expect(frame.getByText('Required by OpenSCAPcupsnfs-')).toBeVisible(); + await expect(frame.getByText('nfs-server')).toBeVisible(); + await expect(frame.getByText('rpcbind')).toBeVisible(); + await expect(frame.getByText('avahi-daemon')).toBeVisible(); + await expect(frame.getByText('autofs')).toBeVisible(); + await expect(frame.getByText('bluetooth')).toBeVisible(); + await expect(frame.getByText('nftables')).toBeVisible(); + await frame.getByRole('button', { name: 'Review and finish' }).click(); + }); + + await test.step('Fill the BP details', async () => { + await fillInDetails(frame, blueprintName); + }); + + await test.step('Create BP', async () => { + await createBlueprint(frame, blueprintName); + }); + + await test.step('Edit BP', async () => { + await frame.getByRole('button', { name: 'Edit blueprint' }).click(); + await frame.getByRole('button', { name: 'Compliance' }).click(); + await expect(frame.getByText('Level 1 - Server')).toBeVisible(); + await frame.getByRole('textbox', { name: 'Type to filter' }).fill('cis'); + await frame + .getByRole('option', { + name: 'CIS Red Hat Enterprise Linux 9 Benchmark for Level 2 - Server This profile', + }) + .click(); + + await frame.getByRole('button', { name: 'Kernel' }).click(); + + await expect( + frame.getByText('Required by OpenSCAPaudit_backlog_limit=8192audit=') + ).toBeVisible(); + await frame.getByRole('button', { name: 'Additional packages' }).click(); + await frame.getByRole('button', { name: 'Selected (11)' }).click(); + await expect(frame.getByRole('gridcell', { name: 'aide' })).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'audit-libs' }) + ).toBeVisible(); + await expect(frame.getByRole('gridcell', { name: 'chrony' })).toBeVisible(); + await expect(frame.getByRole('gridcell', { name: 'cronie' })).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'firewalld' }) + ).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'libpwquality' }) + ).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'libselinux' }) + ).toBeVisible(); + await expect( + frame.getByRole('gridcell', { name: 'nftables' }) + ).toBeVisible(); + await expect(frame.getByRole('gridcell', { name: 'sudo' })).toBeVisible(); + await frame.getByRole('button', { name: 'Systemd services' }).click(); + await expect( + frame.getByText( + 'Required by OpenSCAPauditdcrondfirewalldsystemd-journald' + ) + ).toBeVisible(); + await frame.getByPlaceholder('Add masked service').fill('nftables'); + await frame.getByPlaceholder('Add masked service').press('Enter'); + await expect( + frame.getByText('Masked service already exists') + ).toBeVisible(); + await expect(frame.getByText('Required by OpenSCAPcupsnfs-')).toBeVisible(); + await expect(frame.getByText('nfs-server')).toBeVisible(); + await expect(frame.getByText('rpcbind')).toBeVisible(); + await expect(frame.getByText('avahi-daemon')).toBeVisible(); + await expect(frame.getByText('autofs')).toBeVisible(); + await expect(frame.getByText('bluetooth')).toBeVisible(); + await expect(frame.getByText('nftables')).toBeVisible(); + await frame.getByRole('button', { name: 'Review and finish' }).click(); + await frame + .getByRole('button', { name: 'Save changes to blueprint' }) + .click(); + }); + + // This is for hosted service only as these features are not available in cockpit plugin + await test.step('Export BP', async () => { + await exportBlueprint(page, blueprintName); + }); + + await test.step('Import BP', async () => { + await importBlueprint(page, blueprintName); + }); + + await test.step('Review imported BP', async () => { + await fillInImageOutputGuest(page); + await page.getByRole('button', { name: 'Compliance' }).click(); + + await expect(frame.getByText('Level 2 - Server')).toBeVisible(); + + await page.getByRole('button', { name: 'Cancel' }).click(); + }); +}); From 8d656b766c6fb915abafa1796f5de2d080f79f73 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 30 Jul 2025 04:36:05 +0000 Subject: [PATCH 041/123] build(deps-dev): bump @testing-library/dom from 10.4.0 to 10.4.1 Bumps [@testing-library/dom](https://github.com/testing-library/dom-testing-library) from 10.4.0 to 10.4.1. - [Release notes](https://github.com/testing-library/dom-testing-library/releases) - [Changelog](https://github.com/testing-library/dom-testing-library/blob/main/CHANGELOG.md) - [Commits](https://github.com/testing-library/dom-testing-library/compare/v10.4.0...v10.4.1) --- updated-dependencies: - dependency-name: "@testing-library/dom" dependency-version: 10.4.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++++----- package.json | 2 +- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/package-lock.json b/package-lock.json index 228859e7..b0c0b10f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -44,7 +44,7 @@ "@redhat-cloud-services/frontend-components-config": "6.3.8", "@redhat-cloud-services/tsc-transform-imports": "1.0.25", "@rtk-query/codegen-openapi": "2.0.0", - "@testing-library/dom": "10.4.0", + "@testing-library/dom": "10.4.1", "@testing-library/jest-dom": "6.6.3", "@testing-library/react": "16.3.0", "@testing-library/user-event": "14.6.1", @@ -5185,7 +5185,9 @@ } }, "node_modules/@testing-library/dom": { - "version": "10.4.0", + "version": "10.4.1", + "resolved": "https://registry.npmjs.org/@testing-library/dom/-/dom-10.4.1.tgz", + "integrity": "sha512-o4PXJQidqJl82ckFaXUeoAW+XysPLauYI43Abki5hABd853iMhitooc6znOnczgbTYmEP6U6/y1ZyKAIsvMKGg==", "dev": true, "license": "MIT", "dependencies": { @@ -5193,9 +5195,9 @@ "@babel/runtime": "^7.12.5", "@types/aria-query": "^5.0.1", "aria-query": "5.3.0", - "chalk": "^4.1.0", "dom-accessibility-api": "^0.5.9", "lz-string": "^1.5.0", + "picocolors": "1.1.1", "pretty-format": "^27.0.2" }, "engines": { @@ -23123,16 +23125,18 @@ } }, "@testing-library/dom": { - "version": "10.4.0", + "version": "10.4.1", + "resolved": "https://registry.npmjs.org/@testing-library/dom/-/dom-10.4.1.tgz", + "integrity": "sha512-o4PXJQidqJl82ckFaXUeoAW+XysPLauYI43Abki5hABd853iMhitooc6znOnczgbTYmEP6U6/y1ZyKAIsvMKGg==", "dev": true, "requires": { "@babel/code-frame": "^7.10.4", "@babel/runtime": "^7.12.5", "@types/aria-query": "^5.0.1", "aria-query": "5.3.0", - "chalk": "^4.1.0", "dom-accessibility-api": "^0.5.9", "lz-string": "^1.5.0", + "picocolors": "1.1.1", "pretty-format": "^27.0.2" } }, diff --git a/package.json b/package.json index 312425d5..9c48d87b 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "@redhat-cloud-services/frontend-components-config": "6.3.8", "@redhat-cloud-services/tsc-transform-imports": "1.0.25", "@rtk-query/codegen-openapi": "2.0.0", - "@testing-library/dom": "10.4.0", + "@testing-library/dom": "10.4.1", "@testing-library/jest-dom": "6.6.3", "@testing-library/react": "16.3.0", "@testing-library/user-event": "14.6.1", From 98b890206be526689fc7e2a386cc8a3da4bd2ecc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 30 Jul 2025 04:36:43 +0000 Subject: [PATCH 042/123] build(deps): bump @redhat-cloud-services/frontend-components-utilities Bumps [@redhat-cloud-services/frontend-components-utilities](https://github.com/RedHatInsights/frontend-components) from 6.1.0 to 6.1.1. - [Release notes](https://github.com/RedHatInsights/frontend-components/releases) - [Changelog](https://github.com/RedHatInsights/frontend-components/blob/master/CHANGELOG.md) - [Commits](https://github.com/RedHatInsights/frontend-components/compare/@redhat-cloud-services/frontend-components-utilities-6.1.0...@redhat-cloud-services/frontend-components-utilities-6.1.1) --- updated-dependencies: - dependency-name: "@redhat-cloud-services/frontend-components-utilities" dependency-version: 6.1.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index b0c0b10f..caaf968a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16,7 +16,7 @@ "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", "@redhat-cloud-services/frontend-components-notifications": "6.1.1", - "@redhat-cloud-services/frontend-components-utilities": "6.1.0", + "@redhat-cloud-services/frontend-components-utilities": "6.1.1", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", "@sentry/webpack-plugin": "4.0.1", @@ -4182,9 +4182,9 @@ } }, "node_modules/@redhat-cloud-services/frontend-components-utilities": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-utilities/-/frontend-components-utilities-6.1.0.tgz", - "integrity": "sha512-84+ulQLAkztXox1FcujEr2ktxcyryS1vhkvFqZgWK1/i0TK+AnBPH5G53NPjoDLPNHEEu2lYm4K/d+AC1+y+DA==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-utilities/-/frontend-components-utilities-6.1.1.tgz", + "integrity": "sha512-ETaL9dUOyxrqjJx+QcxI5pBmDOShC6voJINlU4afhelJBfam01oMQxQYB1aPFKs2JmBDbYgT2fgT/6s/1FJS0Q==", "license": "Apache-2.0", "dependencies": { "@redhat-cloud-services/rbac-client": "^1.0.111 || 2.x", @@ -22552,9 +22552,9 @@ } }, "@redhat-cloud-services/frontend-components-utilities": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-utilities/-/frontend-components-utilities-6.1.0.tgz", - "integrity": "sha512-84+ulQLAkztXox1FcujEr2ktxcyryS1vhkvFqZgWK1/i0TK+AnBPH5G53NPjoDLPNHEEu2lYm4K/d+AC1+y+DA==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-utilities/-/frontend-components-utilities-6.1.1.tgz", + "integrity": "sha512-ETaL9dUOyxrqjJx+QcxI5pBmDOShC6voJINlU4afhelJBfam01oMQxQYB1aPFKs2JmBDbYgT2fgT/6s/1FJS0Q==", "requires": { "@redhat-cloud-services/rbac-client": "^1.0.111 || 2.x", "@redhat-cloud-services/types": "^2.0.0", diff --git a/package.json b/package.json index 9c48d87b..3bc57265 100644 --- a/package.json +++ b/package.json @@ -14,7 +14,7 @@ "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", "@redhat-cloud-services/frontend-components-notifications": "6.1.1", - "@redhat-cloud-services/frontend-components-utilities": "6.1.0", + "@redhat-cloud-services/frontend-components-utilities": "6.1.1", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", "@sentry/webpack-plugin": "4.0.1", From 8cf161d4e52b13f9bd20a0f969e95fcb0b72408c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 30 Jul 2025 06:46:20 +0000 Subject: [PATCH 043/123] build(deps-dev): bump @testing-library/jest-dom from 6.6.3 to 6.6.4 Bumps [@testing-library/jest-dom](https://github.com/testing-library/jest-dom) from 6.6.3 to 6.6.4. - [Release notes](https://github.com/testing-library/jest-dom/releases) - [Changelog](https://github.com/testing-library/jest-dom/blob/main/CHANGELOG.md) - [Commits](https://github.com/testing-library/jest-dom/compare/v6.6.3...v6.6.4) --- updated-dependencies: - dependency-name: "@testing-library/jest-dom" dependency-version: 6.6.4 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 34 +++++++++------------------------- package.json | 2 +- 2 files changed, 10 insertions(+), 26 deletions(-) diff --git a/package-lock.json b/package-lock.json index caaf968a..1cf8ef01 100644 --- a/package-lock.json +++ b/package-lock.json @@ -45,7 +45,7 @@ "@redhat-cloud-services/tsc-transform-imports": "1.0.25", "@rtk-query/codegen-openapi": "2.0.0", "@testing-library/dom": "10.4.1", - "@testing-library/jest-dom": "6.6.3", + "@testing-library/jest-dom": "6.6.4", "@testing-library/react": "16.3.0", "@testing-library/user-event": "14.6.1", "@types/node": "24.1.0", @@ -5205,16 +5205,18 @@ } }, "node_modules/@testing-library/jest-dom": { - "version": "6.6.3", + "version": "6.6.4", + "resolved": "https://registry.npmjs.org/@testing-library/jest-dom/-/jest-dom-6.6.4.tgz", + "integrity": "sha512-xDXgLjVunjHqczScfkCJ9iyjdNOVHvvCdqHSSxwM9L0l/wHkTRum67SDc020uAlCoqktJplgO2AAQeLP1wgqDQ==", "dev": true, "license": "MIT", "dependencies": { "@adobe/css-tools": "^4.4.0", "aria-query": "^5.0.0", - "chalk": "^3.0.0", "css.escape": "^1.5.1", "dom-accessibility-api": "^0.6.3", "lodash": "^4.17.21", + "picocolors": "^1.1.1", "redent": "^3.0.0" }, "engines": { @@ -5223,18 +5225,6 @@ "yarn": ">=1" } }, - "node_modules/@testing-library/jest-dom/node_modules/chalk": { - "version": "3.0.0", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@testing-library/jest-dom/node_modules/dom-accessibility-api": { "version": "0.6.3", "dev": true, @@ -23141,26 +23131,20 @@ } }, "@testing-library/jest-dom": { - "version": "6.6.3", + "version": "6.6.4", + "resolved": "https://registry.npmjs.org/@testing-library/jest-dom/-/jest-dom-6.6.4.tgz", + "integrity": "sha512-xDXgLjVunjHqczScfkCJ9iyjdNOVHvvCdqHSSxwM9L0l/wHkTRum67SDc020uAlCoqktJplgO2AAQeLP1wgqDQ==", "dev": true, "requires": { "@adobe/css-tools": "^4.4.0", "aria-query": "^5.0.0", - "chalk": "^3.0.0", "css.escape": "^1.5.1", "dom-accessibility-api": "^0.6.3", "lodash": "^4.17.21", + "picocolors": "^1.1.1", "redent": "^3.0.0" }, "dependencies": { - "chalk": { - "version": "3.0.0", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, "dom-accessibility-api": { "version": "0.6.3", "dev": true diff --git a/package.json b/package.json index 3bc57265..f6a638d6 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,7 @@ "@redhat-cloud-services/tsc-transform-imports": "1.0.25", "@rtk-query/codegen-openapi": "2.0.0", "@testing-library/dom": "10.4.1", - "@testing-library/jest-dom": "6.6.3", + "@testing-library/jest-dom": "6.6.4", "@testing-library/react": "16.3.0", "@testing-library/user-event": "14.6.1", "@types/node": "24.1.0", From d5321bb078466aa95b4f53cd3b2e2d559f0f52ea Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Wed, 30 Jul 2025 08:51:10 +0200 Subject: [PATCH 044/123] Wizard: Remove alert from OpenSCAP step Information about required packages, services and kernel arguments is back on the step. Meaning we can remove the alert as per UX recommendation. --- .../CreateImageWizard/steps/Oscap/Oscap.tsx | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/src/Components/CreateImageWizard/steps/Oscap/Oscap.tsx b/src/Components/CreateImageWizard/steps/Oscap/Oscap.tsx index 35ab3be1..910bd596 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/Oscap.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/Oscap.tsx @@ -42,18 +42,6 @@ const Oscap = ({ majorVersion }: OscapPropTypes) => { )} {complianceType === 'openscap' ? <ProfileSelector /> : <PolicySelector />} {oscapProfile && <OscapProfileInformation />} - {oscapProfile && ( - <Alert - variant="info" - isInline - isPlain - title="Additional customizations" - > - Selecting an OpenSCAP profile will cause the appropriate packages, - file system configuration, kernel arguments, and services to be added - to your image. - </Alert> - )} </> ); }; From 1096c6d4fbbbc430ed9948de8acb2270815e7135 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Thu, 31 Jul 2025 10:58:05 +0200 Subject: [PATCH 045/123] playwright: Add duration to test account creation request There were some changes in Ethel recently, duration currently seems to be a required field. Ethel team works on a fix. Default value for duration is 1 year so I've set it to that. --- .github/workflows/playwright.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml index 5e6ee70e..d0a3ef0a 100644 --- a/.github/workflows/playwright.yml +++ b/.github/workflows/playwright.yml @@ -68,7 +68,7 @@ jobs: export PLAYWRIGHT_USER=image-builder-playwright-$RANDOM export PLAYWRIGHT_PASSWORD=image-builder-playwright-$(uuidgen) # Step 1: Create a new empty account - curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/new -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\"}" + curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/new -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\", \"duration\":\"1 year\"}" # Step 2: Attach subscriptions to the new account curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/attach \ -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\", \"sku\":[\"RH00003\"],\"quantity\": 1}" From 9efdd827717ffcc32a3066bc2ae0bb9870836af9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Jul 2025 10:00:45 +0000 Subject: [PATCH 046/123] build(deps): bump @sentry/webpack-plugin from 4.0.1 to 4.0.2 Bumps [@sentry/webpack-plugin](https://github.com/getsentry/sentry-javascript-bundler-plugins) from 4.0.1 to 4.0.2. - [Release notes](https://github.com/getsentry/sentry-javascript-bundler-plugins/releases) - [Changelog](https://github.com/getsentry/sentry-javascript-bundler-plugins/blob/main/CHANGELOG.md) - [Commits](https://github.com/getsentry/sentry-javascript-bundler-plugins/compare/4.0.1...4.0.2) --- updated-dependencies: - dependency-name: "@sentry/webpack-plugin" dependency-version: 4.0.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 46 +++++++++++++++++++++++----------------------- package.json | 2 +- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1cf8ef01..e6b8ccf4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,7 +19,7 @@ "@redhat-cloud-services/frontend-components-utilities": "6.1.1", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", - "@sentry/webpack-plugin": "4.0.1", + "@sentry/webpack-plugin": "4.0.2", "@unleash/proxy-client-react": "5.0.1", "classnames": "2.5.1", "jwt-decode": "4.0.0", @@ -4716,9 +4716,9 @@ } }, "node_modules/@sentry/babel-plugin-component-annotate": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.1.tgz", - "integrity": "sha512-wjxM5Gqms71tfPntejHix3sUJBFW/v04P0iPUDyvi30slbSlNnyOajwBPNDv+VE5Y6OANV8UV1IOksMaGW1n4Q==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.2.tgz", + "integrity": "sha512-Nr/VamvpQs6w642EI5t+qaCUGnVEro0qqk+S8XO1gc8qSdpc8kkZJFnUk7ozAr+ljYWGfVgWXrxI9lLiriLsRA==", "license": "MIT", "engines": { "node": ">= 14" @@ -4744,13 +4744,13 @@ } }, "node_modules/@sentry/bundler-plugin-core": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.1.tgz", - "integrity": "sha512-V3k9nkh1eHHPw5wNnwCAYlR1yEMNaM1XkPtHj43vIWdy9cqqCGeRnGC8h+m4q61JdzGwZDufOhzs095Ib6TukA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.2.tgz", + "integrity": "sha512-LeARs8qHhEw19tk+KZd9DDV+Rh/UeapIH0+C09fTmff9p8Y82Cj89pEQ2a1rdUiF/oYIjQX45vnZscB7ra42yw==", "license": "MIT", "dependencies": { "@babel/core": "^7.18.5", - "@sentry/babel-plugin-component-annotate": "4.0.1", + "@sentry/babel-plugin-component-annotate": "4.0.2", "@sentry/cli": "^2.49.0", "dotenv": "^16.3.1", "find-up": "^5.0.0", @@ -5034,12 +5034,12 @@ } }, "node_modules/@sentry/webpack-plugin": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.1.tgz", - "integrity": "sha512-LQkg6bEuneFNFtsXFViPujzEs/2SKqdIxYlEVr7cmPx0OhupViiA3TU+8UlgP4piqZWKDdMrlKuG3oTGMzdHww==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.2.tgz", + "integrity": "sha512-UklVtG7Iiw+AvcL0PfiiyW/u3XT+joDAMDvWbx90rFhVSU10ENW5AV5y4pC41qChqEu3P1eBFdaSxg+kdLeqvw==", "license": "MIT", "dependencies": { - "@sentry/bundler-plugin-core": "4.0.1", + "@sentry/bundler-plugin-core": "4.0.2", "unplugin": "1.0.1", "uuid": "^9.0.0" }, @@ -22857,9 +22857,9 @@ } }, "@sentry/babel-plugin-component-annotate": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.1.tgz", - "integrity": "sha512-wjxM5Gqms71tfPntejHix3sUJBFW/v04P0iPUDyvi30slbSlNnyOajwBPNDv+VE5Y6OANV8UV1IOksMaGW1n4Q==" + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@sentry/babel-plugin-component-annotate/-/babel-plugin-component-annotate-4.0.2.tgz", + "integrity": "sha512-Nr/VamvpQs6w642EI5t+qaCUGnVEro0qqk+S8XO1gc8qSdpc8kkZJFnUk7ozAr+ljYWGfVgWXrxI9lLiriLsRA==" }, "@sentry/browser": { "version": "7.120.3", @@ -22877,12 +22877,12 @@ } }, "@sentry/bundler-plugin-core": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.1.tgz", - "integrity": "sha512-V3k9nkh1eHHPw5wNnwCAYlR1yEMNaM1XkPtHj43vIWdy9cqqCGeRnGC8h+m4q61JdzGwZDufOhzs095Ib6TukA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@sentry/bundler-plugin-core/-/bundler-plugin-core-4.0.2.tgz", + "integrity": "sha512-LeARs8qHhEw19tk+KZd9DDV+Rh/UeapIH0+C09fTmff9p8Y82Cj89pEQ2a1rdUiF/oYIjQX45vnZscB7ra42yw==", "requires": { "@babel/core": "^7.18.5", - "@sentry/babel-plugin-component-annotate": "4.0.1", + "@sentry/babel-plugin-component-annotate": "4.0.2", "@sentry/cli": "^2.49.0", "dotenv": "^16.3.1", "find-up": "^5.0.0", @@ -23030,11 +23030,11 @@ } }, "@sentry/webpack-plugin": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.1.tgz", - "integrity": "sha512-LQkg6bEuneFNFtsXFViPujzEs/2SKqdIxYlEVr7cmPx0OhupViiA3TU+8UlgP4piqZWKDdMrlKuG3oTGMzdHww==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-4.0.2.tgz", + "integrity": "sha512-UklVtG7Iiw+AvcL0PfiiyW/u3XT+joDAMDvWbx90rFhVSU10ENW5AV5y4pC41qChqEu3P1eBFdaSxg+kdLeqvw==", "requires": { - "@sentry/bundler-plugin-core": "4.0.1", + "@sentry/bundler-plugin-core": "4.0.2", "unplugin": "1.0.1", "uuid": "^9.0.0" }, diff --git a/package.json b/package.json index f6a638d6..0c345a9b 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,7 @@ "@redhat-cloud-services/frontend-components-utilities": "6.1.1", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", - "@sentry/webpack-plugin": "4.0.1", + "@sentry/webpack-plugin": "4.0.2", "@unleash/proxy-client-react": "5.0.1", "classnames": "2.5.1", "jwt-decode": "4.0.0", From d94834e25f840d0c48f729d25a9d7fbced70d1e6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Jul 2025 10:00:02 +0000 Subject: [PATCH 047/123] build(deps-dev): bump eslint from 9.30.1 to 9.32.0 Bumps [eslint](https://github.com/eslint/eslint) from 9.30.1 to 9.32.0. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/compare/v9.30.1...v9.32.0) --- updated-dependencies: - dependency-name: eslint dependency-version: 9.32.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 86 +++++++++++++++++------------------------------ package.json | 2 +- 2 files changed, 32 insertions(+), 56 deletions(-) diff --git a/package-lock.json b/package-lock.json index e6b8ccf4..aaaf799d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -63,7 +63,7 @@ "chartjs-plugin-annotation": "3.1.0", "copy-webpack-plugin": "13.0.0", "css-loader": "7.1.2", - "eslint": "9.30.1", + "eslint": "9.32.0", "eslint-plugin-disable-autofix": "5.0.1", "eslint-plugin-import": "2.32.0", "eslint-plugin-jest-dom": "5.5.0", @@ -3025,9 +3025,9 @@ } }, "node_modules/@eslint/core": { - "version": "0.14.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.14.0.tgz", - "integrity": "sha512-qIbV0/JZr7iSDjqAc60IqbLdsj9GDt16xQtWD+B78d/HAlvysGdZZ6rpJHGAc2T0FQx1X6thsSPdnoiGKdNtdg==", + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.15.1.tgz", + "integrity": "sha512-bkOp+iumZCCbt1K1CmWf0R9pM5yKpDv+ZXtvSyQpudrI9kuFLp+bM2WOPXImuD/ceQuaa8f5pj93Y7zyECIGNA==", "dev": true, "license": "Apache-2.0", "dependencies": { @@ -3146,9 +3146,9 @@ } }, "node_modules/@eslint/plugin-kit": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.3.3.tgz", - "integrity": "sha512-1+WqvgNMhmlAambTvT3KPtCl/Ibr68VldY2XY40SL1CE0ZXiakFR/cbTspaF5HsnpDMvcYYoJHfl4980NBjGag==", + "version": "0.3.4", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.3.4.tgz", + "integrity": "sha512-Ul5l+lHEcw3L5+k8POx6r74mxEYKG5kOb6Xpy2gCRW6zweT6TEhAf8vhxGgjhqrd/VO/Dirhsb+1hNpD1ue9hw==", "dev": true, "license": "Apache-2.0", "dependencies": { @@ -3159,19 +3159,6 @@ "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, - "node_modules/@eslint/plugin-kit/node_modules/@eslint/core": { - "version": "0.15.1", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.15.1.tgz", - "integrity": "sha512-bkOp+iumZCCbt1K1CmWf0R9pM5yKpDv+ZXtvSyQpudrI9kuFLp+bM2WOPXImuD/ceQuaa8f5pj93Y7zyECIGNA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@types/json-schema": "^7.0.15" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, "node_modules/@exodus/schemasafe": { "version": "1.3.0", "dev": true, @@ -9389,9 +9376,9 @@ } }, "node_modules/eslint": { - "version": "9.30.1", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.30.1.tgz", - "integrity": "sha512-zmxXPNMOXmwm9E0yQLi5uqXHs7uq2UIiqEKo3Gq+3fwo1XrJ+hijAZImyF7hclW3E6oHz43Yk3RP8at6OTKflQ==", + "version": "9.32.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.32.0.tgz", + "integrity": "sha512-LSehfdpgMeWcTZkWZVIJl+tkZ2nuSkyyB9C27MZqFWXuph7DvaowgcTvKqxvpLW1JZIk8PN7hFY3Rj9LQ7m7lg==", "dev": true, "license": "MIT", "dependencies": { @@ -9399,10 +9386,10 @@ "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.21.0", "@eslint/config-helpers": "^0.3.0", - "@eslint/core": "^0.14.0", + "@eslint/core": "^0.15.0", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.30.1", - "@eslint/plugin-kit": "^0.3.1", + "@eslint/js": "9.32.0", + "@eslint/plugin-kit": "^0.3.4", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", @@ -9930,9 +9917,9 @@ } }, "node_modules/eslint/node_modules/@eslint/js": { - "version": "9.30.1", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.30.1.tgz", - "integrity": "sha512-zXhuECFlyep42KZUhWjfvsmXGX39W8K8LFb8AWXM9gSV9dQB+MrJGLKvW6Zw0Ggnbpw0VHTtrhFXYe3Gym18jg==", + "version": "9.32.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.32.0.tgz", + "integrity": "sha512-BBpRFZK3eX6uMLKz8WxFOBIFFcGFJ/g8XuwjTHCqHROSIsopI+ddn/d5Cfh36+7+e5edVS8dbSHnBNhrLEX0zg==", "dev": true, "license": "MIT", "engines": { @@ -21816,9 +21803,9 @@ "dev": true }, "@eslint/core": { - "version": "0.14.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.14.0.tgz", - "integrity": "sha512-qIbV0/JZr7iSDjqAc60IqbLdsj9GDt16xQtWD+B78d/HAlvysGdZZ6rpJHGAc2T0FQx1X6thsSPdnoiGKdNtdg==", + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.15.1.tgz", + "integrity": "sha512-bkOp+iumZCCbt1K1CmWf0R9pM5yKpDv+ZXtvSyQpudrI9kuFLp+bM2WOPXImuD/ceQuaa8f5pj93Y7zyECIGNA==", "dev": true, "requires": { "@types/json-schema": "^7.0.15" @@ -21899,24 +21886,13 @@ "dev": true }, "@eslint/plugin-kit": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.3.3.tgz", - "integrity": "sha512-1+WqvgNMhmlAambTvT3KPtCl/Ibr68VldY2XY40SL1CE0ZXiakFR/cbTspaF5HsnpDMvcYYoJHfl4980NBjGag==", + "version": "0.3.4", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.3.4.tgz", + "integrity": "sha512-Ul5l+lHEcw3L5+k8POx6r74mxEYKG5kOb6Xpy2gCRW6zweT6TEhAf8vhxGgjhqrd/VO/Dirhsb+1hNpD1ue9hw==", "dev": true, "requires": { "@eslint/core": "^0.15.1", "levn": "^0.4.1" - }, - "dependencies": { - "@eslint/core": { - "version": "0.15.1", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.15.1.tgz", - "integrity": "sha512-bkOp+iumZCCbt1K1CmWf0R9pM5yKpDv+ZXtvSyQpudrI9kuFLp+bM2WOPXImuD/ceQuaa8f5pj93Y7zyECIGNA==", - "dev": true, - "requires": { - "@types/json-schema": "^7.0.15" - } - } } }, "@exodus/schemasafe": { @@ -25864,19 +25840,19 @@ } }, "eslint": { - "version": "9.30.1", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.30.1.tgz", - "integrity": "sha512-zmxXPNMOXmwm9E0yQLi5uqXHs7uq2UIiqEKo3Gq+3fwo1XrJ+hijAZImyF7hclW3E6oHz43Yk3RP8at6OTKflQ==", + "version": "9.32.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.32.0.tgz", + "integrity": "sha512-LSehfdpgMeWcTZkWZVIJl+tkZ2nuSkyyB9C27MZqFWXuph7DvaowgcTvKqxvpLW1JZIk8PN7hFY3Rj9LQ7m7lg==", "dev": true, "requires": { "@eslint-community/eslint-utils": "^4.2.0", "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.21.0", "@eslint/config-helpers": "^0.3.0", - "@eslint/core": "^0.14.0", + "@eslint/core": "^0.15.0", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.30.1", - "@eslint/plugin-kit": "^0.3.1", + "@eslint/js": "9.32.0", + "@eslint/plugin-kit": "^0.3.4", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", @@ -25907,9 +25883,9 @@ }, "dependencies": { "@eslint/js": { - "version": "9.30.1", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.30.1.tgz", - "integrity": "sha512-zXhuECFlyep42KZUhWjfvsmXGX39W8K8LFb8AWXM9gSV9dQB+MrJGLKvW6Zw0Ggnbpw0VHTtrhFXYe3Gym18jg==", + "version": "9.32.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.32.0.tgz", + "integrity": "sha512-BBpRFZK3eX6uMLKz8WxFOBIFFcGFJ/g8XuwjTHCqHROSIsopI+ddn/d5Cfh36+7+e5edVS8dbSHnBNhrLEX0zg==", "dev": true }, "ajv": { diff --git a/package.json b/package.json index 0c345a9b..2de71e96 100644 --- a/package.json +++ b/package.json @@ -61,7 +61,7 @@ "chartjs-plugin-annotation": "3.1.0", "copy-webpack-plugin": "13.0.0", "css-loader": "7.1.2", - "eslint": "9.30.1", + "eslint": "9.32.0", "eslint-plugin-disable-autofix": "5.0.1", "eslint-plugin-import": "2.32.0", "eslint-plugin-jest-dom": "5.5.0", From 9943f54cd99f687dcfb048c4070a9c1783ff67ab Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Jul 2025 10:00:39 +0000 Subject: [PATCH 048/123] build(deps-dev): bump eslint-plugin-testing-library from 7.6.0 to 7.6.3 Bumps [eslint-plugin-testing-library](https://github.com/testing-library/eslint-plugin-testing-library) from 7.6.0 to 7.6.3. - [Release notes](https://github.com/testing-library/eslint-plugin-testing-library/releases) - [Changelog](https://github.com/testing-library/eslint-plugin-testing-library/blob/main/.releaserc.json) - [Commits](https://github.com/testing-library/eslint-plugin-testing-library/compare/v7.6.0...v7.6.3) --- updated-dependencies: - dependency-name: eslint-plugin-testing-library dependency-version: 7.6.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index aaaf799d..5809861f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -72,7 +72,7 @@ "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", - "eslint-plugin-testing-library": "7.6.0", + "eslint-plugin-testing-library": "7.6.3", "git-revision-webpack-plugin": "5.0.0", "globals": "16.3.0", "history": "5.3.0", @@ -9863,9 +9863,9 @@ } }, "node_modules/eslint-plugin-testing-library": { - "version": "7.6.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-7.6.0.tgz", - "integrity": "sha512-rxCz4VQFb45kDeFLnQcjGpeb72r4HmCh6v49d+DhrD2HVpnJuwK/GOnPjezWS7CytkNjQjpXcPopxLN++FlXxw==", + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-7.6.3.tgz", + "integrity": "sha512-tI/epV/DD4+nJ51VGg7MWfqajMAW0+U+9dTLFrnqrJHoPO2TyGRU8ASrPNFPe2zzDT1qwznkCeeqMzViALgiig==", "dev": true, "license": "MIT", "dependencies": { @@ -26220,9 +26220,9 @@ "dev": true }, "eslint-plugin-testing-library": { - "version": "7.6.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-7.6.0.tgz", - "integrity": "sha512-rxCz4VQFb45kDeFLnQcjGpeb72r4HmCh6v49d+DhrD2HVpnJuwK/GOnPjezWS7CytkNjQjpXcPopxLN++FlXxw==", + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-7.6.3.tgz", + "integrity": "sha512-tI/epV/DD4+nJ51VGg7MWfqajMAW0+U+9dTLFrnqrJHoPO2TyGRU8ASrPNFPe2zzDT1qwznkCeeqMzViALgiig==", "dev": true, "requires": { "@typescript-eslint/scope-manager": "^8.15.0", diff --git a/package.json b/package.json index 2de71e96..d1badd65 100644 --- a/package.json +++ b/package.json @@ -70,7 +70,7 @@ "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", - "eslint-plugin-testing-library": "7.6.0", + "eslint-plugin-testing-library": "7.6.3", "git-revision-webpack-plugin": "5.0.0", "globals": "16.3.0", "history": "5.3.0", From 90c2c65ebe32e46792325c4d8e905e5298dfbd74 Mon Sep 17 00:00:00 2001 From: Katarina Sieklova <ksieklov@redhat.com> Date: Fri, 6 Jun 2025 13:09:02 +0200 Subject: [PATCH 049/123] Wizard: disable adding empty user tabs When creating an empty user, the "+" sign gets hidden, and only pops back up if at least user name, psswd, or ssh key is filed out. Fixes #3114 --- .../CreateImageWizard/steps/Users/components/UserInfo.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx b/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx index e18bb78d..eb20a91a 100644 --- a/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx +++ b/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx @@ -149,6 +149,7 @@ const UserInfo = () => { activeKey={activeTabKey} onSelect={onSelect} onAdd={onAdd} + isAddButtonDisabled={stepValidation.disabledNext} onClose={onClose} ref={tabComponentRef} > From 64e5744d8ca7d813cf81a03a441de1aa7458605f Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Wed, 30 Jul 2025 13:19:17 +0200 Subject: [PATCH 050/123] Wizard: Remove RHEL betas from release options This removes RHEL betas from release menu and cleans up the code in several places. --- .../CreateImageWizard/CreateImageWizard.tsx | 13 ++---------- .../ImageOutput/components/ReleaseSelect.tsx | 18 ----------------- .../steps/Oscap/removeBetaFromRelease.ts | 2 +- .../Registration/components/Registration.tsx | 20 +++---------------- .../utilities/requestMapper.ts | 10 ++-------- src/constants.ts | 3 --- .../steps/ImageOutput/ImageOutput.test.tsx | 5 ----- 7 files changed, 8 insertions(+), 63 deletions(-) diff --git a/src/Components/CreateImageWizard/CreateImageWizard.tsx b/src/Components/CreateImageWizard/CreateImageWizard.tsx index 2999d1a5..3507693e 100644 --- a/src/Components/CreateImageWizard/CreateImageWizard.tsx +++ b/src/Components/CreateImageWizard/CreateImageWizard.tsx @@ -65,7 +65,6 @@ import { AARCH64, AMPLITUDE_MODULE_NAME, RHEL_10, - RHEL_10_BETA, RHEL_8, RHEL_9, } from '../../constants'; @@ -210,9 +209,6 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { if (searchParams.get('release') === 'rhel9') { dispatch(changeDistribution(RHEL_9)); } - if (searchParams.get('release') === 'rhel10beta') { - dispatch(changeDistribution(RHEL_10_BETA)); - } if (searchParams.get('release') === 'rhel10') { dispatch(changeDistribution(RHEL_10)); } @@ -489,7 +485,6 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { name={complianceEnabled ? 'Compliance' : 'OpenSCAP'} id="step-oscap" key="step-oscap" - isHidden={distribution === RHEL_10_BETA} navItem={CustomStatusNavItem} footer={ <CustomWizardFooter disableNext={false} optional={true} /> @@ -529,9 +524,7 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { key="wizard-repository-snapshot" navItem={CustomStatusNavItem} status={snapshotValidation.disabledNext ? 'error' : 'default'} - isHidden={ - distribution === RHEL_10_BETA || !!process.env.IS_ON_PREMISE - } + isHidden={!!process.env.IS_ON_PREMISE} footer={ <CustomWizardFooter disableNext={snapshotValidation.disabledNext} @@ -546,9 +539,7 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { id="wizard-custom-repositories" key="wizard-custom-repositories" navItem={CustomStatusNavItem} - isHidden={ - distribution === RHEL_10_BETA || !!process.env.IS_ON_PREMISE - } + isHidden={!!process.env.IS_ON_PREMISE} isDisabled={snapshotValidation.disabledNext} footer={ <CustomWizardFooter disableNext={false} optional={true} /> diff --git a/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx b/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx index 620e067b..fc0e3164 100644 --- a/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx +++ b/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx @@ -13,14 +13,12 @@ import { ON_PREM_RELEASES, RELEASES, RHEL_10, - RHEL_10_BETA, RHEL_10_FULL_SUPPORT, RHEL_10_MAINTENANCE_SUPPORT, RHEL_8, RHEL_8_FULL_SUPPORT, RHEL_8_MAINTENANCE_SUPPORT, RHEL_9, - RHEL_9_BETA, RHEL_9_FULL_SUPPORT, RHEL_9_MAINTENANCE_SUPPORT, } from '../../../../../constants'; @@ -33,7 +31,6 @@ import { } from '../../../../../store/wizardSlice'; import isRhel from '../../../../../Utilities/isRhel'; import { toMonthAndYear } from '../../../../../Utilities/time'; -import { useFlag } from '../../../../../Utilities/useGetEnvironment'; const ReleaseSelect = () => { // What the UI refers to as the "release" is referred to as the "distribution" in the API. @@ -44,9 +41,6 @@ const ReleaseSelect = () => { const [isOpen, setIsOpen] = useState(false); const [showDevelopmentOptions, setShowDevelopmentOptions] = useState(false); - const isRHEL9BetaEnabled = useFlag('image-builder.rhel9.beta.enabled'); - const isRHEL10BetaEnabled = useFlag('image-builder.rhel10.beta.enabled'); - const releases = process.env.IS_ON_PREMISE ? ON_PREM_RELEASES : RELEASES; const handleSelect = (_event: React.MouseEvent, selection: Distributions) => { @@ -70,10 +64,6 @@ const ReleaseSelect = () => { return ''; } - if (key === RHEL_9_BETA || key === RHEL_10_BETA) { - return ''; - } - let fullSupportEnd = ''; let maintenanceSupportEnd = ''; @@ -105,14 +95,6 @@ const ReleaseSelect = () => { return key === distribution; } - if (key === RHEL_9_BETA) { - return isRHEL9BetaEnabled; - } - - if (key === RHEL_10_BETA) { - return isRHEL10BetaEnabled; - } - // Only show non-RHEL distros if expanded if (showDevelopmentOptions) { return true; diff --git a/src/Components/CreateImageWizard/steps/Oscap/removeBetaFromRelease.ts b/src/Components/CreateImageWizard/steps/Oscap/removeBetaFromRelease.ts index de8155c5..e628d155 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/removeBetaFromRelease.ts +++ b/src/Components/CreateImageWizard/steps/Oscap/removeBetaFromRelease.ts @@ -11,7 +11,7 @@ import { Distributions } from '../../../../store/imageBuilderApi'; export const removeBetaFromRelease = (dist: Distributions): Distributions => { switch (dist) { case RHEL_10_BETA: - return RHEL_10 as Distributions; + return RHEL_10; case RHEL_9_BETA: return RHEL_9; default: diff --git a/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx b/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx index e19a2030..3d8acf53 100644 --- a/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx @@ -1,4 +1,4 @@ -import React, { useEffect, useState } from 'react'; +import React, { useState } from 'react'; import { Button, @@ -11,11 +11,10 @@ import { import { ExternalLinkAltIcon, HelpIcon } from '@patternfly/react-icons'; import { useFlag } from '@unleash/proxy-client-react'; -import { INSIGHTS_URL, RHC_URL, RHEL_10_BETA } from '../../../../../constants'; +import { INSIGHTS_URL, RHC_URL } from '../../../../../constants'; import { useAppDispatch, useAppSelector } from '../../../../../store/hooks'; import { changeRegistrationType, - selectDistribution, selectRegistrationType, } from '../../../../../store/wizardSlice'; @@ -98,7 +97,6 @@ const RhcPopover = () => { const Registration = () => { const dispatch = useAppDispatch(); - const distribution = useAppSelector(selectDistribution); const registrationType = useAppSelector(selectRegistrationType); const [showOptions, setShowOptions] = useState( @@ -109,13 +107,6 @@ const Registration = () => { 'image-builder.satellite.enabled' ); - // TO DO: Remove when rhc starts working for RHEL 10 Beta - useEffect(() => { - if (distribution === RHEL_10_BETA) { - dispatch(changeRegistrationType('register-now-insights')); - } - }, []); - return ( <FormGroup label="Registration method"> <Radio @@ -126,11 +117,8 @@ const Registration = () => { registrationType === 'register-now-rhc' } onChange={(_event, checked) => { - // TO DO: Update when rhc starts working for RHEL 10 Beta - if (checked && distribution !== RHEL_10_BETA) { + if (checked) { dispatch(changeRegistrationType('register-now-rhc')); - } else if (checked && distribution === RHEL_10_BETA) { - dispatch(changeRegistrationType('register-now-insights')); } }} id="register-system-now" @@ -187,8 +175,6 @@ const Registration = () => { dispatch(changeRegistrationType('register-now-insights')); } }} - // TO DO: Remove when rhc starts working for RHEL 10 Beta - isDisabled={distribution === RHEL_10_BETA} id="register-system-now-rhc" name="register-system-rhc" /> diff --git a/src/Components/CreateImageWizard/utilities/requestMapper.ts b/src/Components/CreateImageWizard/utilities/requestMapper.ts index fc9756e1..b0a7b3a7 100644 --- a/src/Components/CreateImageWizard/utilities/requestMapper.ts +++ b/src/Components/CreateImageWizard/utilities/requestMapper.ts @@ -9,10 +9,8 @@ import { FIRSTBOOT_PATH, FIRSTBOOT_SERVICE_PATH, RHEL_10, - RHEL_10_BETA, RHEL_8, RHEL_9, - RHEL_9_BETA, SATELLITE_PATH, SATELLITE_SERVICE_DATA, SATELLITE_SERVICE_PATH, @@ -163,12 +161,8 @@ const convertFilesystemToPartition = (filesystem: Filesystem): Partition => { * @param distribution blueprint distribution */ const getLatestRelease = (distribution: Distributions) => { - return distribution === RHEL_10_BETA - ? (RHEL_10_BETA as Distributions) - : distribution.startsWith('rhel-10') - ? (RHEL_10 as Distributions) - : distribution === RHEL_9_BETA - ? (RHEL_9_BETA as Distributions) + return distribution.startsWith('rhel-10') + ? RHEL_10 : distribution.startsWith('rhel-9') ? RHEL_9 : distribution.startsWith('rhel-8') diff --git a/src/constants.ts b/src/constants.ts index 792946a4..f278414c 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -88,8 +88,6 @@ export const RELEASES = new Map([ [RHEL_10, 'Red Hat Enterprise Linux (RHEL) 10'], [RHEL_9, 'Red Hat Enterprise Linux (RHEL) 9'], [RHEL_8, 'Red Hat Enterprise Linux (RHEL) 8'], - [RHEL_9_BETA, 'Red Hat Enterprise Linux (RHEL) 9 Beta'], - [RHEL_10_BETA, 'Red Hat Enterprise Linux (RHEL) 10 Beta'], [CENTOS_9, 'CentOS Stream 9'], [CENTOS_10, 'CentOS Stream 10'], ]); @@ -98,7 +96,6 @@ export const ON_PREM_RELEASES = new Map([ [CENTOS_10, 'CentOS Stream 10'], [FEDORA_41, 'Fedora Linux 41'], [FEDORA_42, 'Fedora Linux 42'], - [RHEL_10_BETA, 'Red Hat Enterprise Linux (RHEL) 10 Beta'], [RHEL_10, 'Red Hat Enterprise Linux (RHEL) 10'], ]); diff --git a/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx b/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx index ab295707..ee026638 100644 --- a/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx @@ -682,11 +682,6 @@ describe('Set release using query parameter', () => { await renderCreateMode({ release: 'rhel9' }); await screen.findByText('Red Hat Enterprise Linux (RHEL) 9'); }); - - test('rhel 10 beta (query parameter provided)', async () => { - await renderCreateMode({ release: 'rhel10beta' }); - await screen.findByText('Red Hat Enterprise Linux (RHEL) 10 Beta'); - }); }); describe('Set architecture using query parameter', () => { From fdaf5129c8bca73118a96e9ea4769b044799bb46 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Fri, 1 Aug 2025 10:03:44 +0200 Subject: [PATCH 051/123] playwright: Update required Oscap packages Follow up to https://github.com/osbuild/image-builder-crc/pull/1659. This updates test to check required Oscap packages to match updated set. --- playwright/Customizations/OpenSCAP.spec.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/playwright/Customizations/OpenSCAP.spec.ts b/playwright/Customizations/OpenSCAP.spec.ts index 7784cc12..aa575022 100644 --- a/playwright/Customizations/OpenSCAP.spec.ts +++ b/playwright/Customizations/OpenSCAP.spec.ts @@ -63,10 +63,9 @@ test('Create a blueprint with OpenSCAP customization', async ({ .nth(3) ).toBeVisible(); await frame.getByRole('button', { name: 'Additional packages' }).click(); - await frame.getByRole('button', { name: 'Selected (9)' }).click(); + await frame.getByRole('button', { name: 'Selected (8)' }).click(); await expect(frame.getByRole('gridcell', { name: 'aide' })).toBeVisible(); await expect(frame.getByRole('gridcell', { name: 'chrony' })).toBeVisible(); - await expect(frame.getByRole('gridcell', { name: 'cronie' })).toBeVisible(); await expect( frame.getByRole('gridcell', { name: 'firewalld' }) ).toBeVisible(); @@ -127,13 +126,12 @@ test('Create a blueprint with OpenSCAP customization', async ({ frame.getByText('Required by OpenSCAPaudit_backlog_limit=8192audit=') ).toBeVisible(); await frame.getByRole('button', { name: 'Additional packages' }).click(); - await frame.getByRole('button', { name: 'Selected (11)' }).click(); + await frame.getByRole('button', { name: 'Selected (10)' }).click(); await expect(frame.getByRole('gridcell', { name: 'aide' })).toBeVisible(); await expect( frame.getByRole('gridcell', { name: 'audit-libs' }) ).toBeVisible(); await expect(frame.getByRole('gridcell', { name: 'chrony' })).toBeVisible(); - await expect(frame.getByRole('gridcell', { name: 'cronie' })).toBeVisible(); await expect( frame.getByRole('gridcell', { name: 'firewalld' }) ).toBeVisible(); From 1bfc830147aafd463288cc73467b275cc7b9d6e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Budai?= <ondrej@budai.cz> Date: Thu, 31 Jul 2025 18:35:08 +0200 Subject: [PATCH 052/123] remove as much edge mgmt code as possible We no longer include the edge mgmt federated module so let's remove all remaining traces of the integration. --- README.md | 2 +- api/codegen.sh | 1 - api/config/edge.ts | 36 -- eslint.config.js | 1 - .../utilities/requestMapper.ts | 1 - src/Hooks/Edge/useGetNotificationProp.ts | 34 -- src/constants.ts | 1 - src/store/edgeApi.ts | 1 - src/store/index.ts | 2 - src/store/service/edgeApi.ts | 578 ------------------ src/store/service/emptyEdgeApi.ts | 10 - 11 files changed, 1 insertion(+), 666 deletions(-) delete mode 100644 api/config/edge.ts delete mode 100644 src/Hooks/Edge/useGetNotificationProp.ts delete mode 100644 src/store/edgeApi.ts delete mode 100644 src/store/service/edgeApi.ts delete mode 100644 src/store/service/emptyEdgeApi.ts diff --git a/README.md b/README.md index 500e1d02..66244e72 100644 --- a/README.md +++ b/README.md @@ -166,7 +166,7 @@ import type { ConfigFile } from '@rtk-query/codegen-openapi'; const config: ConfigFile = { schemaFile: 'URL_TO_THE_OPENAPI_SCHEMA', apiFile: '../../src/store/emptyFoobarApi.ts', - apiImport: 'emptyEdgeApi', + apiImport: 'emptyContentSourcesApi', outputFile: '../../src/store/foobarApi.ts', exportName: 'foobarApi', hooks: true, diff --git a/api/codegen.sh b/api/codegen.sh index a0bd9ff4..f7a0f4a2 100644 --- a/api/codegen.sh +++ b/api/codegen.sh @@ -5,7 +5,6 @@ npx @rtk-query/codegen-openapi ./api/config/imageBuilder.ts & npx @rtk-query/codegen-openapi ./api/config/rhsm.ts & npx @rtk-query/codegen-openapi ./api/config/contentSources.ts & npx @rtk-query/codegen-openapi ./api/config/provisioning.ts & -npx @rtk-query/codegen-openapi ./api/config/edge.ts & npx @rtk-query/codegen-openapi ./api/config/compliance.ts & npx @rtk-query/codegen-openapi ./api/config/composerCloudApi.ts & diff --git a/api/config/edge.ts b/api/config/edge.ts deleted file mode 100644 index 4b1aa139..00000000 --- a/api/config/edge.ts +++ /dev/null @@ -1,36 +0,0 @@ -import type { ConfigFile } from '@rtk-query/codegen-openapi'; - -const config: ConfigFile = { - schemaFile: 'https://console.redhat.com/api/edge/v1/openapi.json', - apiFile: '../../src/store/service/emptyEdgeApi.ts', - apiImport: 'emptyEdgeApi', - outputFile: '../../src/store/service/edgeApi.ts', - exportName: 'edgeApi', - hooks: true, - unionUndefined: true, - filterEndpoints: [ - 'createImage', - 'createImageUpdate', - 'getAllImages', - 'getImageStatusByID', - 'getImageByID', - 'getImageDetailsByID', - 'getImageByOstree', - 'createInstallerForImage', - 'getRepoForImage', - 'getMetadataForImage', - 'createKickStartForImage', - 'checkImageName', - 'retryCreateImage', - 'listAllImageSets', - 'getImageSetsByID', - 'getImageSetsView', - 'getImageSetViewByID', - 'getAllImageSetImagesView', - 'getImageSetsDevicesByID', - 'deleteImageSet', - 'getImageSetImageView', - ], -}; - -export default config; diff --git a/eslint.config.js b/eslint.config.js index 0f786976..0c4750c1 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -21,7 +21,6 @@ module.exports = defineConfig([ '**/contentSourcesApi.ts', '**/rhsmApi.ts', '**/provisioningApi.ts', - '**/edgeApi.ts', '**/complianceApi.ts', '**/composerCloudApi.ts' ] diff --git a/src/Components/CreateImageWizard/utilities/requestMapper.ts b/src/Components/CreateImageWizard/utilities/requestMapper.ts index b0a7b3a7..9ae2c772 100644 --- a/src/Components/CreateImageWizard/utilities/requestMapper.ts +++ b/src/Components/CreateImageWizard/utilities/requestMapper.ts @@ -510,7 +510,6 @@ const uploadTypeByTargetEnv = ( case 'ami': return 'aws'; default: { - // TODO: add edge type throw new Error(`image type: ${imageType} has no implementation yet`); } } diff --git a/src/Hooks/Edge/useGetNotificationProp.ts b/src/Hooks/Edge/useGetNotificationProp.ts deleted file mode 100644 index d444a175..00000000 --- a/src/Hooks/Edge/useGetNotificationProp.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { useAddNotification } from '@redhat-cloud-services/frontend-components-notifications/hooks'; - -const manageEdgeImagesUrlName = 'manage-edge-images'; - -const useGetNotificationProp = () => { - const addNotification = useAddNotification(); - return { - hasInfo: (hasInfoMessage: Notification) => { - addNotification({ - variant: 'info', - ...hasInfoMessage, - }); - }, - hasSuccess: (hasSuccessMessage: Notification) => { - addNotification({ - variant: 'success', - ...hasSuccessMessage, - }); - }, - /* eslint-disable @typescript-eslint/no-explicit-any */ - err: (errMessage: any, err: any) => { - addNotification({ - variant: 'danger', - ...errMessage, - // Add error message from API, if present - description: err?.Title - ? `${errMessage.description}: ${err.Title}` - : errMessage.description, - }); - }, - }; -}; - -export { useGetNotificationProp, manageEdgeImagesUrlName }; diff --git a/src/constants.ts b/src/constants.ts index f278414c..d629963a 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -2,7 +2,6 @@ import type { ImageTypes } from './store/imageBuilderApi'; export const IMAGE_BUILDER_API = '/api/image-builder/v1'; export const RHSM_API = '/api/rhsm/v2'; -export const EDGE_API = '/api/edge/v1'; export const CONTENT_SOURCES_API = '/api/content-sources/v1'; export const PROVISIONING_API = '/api/provisioning/v1'; export const COMPLIANCE_API = '/api/compliance/v2'; diff --git a/src/store/edgeApi.ts b/src/store/edgeApi.ts deleted file mode 100644 index 765c71a8..00000000 --- a/src/store/edgeApi.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './service/edgeApi'; diff --git a/src/store/index.ts b/src/store/index.ts index 8adab09f..3759201a 100644 --- a/src/store/index.ts +++ b/src/store/index.ts @@ -6,7 +6,6 @@ import { cloudProviderConfigSlice } from './cloudProviderConfigSlice'; import { cockpitApi } from './cockpit/cockpitApi'; import { complianceApi } from './complianceApi'; import { contentSourcesApi } from './contentSourcesApi'; -import { edgeApi } from './edgeApi'; import { listenerMiddleware, startAppListening } from './listenerMiddleware'; import { provisioningApi } from './provisioningApi'; import { rhsmApi } from './rhsmApi'; @@ -22,7 +21,6 @@ import wizardSlice, { export const serviceReducer = combineReducers({ [contentSourcesApi.reducerPath]: contentSourcesApi.reducer, - [edgeApi.reducerPath]: edgeApi.reducer, [imageBuilderApi.reducerPath]: imageBuilderApi.reducer, [rhsmApi.reducerPath]: rhsmApi.reducer, [provisioningApi.reducerPath]: provisioningApi.reducer, diff --git a/src/store/service/edgeApi.ts b/src/store/service/edgeApi.ts deleted file mode 100644 index 809f1d56..00000000 --- a/src/store/service/edgeApi.ts +++ /dev/null @@ -1,578 +0,0 @@ -import { emptyEdgeApi as api } from "./emptyEdgeApi"; -const injectedRtkApi = api.injectEndpoints({ - endpoints: (build) => ({ - listAllImageSets: build.query< - ListAllImageSetsApiResponse, - ListAllImageSetsApiArg - >({ - query: (queryArg) => ({ - url: `/image-sets`, - params: { - sort_by: queryArg.sortBy, - name: queryArg.name, - status: queryArg.status, - limit: queryArg.limit, - offset: queryArg.offset, - }, - }), - }), - getImageSetsView: build.query< - GetImageSetsViewApiResponse, - GetImageSetsViewApiArg - >({ - query: (queryArg) => ({ - url: `/image-sets/view`, - params: { - sort_by: queryArg.sortBy, - name: queryArg.name, - status: queryArg.status, - id: queryArg.id, - limit: queryArg.limit, - offset: queryArg.offset, - }, - }), - }), - getImageSetImageView: build.query< - GetImageSetImageViewApiResponse, - GetImageSetImageViewApiArg - >({ - query: (queryArg) => ({ - url: `/image-sets/view/${queryArg.imageSetId}/versions/${queryArg.imageId}`, - }), - }), - getAllImageSetImagesView: build.query< - GetAllImageSetImagesViewApiResponse, - GetAllImageSetImagesViewApiArg - >({ - query: (queryArg) => ({ - url: `/image-sets/view/${queryArg.imageSetId}/versions`, - params: { - sort_by: queryArg.sortBy, - status: queryArg.status, - version: queryArg.version, - limit: queryArg.limit, - offset: queryArg.offset, - }, - }), - }), - deleteImageSet: build.mutation< - DeleteImageSetApiResponse, - DeleteImageSetApiArg - >({ - query: (queryArg) => ({ - url: `/image-sets/${queryArg.imageSetId}`, - method: "DELETE", - }), - }), - getAllImages: build.query<GetAllImagesApiResponse, GetAllImagesApiArg>({ - query: (queryArg) => ({ - url: `/images`, - params: { - limit: queryArg.limit, - offset: queryArg.offset, - sort_by: queryArg.sortBy, - name: queryArg.name, - status: queryArg.status, - distribution: queryArg.distribution, - created_at: queryArg.createdAt, - }, - }), - }), - createImage: build.mutation<CreateImageApiResponse, CreateImageApiArg>({ - query: (queryArg) => ({ - url: `/images`, - method: "POST", - body: queryArg.createImage, - }), - }), - checkImageName: build.mutation< - CheckImageNameApiResponse, - CheckImageNameApiArg - >({ - query: (queryArg) => ({ - url: `/images/checkImageName`, - method: "POST", - body: queryArg.createImage, - }), - }), - createInstallerForImage: build.mutation< - CreateInstallerForImageApiResponse, - CreateInstallerForImageApiArg - >({ - query: (queryArg) => ({ - url: `/images/${queryArg.imageId}/installer`, - method: "POST", - body: queryArg.createImage, - }), - }), - createKickStartForImage: build.mutation< - CreateKickStartForImageApiResponse, - CreateKickStartForImageApiArg - >({ - query: (queryArg) => ({ - url: `/images/${queryArg.imageId}/kickstart`, - method: "POST", - body: queryArg.createImage, - }), - }), - getMetadataForImage: build.query< - GetMetadataForImageApiResponse, - GetMetadataForImageApiArg - >({ - query: (queryArg) => ({ url: `/images/${queryArg.imageId}/metadata` }), - }), - getRepoForImage: build.query< - GetRepoForImageApiResponse, - GetRepoForImageApiArg - >({ - query: (queryArg) => ({ url: `/images/${queryArg.imageId}/repo` }), - }), - retryCreateImage: build.mutation< - RetryCreateImageApiResponse, - RetryCreateImageApiArg - >({ - query: (queryArg) => ({ - url: `/images/${queryArg.imageId}/retry`, - method: "POST", - body: queryArg.createImage, - }), - }), - createImageUpdate: build.mutation< - CreateImageUpdateApiResponse, - CreateImageUpdateApiArg - >({ - query: (queryArg) => ({ - url: `/images/${queryArg.imageId}/update`, - method: "POST", - body: queryArg.createImage, - }), - }), - getImageByOstree: build.query< - GetImageByOstreeApiResponse, - GetImageByOstreeApiArg - >({ - query: (queryArg) => ({ - url: `/images/${queryArg.ostreeCommitHash}/info`, - }), - }), - }), - overrideExisting: false, -}); -export { injectedRtkApi as edgeApi }; -export type ListAllImageSetsApiResponse = - /** status 200 OK */ ModelsImageSetsResponseApi; -export type ListAllImageSetsApiArg = { - /** Define sort fields: created_at, updated_at, name. To sort DESC use - */ - sortBy?: string; - /** field: filter by name */ - name?: string; - /** field: filter by status */ - status?: string; - /** field: return number of image-set view until limit is reached. Default is 100. */ - limit?: number; - /** field: return number of image-set view beginning at the offset. */ - offset?: number; -}; -export type GetImageSetsViewApiResponse = - /** status 200 OK */ ModelsImageSetsViewResponseApi; -export type GetImageSetsViewApiArg = { - /** Define sort fields: created_at, updated_at, name. To sort DESC use - */ - sortBy?: string; - /** field: filter by name */ - name?: string; - /** field: filter by status */ - status?: string; - /** field: filter by id */ - id?: number; - /** field: return number of image-set view until limit is reached. Default is 30. */ - limit?: number; - /** field: return number of image-set view beginning at the offset. */ - offset?: number; -}; -export type GetImageSetImageViewApiResponse = - /** status 200 OK */ ModelsImageSetImageIdViewApi; -export type GetImageSetImageViewApiArg = { - /** the image set id */ - imageSetId: number; - /** the image id */ - imageId: number; -}; -export type GetAllImageSetImagesViewApiResponse = - /** status 200 OK */ ModelsImagesViewDataApi; -export type GetAllImageSetImagesViewApiArg = { - /** the image-set id */ - imageSetId: number; - /** Define sort fields: created_at, version, To sort DESC use - */ - sortBy?: string; - /** field: filter by status */ - status?: string; - /** field: filter by version */ - version?: string; - /** field: return number of images until limit is reached. Default is 100. */ - limit?: number; - /** field: return number of images beginning at the offset. */ - offset?: number; -}; -export type DeleteImageSetApiResponse = /** status 200 OK */ ModelsImageSetApi; -export type DeleteImageSetApiArg = { - /** Identifier of the ImageSet */ - imageSetId: number; -}; -export type GetAllImagesApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type GetAllImagesApiArg = { - /** Return number of images until limit is reached. */ - limit?: number; - /** Return number of images beginning at the offset */ - offset?: number; - /** created_at, distribution, name,status. To sort DESC use -before the fields */ - sortBy?: string; - /** Filter by name. */ - name?: string; - /** Filter by status. */ - status?: string; - /** Filter by distribution. */ - distribution?: string; - /** Filter by creation date. */ - createdAt?: string; -}; -export type CreateImageApiResponse = /** status 200 OK */ ImageResponse; -export type CreateImageApiArg = { - /** request body */ - createImage: CreateImage; -}; -export type CheckImageNameApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type CheckImageNameApiArg = { - /** request body */ - createImage: CreateImage; -}; -export type CreateInstallerForImageApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type CreateInstallerForImageApiArg = { - /** Image ID */ - imageId: number; - /** request body */ - createImage: CreateImage; -}; -export type CreateKickStartForImageApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type CreateKickStartForImageApiArg = { - /** Image ID */ - imageId: number; - /** request body */ - createImage: CreateImage; -}; -export type GetMetadataForImageApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type GetMetadataForImageApiArg = { - /** Image ID */ - imageId: number; -}; -export type GetRepoForImageApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type GetRepoForImageApiArg = { - /** Image ID */ - imageId: number; -}; -export type RetryCreateImageApiResponse = - /** status 201 Retry is being processed */ ModelsSuccessPlaceholderResponse; -export type RetryCreateImageApiArg = { - /** Image ID */ - imageId: number; - /** request body */ - createImage: CreateImage; -}; -export type CreateImageUpdateApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type CreateImageUpdateApiArg = { - /** Image ID */ - imageId: number; - /** request body */ - createImage: CreateImage; -}; -export type GetImageByOstreeApiResponse = - /** status 200 OK */ ModelsSuccessPlaceholderResponse; -export type GetImageByOstreeApiArg = { - /** Ostree Commit Hash */ - ostreeCommitHash: string; -}; -export type ModelsEdgeApiTime = { - time?: string | undefined; - /** Valid is true if Time is not NULL */ - valid?: boolean | undefined; -}; -export type GormDeletedAt = { - time?: string | undefined; - /** Valid is true if Time is not NULL */ - valid?: boolean | undefined; -}; -export type ModelsInstalledPackage = { - ID?: number | undefined; - arch?: string | undefined; - commits?: ModelsCommit[] | undefined; - epoch?: string | undefined; - name?: string | undefined; - release?: string | undefined; - sigmd5?: string | undefined; - signature?: string | undefined; - type?: string | undefined; - version?: string | undefined; -}; -export type ModelsRepo = { - CreatedAt?: ModelsEdgeApiTime | undefined; - DeletedAt?: GormDeletedAt | undefined; - ID?: number | undefined; - /** AWS repo upload status */ - RepoStatus?: string | undefined; - /** AWS repo URL */ - RepoURL?: string | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - /** Pulp Repo ID (used for updates) */ - pulp_repo_id?: string | undefined; - /** Status of Pulp repo import */ - pulp_repo_status?: string | undefined; - /** Distribution URL returned from Pulp */ - pulp_repo_url?: string | undefined; -}; -export type ModelsCommit = { - Account?: string | undefined; - Arch?: string | undefined; - BlueprintToml?: string | undefined; - BuildDate?: string | undefined; - BuildNumber?: number | undefined; - ChangesRefs?: boolean | undefined; - ComposeJobID?: string | undefined; - CreatedAt?: ModelsEdgeApiTime | undefined; - DeletedAt?: GormDeletedAt | undefined; - ID?: number | undefined; - ImageBuildHash?: string | undefined; - ImageBuildParentHash?: string | undefined; - ImageBuildTarURL?: string | undefined; - InstalledPackages?: ModelsInstalledPackage[] | undefined; - OSTreeCommit?: string | undefined; - OSTreeParentCommit?: string | undefined; - OSTreeParentRef?: string | undefined; - OSTreeRef?: string | undefined; - Repo?: ModelsRepo | undefined; - RepoID?: number | undefined; - Status?: string | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - external?: boolean | undefined; - name?: string | undefined; - org_id?: string | undefined; -}; -export type ModelsPackage = { - CreatedAt?: ModelsEdgeApiTime | undefined; - DeletedAt?: GormDeletedAt | undefined; - ID?: number | undefined; - Name?: string | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; -}; -export type ModelsInstaller = { - Account?: string | undefined; - Checksum?: string | undefined; - ComposeJobID?: string | undefined; - CreatedAt?: ModelsEdgeApiTime | undefined; - DeletedAt?: GormDeletedAt | undefined; - ID?: number | undefined; - ImageBuildISOURL?: string | undefined; - SshKey?: string | undefined; - Status?: string | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - Username?: string | undefined; - org_id?: string | undefined; -}; -export type ModelsThirdPartyRepo = { - CreatedAt?: ModelsEdgeApiTime | undefined; - DeletedAt?: GormDeletedAt | undefined; - Description?: string | undefined; - ID?: number | undefined; - Images?: ModelsImage[] | undefined; - Name?: string | undefined; - URL?: string | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - account?: string | undefined; - distribution_arch?: string | undefined; - distribution_version?: string[] | undefined; - gpg_key?: string | undefined; - org_id?: string | undefined; - package_count?: number | undefined; - uuid?: string | undefined; -}; -export type ModelsImage = { - Account?: string | undefined; - Commit?: ModelsCommit | undefined; - CommitID?: number | undefined; - CreatedAt?: ModelsEdgeApiTime | undefined; - CustomPackages?: ModelsPackage[] | undefined; - DeletedAt?: GormDeletedAt | undefined; - Description?: string | undefined; - Distribution?: string | undefined; - ID?: number | undefined; - /** TODO: Wipe staging database and set to not nullable */ - ImageSetID?: number | undefined; - /** TODO: Remove as soon as the frontend stops using */ - ImageType?: string | undefined; - Installer?: ModelsInstaller | undefined; - InstallerID?: number | undefined; - Name?: string | undefined; - OutputTypes?: string[] | undefined; - Packages?: ModelsPackage[] | undefined; - Status?: string | undefined; - /** only for forms */ - SystemsRunning?: number | undefined; - ThirdPartyRepositories?: ModelsThirdPartyRepo[] | undefined; - /** only for forms */ - TotalPackages?: number | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - Version?: number | undefined; - activationKey?: string | undefined; - org_id?: string | undefined; - /** storing for logging reference on resume */ - request_id?: string | undefined; -}; -export type ModelsImageSetApi = { - CreatedAt?: ModelsEdgeApiTime | undefined; - DeletedAt?: GormDeletedAt | undefined; - ID?: number | undefined; - /** images of image set */ - Images?: ModelsImage[] | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - /** the image set name */ - name?: string | undefined; - /** the image set version */ - version?: number | undefined; -}; -export type ModelsImageSetInstallerUrlapi = { - /** The image-set latest available image ISO */ - image_build_iso_url?: string | undefined; - /** image set data */ - image_set?: ModelsImageSetApi | undefined; -}; -export type ModelsImageSetsResponseApi = { - /** count of image-sets */ - Count?: number | undefined; - /** all data of image-sets */ - Data?: ModelsImageSetInstallerUrlapi[] | undefined; -}; -export type ErrorsBadRequest = { - Code?: string | undefined; - Status?: number | undefined; - Title?: string | undefined; -}; -export type ErrorsNotFound = { - Code?: string | undefined; - Status?: number | undefined; - Title?: string | undefined; -}; -export type ErrorsInternalServerError = { - Code?: string | undefined; - Status?: number | undefined; - Title?: string | undefined; -}; -export type ModelsImageSetView = { - Distribution?: string | undefined; - ID?: number | undefined; - ImageBuildIsoURL?: string | undefined; - ImageID?: number | undefined; - Name?: string | undefined; - OutputTypes?: string[] | undefined; - Status?: string | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - Version?: number | undefined; -}; -export type ModelsImageSetsViewResponseApi = { - /** count of image-sets */ - count?: number | undefined; - /** data of image set view */ - data?: ModelsImageSetView[] | undefined; -}; -export type ModelsImageDetailApi = { - /** Number of additional packages */ - additional_packages?: number | undefined; - image?: ModelsImage | undefined; - /** Number of packages */ - packages?: number | undefined; - /** Number of added update */ - update_added?: number | undefined; - /** Number of removed update */ - update_removed?: number | undefined; - /** Number of updated update */ - update_updated?: number | undefined; -}; -export type ModelsImageSetImageIdViewApi = { - /** The image-set latest available image ISO */ - ImageBuildIsoURL?: string | undefined; - /** the requested image details */ - ImageDetails?: ModelsImageDetailApi | undefined; - /** image set data */ - ImageSet?: ModelsImageSetApi | undefined; -}; -export type ModelsImageView = { - CommitCheckSum?: string | undefined; - CreatedAt?: ModelsEdgeApiTime | undefined; - ID?: number | undefined; - ImageBuildIsoURL?: string | undefined; - ImageType?: string | undefined; - Name?: string | undefined; - OutputTypes?: string[] | undefined; - Status?: string | undefined; - Version?: number | undefined; -}; -export type ModelsImagesViewDataApi = { - /** total number of image view data */ - count?: number | undefined; - data?: ModelsImageView[] | undefined; -}; -export type ModelsSuccessPlaceholderResponse = object; -export type ImageResponse = { - Account?: string | undefined; - Commit?: ModelsCommit | undefined; - CommitID?: number | undefined; - CreatedAt?: ModelsEdgeApiTime | undefined; - CustomPackages?: ModelsPackage[] | undefined; - DeletedAt?: GormDeletedAt | undefined; - Description?: string | undefined; - Distribution?: string | undefined; - ID?: number | undefined; - /** TODO: Wipe staging database and set to not nullable */ - ImageSetID?: number | undefined; - /** TODO: Remove as soon as the frontend stops using */ - ImageType?: string | undefined; - Installer?: ModelsInstaller | undefined; - InstallerID?: number | undefined; - Name?: string | undefined; - OutputTypes?: string[] | undefined; - Packages?: ModelsPackage[] | undefined; - Status?: string | undefined; - /** only for forms */ - SystemsRunning?: number | undefined; - ThirdPartyRepositories?: ModelsThirdPartyRepo[] | undefined; - /** only for forms */ - TotalPackages?: number | undefined; - UpdatedAt?: ModelsEdgeApiTime | undefined; - Version?: number | undefined; - activationKey?: string | undefined; - org_id?: string | undefined; - /** storing for logging reference on resume */ - request_id?: string | undefined; -}; -export type CreateImage = object; -export const { - useListAllImageSetsQuery, - useGetImageSetsViewQuery, - useGetImageSetImageViewQuery, - useGetAllImageSetImagesViewQuery, - useDeleteImageSetMutation, - useGetAllImagesQuery, - useCreateImageMutation, - useCheckImageNameMutation, - useCreateInstallerForImageMutation, - useCreateKickStartForImageMutation, - useGetMetadataForImageQuery, - useGetRepoForImageQuery, - useRetryCreateImageMutation, - useCreateImageUpdateMutation, - useGetImageByOstreeQuery, -} = injectedRtkApi; diff --git a/src/store/service/emptyEdgeApi.ts b/src/store/service/emptyEdgeApi.ts deleted file mode 100644 index 786f8aa1..00000000 --- a/src/store/service/emptyEdgeApi.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { createApi, fetchBaseQuery } from '@reduxjs/toolkit/query/react'; - -import { EDGE_API } from '../../constants'; - -// initialize an empty api service that we'll inject endpoints into later as needed -export const emptyEdgeApi = createApi({ - reducerPath: 'edgeApi', - baseQuery: fetchBaseQuery({ baseUrl: window.location.origin + EDGE_API }), - endpoints: () => ({}), -}); From 327e1cd48f107f123806b400ccb72d88b9f08715 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Wed, 30 Jul 2025 10:49:58 +0200 Subject: [PATCH 053/123] src: Fix `useChrome` import, update mock, solve some lint warnings This fixes the way we're importing `useChrome` in some places. The mock was also updated to reflect the changes. This resolves several lint warnings. --- src/App.tsx | 2 +- .../Blueprints/BlueprintsSideBar.tsx | 7 +++-- .../Blueprints/BuildImagesButton.tsx | 7 +++-- .../Blueprints/DeleteBlueprintModal.tsx | 7 +++-- .../steps/Registration/index.tsx | 5 +++- .../steps/Review/Footer/CreateDropdown.tsx | 17 ++++++++--- .../steps/Review/Footer/EditDropdown.tsx | 18 +++++++++--- .../steps/Review/Footer/Footer.tsx | 4 +-- src/Components/ImagesTable/ImageDetails.tsx | 9 ++++-- src/Components/ImagesTable/ImagesTable.tsx | 29 +++++++++++++------ src/Components/ImagesTable/Instance.tsx | 11 +++++-- src/Components/ImagesTable/Status.tsx | 9 ++++-- src/Components/LandingPage/NewAlert.tsx | 2 +- src/Components/LandingPage/Quickstarts.tsx | 2 +- src/Utilities/useGetEnvironment.ts | 2 +- src/test/setup.ts | 27 ++++++++--------- 16 files changed, 108 insertions(+), 50 deletions(-) diff --git a/src/App.tsx b/src/App.tsx index f77a0c17..fadac91d 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,6 +1,6 @@ import React, { useEffect } from 'react'; -import { useChrome } from '@redhat-cloud-services/frontend-components/useChrome'; +import useChrome from '@redhat-cloud-services/frontend-components/useChrome'; import NotificationsProvider from '@redhat-cloud-services/frontend-components-notifications/NotificationsProvider'; import '@patternfly/patternfly/patternfly-addons.css'; diff --git a/src/Components/Blueprints/BlueprintsSideBar.tsx b/src/Components/Blueprints/BlueprintsSideBar.tsx index 035be843..02337d32 100644 --- a/src/Components/Blueprints/BlueprintsSideBar.tsx +++ b/src/Components/Blueprints/BlueprintsSideBar.tsx @@ -75,10 +75,13 @@ const BlueprintsSidebar = () => { useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); if (blueprintSearchInput) { searchParams.search = blueprintSearchInput; diff --git a/src/Components/Blueprints/BuildImagesButton.tsx b/src/Components/Blueprints/BuildImagesButton.tsx index 9bc3d7ba..2ca2498a 100644 --- a/src/Components/Blueprints/BuildImagesButton.tsx +++ b/src/Components/Blueprints/BuildImagesButton.tsx @@ -42,10 +42,13 @@ export const BuildImagesButton = ({ children }: BuildImagesButtonPropTypes) => { useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); const onBuildHandler = async () => { if (selectedBlueprintId) { diff --git a/src/Components/Blueprints/DeleteBlueprintModal.tsx b/src/Components/Blueprints/DeleteBlueprintModal.tsx index aa112216..ca1dcc79 100644 --- a/src/Components/Blueprints/DeleteBlueprintModal.tsx +++ b/src/Components/Blueprints/DeleteBlueprintModal.tsx @@ -46,10 +46,13 @@ export const DeleteBlueprintModal: React.FunctionComponent< useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); const searchParams: GetBlueprintsApiArg = { limit: blueprintsLimit, diff --git a/src/Components/CreateImageWizard/steps/Registration/index.tsx b/src/Components/CreateImageWizard/steps/Registration/index.tsx index 12400170..11ed3ad4 100644 --- a/src/Components/CreateImageWizard/steps/Registration/index.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/index.tsx @@ -28,10 +28,13 @@ const RegistrationStep = () => { useEffect(() => { (async () => { - const userData = await auth?.getUser(); + const userData = await auth.getUser(); const id = userData?.identity?.internal?.org_id; setOrgId(id); })(); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps }, []); const activationKey = useAppSelector(selectActivationKey); diff --git a/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx b/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx index 1f50f45f..43e72414 100644 --- a/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx +++ b/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx @@ -47,12 +47,17 @@ export const CreateSaveAndBuildBtn = ({ const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth, isBeta } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + const packages = useAppSelector(selectPackages); const { trigger: buildBlueprint } = useComposeBlueprintMutation(); @@ -112,10 +117,14 @@ export const CreateSaveButton = ({ useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + const packages = useAppSelector(selectPackages); const { trigger: createBlueprint, isLoading } = useCreateBlueprintMutation({ diff --git a/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx b/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx index 132e4818..c4577e4f 100644 --- a/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx +++ b/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx @@ -40,12 +40,17 @@ export const EditSaveAndBuildBtn = ({ const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth, isBeta } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + const { trigger: buildBlueprint } = useComposeBlueprintMutation(); const packages = useAppSelector(selectPackages); @@ -103,12 +108,17 @@ export const EditSaveButton = ({ const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth, isBeta } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + const packages = useAppSelector(selectPackages); const { trigger: updateBlueprint, isLoading } = useUpdateBlueprintMutation({ diff --git a/src/Components/CreateImageWizard/steps/Review/Footer/Footer.tsx b/src/Components/CreateImageWizard/steps/Review/Footer/Footer.tsx index d1745c5f..d4d02b51 100644 --- a/src/Components/CreateImageWizard/steps/Review/Footer/Footer.tsx +++ b/src/Components/CreateImageWizard/steps/Review/Footer/Footer.tsx @@ -9,7 +9,7 @@ import { WizardFooterWrapper, } from '@patternfly/react-core'; import { MenuToggleElement } from '@patternfly/react-core/dist/esm/components/MenuToggle/MenuToggle'; -import { useChrome } from '@redhat-cloud-services/frontend-components/useChrome'; +import useChrome from '@redhat-cloud-services/frontend-components/useChrome'; import { useStore } from 'react-redux'; import { useNavigate, useParams } from 'react-router-dom'; @@ -52,7 +52,7 @@ const ReviewWizardFooter = () => { const getBlueprintPayload = async () => { if (!process.env.IS_ON_PREMISE) { - const userData = await auth?.getUser(); + const userData = await auth.getUser(); const orgId = userData?.identity?.internal?.org_id; const requestBody = orgId && mapRequestFromState(store, orgId); return requestBody; diff --git a/src/Components/ImagesTable/ImageDetails.tsx b/src/Components/ImagesTable/ImageDetails.tsx index 9e830c22..a0ab0a97 100644 --- a/src/Components/ImagesTable/ImageDetails.tsx +++ b/src/Components/ImagesTable/ImageDetails.tsx @@ -137,12 +137,17 @@ export const AwsDetails = ({ compose }: AwsDetailsPropTypes) => { const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + if (!isAwsUploadRequestOptions(options)) { throw TypeError( `Error: options must be of type AwsUploadRequestOptions, not ${typeof options}.` diff --git a/src/Components/ImagesTable/ImagesTable.tsx b/src/Components/ImagesTable/ImagesTable.tsx index 73c0a020..f0a52bee 100644 --- a/src/Components/ImagesTable/ImagesTable.tsx +++ b/src/Components/ImagesTable/ImagesTable.tsx @@ -104,12 +104,16 @@ const ImagesTable = () => { const blueprintsLimit = useAppSelector(selectLimit) || PAGINATION_LIMIT; const { analytics, auth } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); const searchParamsGetBlueprints: GetBlueprintsApiArg = { limit: blueprintsLimit, @@ -465,18 +469,20 @@ const AwsRow = ({ compose, composeStatus, rowIndex }: AwsRowPropTypes) => { const navigate = useNavigate(); const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + const target = <AwsTarget compose={compose} />; - const status = <CloudStatus compose={compose} />; - const instance = <CloudInstance compose={compose} />; - const details = <AwsDetails compose={compose} />; const actions = ( @@ -549,12 +555,17 @@ const Row = ({ }: RowPropTypes) => { const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + const [isExpanded, setIsExpanded] = useState(false); const handleToggle = () => setIsExpanded(!isExpanded); const dispatch = useDispatch(); diff --git a/src/Components/ImagesTable/Instance.tsx b/src/Components/ImagesTable/Instance.tsx index 4f1526c2..dda9892c 100644 --- a/src/Components/ImagesTable/Instance.tsx +++ b/src/Components/ImagesTable/Instance.tsx @@ -19,7 +19,7 @@ import { OrderType, } from '@patternfly/react-core/dist/esm/components/List/List'; import { ExternalLinkAltIcon } from '@patternfly/react-icons'; -import { useChrome } from '@redhat-cloud-services/frontend-components/useChrome'; +import useChrome from '@redhat-cloud-services/frontend-components/useChrome'; import { ChromeUser } from '@redhat-cloud-services/types'; import { useLoadModule, useScalprum } from '@scalprum/react-core'; import cockpit from 'cockpit'; @@ -100,12 +100,17 @@ const ProvisioningLink = ({ const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + const [wizardOpen, setWizardOpen] = useState(false); const [exposedScalprumModule, error] = useLoadModule( { diff --git a/src/Components/ImagesTable/Status.tsx b/src/Components/ImagesTable/Status.tsx index 7d0dba19..4785f293 100644 --- a/src/Components/ImagesTable/Status.tsx +++ b/src/Components/ImagesTable/Status.tsx @@ -124,12 +124,17 @@ export const CloudStatus = ({ compose }: CloudStatusPropTypes) => { }); const [userData, setUserData] = useState<ChromeUser | void>(undefined); const { analytics, auth } = useChrome(); + useEffect(() => { (async () => { - const data = await auth?.getUser(); + const data = await auth.getUser(); setUserData(data); })(); - }, [auth]); + // This useEffect hook should run *only* on mount and therefore has an empty + // dependency array. eslint's exhaustive-deps rule does not support this use. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); + if (!isSuccess) { return <Skeleton />; } diff --git a/src/Components/LandingPage/NewAlert.tsx b/src/Components/LandingPage/NewAlert.tsx index 2a38e143..e5c19a60 100644 --- a/src/Components/LandingPage/NewAlert.tsx +++ b/src/Components/LandingPage/NewAlert.tsx @@ -10,7 +10,7 @@ import { } from '@patternfly/react-core'; // Import for optional quickstarts functionality -// import { useChrome } from '@redhat-cloud-services/frontend-components/useChrome'; +// import useChrome from '@redhat-cloud-services/frontend-components/useChrome'; type NewAlertPropTypes = { setShowAlert: React.Dispatch<React.SetStateAction<boolean>>; diff --git a/src/Components/LandingPage/Quickstarts.tsx b/src/Components/LandingPage/Quickstarts.tsx index 4c1119ed..7c9ace87 100644 --- a/src/Components/LandingPage/Quickstarts.tsx +++ b/src/Components/LandingPage/Quickstarts.tsx @@ -2,7 +2,7 @@ import React, { useState } from 'react'; import { Button, ExpandableSection } from '@patternfly/react-core'; import { ArrowRightIcon } from '@patternfly/react-icons'; -import { useChrome } from '@redhat-cloud-services/frontend-components/useChrome'; +import useChrome from '@redhat-cloud-services/frontend-components/useChrome'; export const Quickstarts = () => { const [showHint, setShowHint] = useState(true); diff --git a/src/Utilities/useGetEnvironment.ts b/src/Utilities/useGetEnvironment.ts index e6769638..db6dc91f 100644 --- a/src/Utilities/useGetEnvironment.ts +++ b/src/Utilities/useGetEnvironment.ts @@ -1,4 +1,4 @@ -import { useChrome } from '@redhat-cloud-services/frontend-components/useChrome'; +import useChrome from '@redhat-cloud-services/frontend-components/useChrome'; import { useFlag as useUnleashFlag } from '@unleash/proxy-client-react'; export const useGetEnvironment = process.env.IS_ON_PREMISE diff --git a/src/test/setup.ts b/src/test/setup.ts index d3675dfd..a21cefa0 100644 --- a/src/test/setup.ts +++ b/src/test/setup.ts @@ -7,6 +7,12 @@ import 'vitest-canvas-mock'; // scrollTo is not defined in jsdom - needed for the navigation to the wizard window.HTMLElement.prototype.scrollTo = function () {}; +// provide a fallback *only* when window.getComputedStyle is missing +// eslint-disable-next-line disable-autofix/@typescript-eslint/no-unnecessary-condition +window.getComputedStyle = window.getComputedStyle || (() => ({ + getPropertyValue: () => '', +})); + // ResizeObserver is not defined and needs to be mocked and stubbed const MockResizeObserver = vi.fn(() => ({ observe: vi.fn(), @@ -16,29 +22,24 @@ const MockResizeObserver = vi.fn(() => ({ vi.stubGlobal('ResizeObserver', MockResizeObserver); vi.mock('@redhat-cloud-services/frontend-components/useChrome', () => ({ - useChrome: () => ({ + default: () => ({ auth: { - getUser: () => { - return { - identity: { - internal: { - org_id: 5, - }, + getUser: async () => ({ + identity: { + internal: { + org_id: 5, }, - }; - }, + }, + }), }, isBeta: () => true, isProd: () => true, getEnvironment: () => 'prod', - }), - default: () => ({ analytics: { track: () => 'test', group: () => 'test', screen: () => 'test', }, - isBeta: () => true, }), })); @@ -67,7 +68,7 @@ vi.mock('@unleash/proxy-client-react', () => ({ }), })); -// Remove DOM dump from the testing-library output +// remove DOM dump from the testing-library output configure({ getElementError: (message: string) => { const error = new Error(message); From 0acedb913c09e618b9a51fd71aaa651ae16cdcf2 Mon Sep 17 00:00:00 2001 From: Klara Simickova <49452678+regexowl@users.noreply.github.com> Date: Fri, 1 Aug 2025 12:08:06 +0200 Subject: [PATCH 054/123] Revert "playwright: Add duration to test account creation request" This reverts commit 1096c6d4fbbbc430ed9948de8acb2270815e7135. --- .github/workflows/playwright.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml index d0a3ef0a..5e6ee70e 100644 --- a/.github/workflows/playwright.yml +++ b/.github/workflows/playwright.yml @@ -68,7 +68,7 @@ jobs: export PLAYWRIGHT_USER=image-builder-playwright-$RANDOM export PLAYWRIGHT_PASSWORD=image-builder-playwright-$(uuidgen) # Step 1: Create a new empty account - curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/new -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\", \"duration\":\"1 year\"}" + curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/new -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\"}" # Step 2: Attach subscriptions to the new account curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/attach \ -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\", \"sku\":[\"RH00003\"],\"quantity\": 1}" From 9f526faa651807717b9a72b6570d1e7b89aa3fc9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Aug 2025 06:42:46 +0000 Subject: [PATCH 055/123] build(deps-dev): bump eslint-plugin-playwright from 2.2.1 to 2.2.2 Bumps [eslint-plugin-playwright](https://github.com/playwright-community/eslint-plugin-playwright) from 2.2.1 to 2.2.2. - [Release notes](https://github.com/playwright-community/eslint-plugin-playwright/releases) - [Changelog](https://github.com/playwright-community/eslint-plugin-playwright/blob/main/CHANGELOG.md) - [Commits](https://github.com/playwright-community/eslint-plugin-playwright/compare/v2.2.1...v2.2.2) --- updated-dependencies: - dependency-name: eslint-plugin-playwright dependency-version: 2.2.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 5809861f..40398032 100644 --- a/package-lock.json +++ b/package-lock.json @@ -68,7 +68,7 @@ "eslint-plugin-import": "2.32.0", "eslint-plugin-jest-dom": "5.5.0", "eslint-plugin-jsx-a11y": "6.10.2", - "eslint-plugin-playwright": "2.2.1", + "eslint-plugin-playwright": "2.2.2", "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", @@ -9670,9 +9670,9 @@ } }, "node_modules/eslint-plugin-playwright": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-playwright/-/eslint-plugin-playwright-2.2.1.tgz", - "integrity": "sha512-vYGKs9Y0H2A7tvvuKBF11w2aJa7diS9JRJbo/3Y5nU12RRgZummSUKvfZbickRdNVmt65R4lSrWn8Nyali2a3w==", + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/eslint-plugin-playwright/-/eslint-plugin-playwright-2.2.2.tgz", + "integrity": "sha512-j0jKpndIPOXRRP9uMkwb9l/nSmModOU3452nrFdgFJoEv/435J1onk8+aITzjDW8DfypxgmVaDMdmVIa6F7I0w==", "dev": true, "license": "MIT", "dependencies": { @@ -26106,9 +26106,9 @@ } }, "eslint-plugin-playwright": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-playwright/-/eslint-plugin-playwright-2.2.1.tgz", - "integrity": "sha512-vYGKs9Y0H2A7tvvuKBF11w2aJa7diS9JRJbo/3Y5nU12RRgZummSUKvfZbickRdNVmt65R4lSrWn8Nyali2a3w==", + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/eslint-plugin-playwright/-/eslint-plugin-playwright-2.2.2.tgz", + "integrity": "sha512-j0jKpndIPOXRRP9uMkwb9l/nSmModOU3452nrFdgFJoEv/435J1onk8+aITzjDW8DfypxgmVaDMdmVIa6F7I0w==", "dev": true, "requires": { "globals": "^13.23.0" diff --git a/package.json b/package.json index d1badd65..b88dcc6b 100644 --- a/package.json +++ b/package.json @@ -66,7 +66,7 @@ "eslint-plugin-import": "2.32.0", "eslint-plugin-jest-dom": "5.5.0", "eslint-plugin-jsx-a11y": "6.10.2", - "eslint-plugin-playwright": "2.2.1", + "eslint-plugin-playwright": "2.2.2", "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", From 3b8b2ad240606c4e68094b6dc5275b7da277808a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Aug 2025 06:44:59 +0000 Subject: [PATCH 056/123] build(deps-dev): bump @currents/playwright from 1.15.2 to 1.15.3 Bumps [@currents/playwright](https://github.com/currents-dev/currents-playwright-changelog) from 1.15.2 to 1.15.3. - [Changelog](https://github.com/currents-dev/currents-playwright-changelog/blob/main/CHANGELOG.md) - [Commits](https://github.com/currents-dev/currents-playwright-changelog/commits) --- updated-dependencies: - dependency-name: "@currents/playwright" dependency-version: 1.15.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 40398032..bac37997 100644 --- a/package-lock.json +++ b/package-lock.json @@ -36,7 +36,7 @@ "@babel/preset-env": "7.28.0", "@babel/preset-react": "7.27.1", "@babel/preset-typescript": "7.27.1", - "@currents/playwright": "1.15.2", + "@currents/playwright": "1.15.3", "@eslint/js": "9.31.0", "@patternfly/react-icons": "6.3.0", "@playwright/test": "1.51.1", @@ -2340,9 +2340,9 @@ } }, "node_modules/@currents/playwright": { - "version": "1.15.2", - "resolved": "https://registry.npmjs.org/@currents/playwright/-/playwright-1.15.2.tgz", - "integrity": "sha512-VhmYwlHusieBWAzDoluLbas8CVcnXTwOUiAoZ4lqbSPy3sBpM3fr9/wAv6A8mwtZjUX7QfD56jhtpMImFK7OlQ==", + "version": "1.15.3", + "resolved": "https://registry.npmjs.org/@currents/playwright/-/playwright-1.15.3.tgz", + "integrity": "sha512-m2znwZx+y6Z62d03sfC3wv67bqcMzr4HOuh+aG9a6d1rlpbrc8sx+8NzNSAQmuSuBNrrBJXoVSG7G/uj0E2mLA==", "dev": true, "license": "MIT", "dependencies": { @@ -21447,9 +21447,9 @@ } }, "@currents/playwright": { - "version": "1.15.2", - "resolved": "https://registry.npmjs.org/@currents/playwright/-/playwright-1.15.2.tgz", - "integrity": "sha512-VhmYwlHusieBWAzDoluLbas8CVcnXTwOUiAoZ4lqbSPy3sBpM3fr9/wAv6A8mwtZjUX7QfD56jhtpMImFK7OlQ==", + "version": "1.15.3", + "resolved": "https://registry.npmjs.org/@currents/playwright/-/playwright-1.15.3.tgz", + "integrity": "sha512-m2znwZx+y6Z62d03sfC3wv67bqcMzr4HOuh+aG9a6d1rlpbrc8sx+8NzNSAQmuSuBNrrBJXoVSG7G/uj0E2mLA==", "dev": true, "requires": { "@babel/code-frame": "^7.27.1", diff --git a/package.json b/package.json index b88dcc6b..71cc6d17 100644 --- a/package.json +++ b/package.json @@ -34,7 +34,7 @@ "@babel/preset-env": "7.28.0", "@babel/preset-react": "7.27.1", "@babel/preset-typescript": "7.27.1", - "@currents/playwright": "1.15.2", + "@currents/playwright": "1.15.3", "@eslint/js": "9.31.0", "@patternfly/react-icons": "6.3.0", "@playwright/test": "1.51.1", From acc79e149c3e236d28e391b0a448ec91e9efa64f Mon Sep 17 00:00:00 2001 From: Michal Gold <mgold@redhat.com> Date: Sun, 3 Aug 2025 12:34:01 +0300 Subject: [PATCH 057/123] Wizard: Add FIPS state management infrastructure - Add fips field to wizardState type with enabled boolean property - Add fips configuration to initialState with default value false - Add selectFips selector to access FIPS state from store - Add changeFips reducer action to update FIPS enabled state This provides the Redux state management foundation for FIPS mode configuration. UI components and wizard steps will be added separately. --- .../utilities/requestMapper.ts | 18 +++++++++++++++++- src/store/wizardSlice.ts | 14 ++++++++++++++ 2 files changed, 31 insertions(+), 1 deletion(-) diff --git a/src/Components/CreateImageWizard/utilities/requestMapper.ts b/src/Components/CreateImageWizard/utilities/requestMapper.ts index 9ae2c772..ec165c69 100644 --- a/src/Components/CreateImageWizard/utilities/requestMapper.ts +++ b/src/Components/CreateImageWizard/utilities/requestMapper.ts @@ -70,6 +70,7 @@ import { selectCustomRepositories, selectDistribution, selectFileSystemConfigurationType, + selectFips, selectFirewall, selectFirstBootScript, selectGcpAccountType, @@ -364,6 +365,9 @@ function commonRequestToState( disabled: request.customizations.firewall?.services?.disabled || [], }, }, + fips: { + enabled: request.customizations.fips?.enabled || false, + }, }; } @@ -631,7 +635,7 @@ const getCustomizations = (state: RootState, orgID: string): Customizations => { fdo: undefined, ignition: undefined, partitioning_mode: undefined, - fips: undefined, + fips: getFips(state), cacerts: satCert && selectRegistrationType(state) === 'register-satellite' ? { @@ -869,6 +873,18 @@ const getPayloadRepositories = (state: RootState) => { return payloadAndRecommendedRepositories; }; +const getFips = (state: RootState) => { + const fips = selectFips(state); + + if (!fips.enabled) { + return undefined; + } + + return { + enabled: fips.enabled, + }; +}; + const getKernel = (state: RootState) => { const kernel = selectKernel(state); const kernelAppendString = selectKernel(state).append.join(' '); diff --git a/src/store/wizardSlice.ts b/src/store/wizardSlice.ts index 9f1b7733..36d9af71 100644 --- a/src/store/wizardSlice.ts +++ b/src/store/wizardSlice.ts @@ -170,6 +170,9 @@ export type wizardState = { disabled: string[]; }; }; + fips: { + enabled: boolean; + }; metadata?: { parent_id: string | null; exported_at: string; @@ -270,6 +273,9 @@ export const initialState: wizardState = { disabled: [], }, }, + fips: { + enabled: false, + }, firstBoot: { script: '' }, users: [], }; @@ -494,6 +500,10 @@ export const selectFirewall = (state: RootState) => { return state.wizard.firewall; }; +export const selectFips = (state: RootState) => { + return state.wizard.fips; +}; + export const wizardSlice = createSlice({ name: 'wizard', initialState, @@ -1131,6 +1141,9 @@ export const wizardSlice = createSlice({ state.users[action.payload.index].groups.splice(groupIndex, 1); } }, + changeFips: (state, action: PayloadAction<boolean>) => { + state.fips.enabled = action.payload; + }, }, }); @@ -1231,5 +1244,6 @@ export const { addUserGroupByIndex, removeUserGroupByIndex, changeRedHatRepositories, + changeFips, } = wizardSlice.actions; export default wizardSlice.reducer; From 4f250ee63710ef65853695fdf650b8df6df1059a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Aug 2025 06:47:49 +0000 Subject: [PATCH 058/123] build(deps-dev): bump stylelint from 16.22.0 to 16.23.0 Bumps [stylelint](https://github.com/stylelint/stylelint) from 16.22.0 to 16.23.0. - [Release notes](https://github.com/stylelint/stylelint/releases) - [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md) - [Commits](https://github.com/stylelint/stylelint/compare/16.22.0...16.23.0) --- updated-dependencies: - dependency-name: stylelint dependency-version: 16.23.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 124 ++++++++++++++++++++++------------------------ package.json | 2 +- 2 files changed, 60 insertions(+), 66 deletions(-) diff --git a/package-lock.json b/package-lock.json index bac37997..165c5b51 100644 --- a/package-lock.json +++ b/package-lock.json @@ -89,7 +89,7 @@ "redux-mock-store": "1.5.5", "sass": "1.89.2", "sass-loader": "16.0.5", - "stylelint": "16.22.0", + "stylelint": "16.23.0", "stylelint-config-recommended-scss": "15.0.1", "ts-node": "10.9.2", "ts-patch": "3.3.0", @@ -3498,14 +3498,11 @@ } }, "node_modules/@keyv/serialize": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@keyv/serialize/-/serialize-1.0.3.tgz", - "integrity": "sha512-qnEovoOp5Np2JDGonIDL6Ayihw0RhnRh6vxPuHo4RDn1UOzwEo4AeIfpL6UGIrsceWrCMiVPgwRjbHu4vYFc3g==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@keyv/serialize/-/serialize-1.1.0.tgz", + "integrity": "sha512-RlDgexML7Z63Q8BSaqhXdCYNBy/JQnqYIwxofUrNLGCblOMHp+xux2Q8nLMLlPpgHQPoU0Do8Z6btCpRBEqZ8g==", "dev": true, - "license": "MIT", - "dependencies": { - "buffer": "^6.0.3" - } + "license": "MIT" }, "node_modules/@kurkle/color": { "version": "0.3.2", @@ -7447,24 +7444,24 @@ } }, "node_modules/cacheable": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.10.0.tgz", - "integrity": "sha512-SSgQTAnhd7WlJXnGlIi4jJJOiHzgnM5wRMEPaXAU4kECTAMpBoYKoZ9i5zHmclIEZbxcu3j7yY/CF8DTmwIsHg==", + "version": "1.10.3", + "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.10.3.tgz", + "integrity": "sha512-M6p10iJ/VT0wT7TLIGUnm958oVrU2cUK8pQAVU21Zu7h8rbk/PeRtRWrvHJBql97Bhzk3g1N6+2VKC+Rjxna9Q==", "dev": true, "license": "MIT", "dependencies": { - "hookified": "^1.8.2", - "keyv": "^5.3.3" + "hookified": "^1.10.0", + "keyv": "^5.4.0" } }, "node_modules/cacheable/node_modules/keyv": { - "version": "5.3.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.3.4.tgz", - "integrity": "sha512-ypEvQvInNpUe+u+w8BIcPkQvEqXquyyibWE/1NB5T2BTzIpS5cGEV1LZskDzPSTvNAaT4+5FutvzlvnkxOSKlw==", + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.5.0.tgz", + "integrity": "sha512-QG7qR2tijh1ftOvClut4YKKg1iW6cx3GZsKoGyJPxHkGWK9oJhG9P3j5deP0QQOGDowBMVQFaP+Vm4NpGYvmIQ==", "dev": true, "license": "MIT", "dependencies": { - "@keyv/serialize": "^1.0.3" + "@keyv/serialize": "^1.1.0" } }, "node_modules/call-bind": { @@ -11305,9 +11302,9 @@ } }, "node_modules/hookified": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.10.0.tgz", - "integrity": "sha512-dJw0492Iddsj56U1JsSTm9E/0B/29a1AuoSLRAte8vQg/kaTGF3IgjEWT8c8yG4cC10+HisE1x5QAwR0Xwc+DA==", + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.11.0.tgz", + "integrity": "sha512-aDdIN3GyU5I6wextPplYdfmWCo+aLmjjVbntmX6HLD5RCi/xKsivYEBhnRD+d9224zFf008ZpLMPlWF0ZodYZw==", "dev": true, "license": "MIT" }, @@ -17566,9 +17563,9 @@ "license": "MIT" }, "node_modules/stylelint": { - "version": "16.22.0", - "resolved": "https://registry.npmjs.org/stylelint/-/stylelint-16.22.0.tgz", - "integrity": "sha512-SVEMTdjKNV4ollUrIY9ordZ36zHv2/PHzPjfPMau370MlL2VYXeLgSNMMiEbLGRO8RmD2R8/BVUeF2DfnfkC0w==", + "version": "16.23.0", + "resolved": "https://registry.npmjs.org/stylelint/-/stylelint-16.23.0.tgz", + "integrity": "sha512-69T5aS2LUY306ekt1Q1oaSPwz/jaG9HjyMix3UMrai1iEbuOafBe2Dh8xlyczrxFAy89qcKyZWWtc42XLx3Bbw==", "dev": true, "funding": [ { @@ -17595,7 +17592,7 @@ "debug": "^4.4.1", "fast-glob": "^3.3.3", "fastest-levenshtein": "^1.0.16", - "file-entry-cache": "^10.1.1", + "file-entry-cache": "^10.1.3", "global-modules": "^2.0.0", "globby": "^11.1.0", "globjoin": "^0.1.4", @@ -17743,25 +17740,25 @@ } }, "node_modules/stylelint/node_modules/file-entry-cache": { - "version": "10.1.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-10.1.1.tgz", - "integrity": "sha512-zcmsHjg2B2zjuBgjdnB+9q0+cWcgWfykIcsDkWDB4GTPtl1eXUA+gTI6sO0u01AqK3cliHryTU55/b2Ow1hfZg==", + "version": "10.1.3", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-10.1.3.tgz", + "integrity": "sha512-D+w75Ub8T55yor7fPgN06rkCAUbAYw2vpxJmmjv/GDAcvCnv9g7IvHhIZoxzRZThrXPFI2maeY24pPbtyYU7Lg==", "dev": true, "license": "MIT", "dependencies": { - "flat-cache": "^6.1.10" + "flat-cache": "^6.1.12" } }, "node_modules/stylelint/node_modules/flat-cache": { - "version": "6.1.10", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.10.tgz", - "integrity": "sha512-B6/v1f0NwjxzmeOhzfXPGWpKBVA207LS7lehaVKQnFrVktcFRfkzjZZ2gwj2i1TkEUMQht7ZMJbABUT5N+V1Nw==", + "version": "6.1.12", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.12.tgz", + "integrity": "sha512-U+HqqpZPPXP5d24bWuRzjGqVqUcw64k4nZAbruniDwdRg0H10tvN7H6ku1tjhA4rg5B9GS3siEvwO2qjJJ6f8Q==", "dev": true, "license": "MIT", "dependencies": { - "cacheable": "^1.10.0", + "cacheable": "^1.10.3", "flatted": "^3.3.3", - "hookified": "^1.9.1" + "hookified": "^1.10.0" } }, "node_modules/stylelint/node_modules/ignore": { @@ -22093,13 +22090,10 @@ "requires": {} }, "@keyv/serialize": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@keyv/serialize/-/serialize-1.0.3.tgz", - "integrity": "sha512-qnEovoOp5Np2JDGonIDL6Ayihw0RhnRh6vxPuHo4RDn1UOzwEo4AeIfpL6UGIrsceWrCMiVPgwRjbHu4vYFc3g==", - "dev": true, - "requires": { - "buffer": "^6.0.3" - } + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@keyv/serialize/-/serialize-1.1.0.tgz", + "integrity": "sha512-RlDgexML7Z63Q8BSaqhXdCYNBy/JQnqYIwxofUrNLGCblOMHp+xux2Q8nLMLlPpgHQPoU0Do8Z6btCpRBEqZ8g==", + "dev": true }, "@kurkle/color": { "version": "0.3.2", @@ -24621,22 +24615,22 @@ "dev": true }, "cacheable": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.10.0.tgz", - "integrity": "sha512-SSgQTAnhd7WlJXnGlIi4jJJOiHzgnM5wRMEPaXAU4kECTAMpBoYKoZ9i5zHmclIEZbxcu3j7yY/CF8DTmwIsHg==", + "version": "1.10.3", + "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-1.10.3.tgz", + "integrity": "sha512-M6p10iJ/VT0wT7TLIGUnm958oVrU2cUK8pQAVU21Zu7h8rbk/PeRtRWrvHJBql97Bhzk3g1N6+2VKC+Rjxna9Q==", "dev": true, "requires": { - "hookified": "^1.8.2", - "keyv": "^5.3.3" + "hookified": "^1.10.0", + "keyv": "^5.4.0" }, "dependencies": { "keyv": { - "version": "5.3.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.3.4.tgz", - "integrity": "sha512-ypEvQvInNpUe+u+w8BIcPkQvEqXquyyibWE/1NB5T2BTzIpS5cGEV1LZskDzPSTvNAaT4+5FutvzlvnkxOSKlw==", + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.5.0.tgz", + "integrity": "sha512-QG7qR2tijh1ftOvClut4YKKg1iW6cx3GZsKoGyJPxHkGWK9oJhG9P3j5deP0QQOGDowBMVQFaP+Vm4NpGYvmIQ==", "dev": true, "requires": { - "@keyv/serialize": "^1.0.3" + "@keyv/serialize": "^1.1.0" } } } @@ -27098,9 +27092,9 @@ } }, "hookified": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.10.0.tgz", - "integrity": "sha512-dJw0492Iddsj56U1JsSTm9E/0B/29a1AuoSLRAte8vQg/kaTGF3IgjEWT8c8yG4cC10+HisE1x5QAwR0Xwc+DA==", + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.11.0.tgz", + "integrity": "sha512-aDdIN3GyU5I6wextPplYdfmWCo+aLmjjVbntmX6HLD5RCi/xKsivYEBhnRD+d9224zFf008ZpLMPlWF0ZodYZw==", "dev": true }, "hosted-git-info": { @@ -31073,9 +31067,9 @@ } }, "stylelint": { - "version": "16.22.0", - "resolved": "https://registry.npmjs.org/stylelint/-/stylelint-16.22.0.tgz", - "integrity": "sha512-SVEMTdjKNV4ollUrIY9ordZ36zHv2/PHzPjfPMau370MlL2VYXeLgSNMMiEbLGRO8RmD2R8/BVUeF2DfnfkC0w==", + "version": "16.23.0", + "resolved": "https://registry.npmjs.org/stylelint/-/stylelint-16.23.0.tgz", + "integrity": "sha512-69T5aS2LUY306ekt1Q1oaSPwz/jaG9HjyMix3UMrai1iEbuOafBe2Dh8xlyczrxFAy89qcKyZWWtc42XLx3Bbw==", "dev": true, "requires": { "@csstools/css-parser-algorithms": "^3.0.5", @@ -31091,7 +31085,7 @@ "debug": "^4.4.1", "fast-glob": "^3.3.3", "fastest-levenshtein": "^1.0.16", - "file-entry-cache": "^10.1.1", + "file-entry-cache": "^10.1.3", "global-modules": "^2.0.0", "globby": "^11.1.0", "globjoin": "^0.1.4", @@ -31133,23 +31127,23 @@ } }, "file-entry-cache": { - "version": "10.1.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-10.1.1.tgz", - "integrity": "sha512-zcmsHjg2B2zjuBgjdnB+9q0+cWcgWfykIcsDkWDB4GTPtl1eXUA+gTI6sO0u01AqK3cliHryTU55/b2Ow1hfZg==", + "version": "10.1.3", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-10.1.3.tgz", + "integrity": "sha512-D+w75Ub8T55yor7fPgN06rkCAUbAYw2vpxJmmjv/GDAcvCnv9g7IvHhIZoxzRZThrXPFI2maeY24pPbtyYU7Lg==", "dev": true, "requires": { - "flat-cache": "^6.1.10" + "flat-cache": "^6.1.12" } }, "flat-cache": { - "version": "6.1.10", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.10.tgz", - "integrity": "sha512-B6/v1f0NwjxzmeOhzfXPGWpKBVA207LS7lehaVKQnFrVktcFRfkzjZZ2gwj2i1TkEUMQht7ZMJbABUT5N+V1Nw==", + "version": "6.1.12", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.12.tgz", + "integrity": "sha512-U+HqqpZPPXP5d24bWuRzjGqVqUcw64k4nZAbruniDwdRg0H10tvN7H6ku1tjhA4rg5B9GS3siEvwO2qjJJ6f8Q==", "dev": true, "requires": { - "cacheable": "^1.10.0", + "cacheable": "^1.10.3", "flatted": "^3.3.3", - "hookified": "^1.9.1" + "hookified": "^1.10.0" } }, "ignore": { diff --git a/package.json b/package.json index 71cc6d17..dc9508a1 100644 --- a/package.json +++ b/package.json @@ -87,7 +87,7 @@ "redux-mock-store": "1.5.5", "sass": "1.89.2", "sass-loader": "16.0.5", - "stylelint": "16.22.0", + "stylelint": "16.23.0", "stylelint-config-recommended-scss": "15.0.1", "ts-node": "10.9.2", "ts-patch": "3.3.0", From 88dd0880c82a8553db06164a69be0c6fdb587b2d Mon Sep 17 00:00:00 2001 From: Michal Gold <mgold@redhat.com> Date: Thu, 31 Jul 2025 17:14:14 +0300 Subject: [PATCH 059/123] Wizard: Add tooltip explaining password visibility in edit mode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When editing a blueprint, password fields show an eye icon that appears clickable but is actually disabled for security reasons (passwords cannot be retrieved from the backend). This creates confusing UX where users expect the icon to work but it doesn't respond. This change adds a tooltip that appears when hovering over the disabled eye button, explaining that "Passwords cannot be viewed when editing a blueprint for security reasons." The fix wraps the disabled button in a span element to ensure the tooltip triggers properly, as disabled buttons don't receive mouse events. Also adds unit test to verify the tooltip functionality Fixes #3303 🤖 Generated with AI --- .../utilities/PasswordValidatedInput.tsx | 33 ++++++++++++++----- .../steps/Users/Users.test.tsx | 26 +++++++++++++++ src/test/fixtures/editMode.ts | 2 +- 3 files changed, 52 insertions(+), 9 deletions(-) diff --git a/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx b/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx index 6cc85c7e..972902d7 100644 --- a/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx +++ b/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx @@ -10,6 +10,7 @@ import { InputGroupItem, TextInput, TextInputProps, + Tooltip, } from '@patternfly/react-core'; import { EyeIcon, EyeSlashIcon } from '@patternfly/react-icons'; @@ -46,6 +47,21 @@ export const PasswordValidatedInput = ({ setIsPasswordVisible(!isPasswordVisible); }; + const isEditingWithoutValue = hasPassword && !value; + + const PasswordToggleButton = () => { + return ( + <Button + variant="control" + onClick={togglePasswordVisibility} + aria-label={isPasswordVisible ? 'Hide password' : 'Show password'} + isDisabled={isEditingWithoutValue} + > + {isPasswordVisible ? <EyeSlashIcon /> : <EyeIcon />} + </Button> + ); + }; + return ( <FormGroup label="Password" className="pf-v6-u-pb-md"> <> @@ -61,14 +77,15 @@ export const PasswordValidatedInput = ({ /> </InputGroupItem> <InputGroupItem> - <Button - variant="control" - onClick={togglePasswordVisibility} - aria-label={isPasswordVisible ? 'Hide password' : 'Show password'} - isDisabled={hasPassword && !value} - > - {isPasswordVisible ? <EyeSlashIcon /> : <EyeIcon />} - </Button> + {isEditingWithoutValue ? ( + <Tooltip content="Passwords cannot be viewed when editing a blueprint for security reasons"> + <span> + <PasswordToggleButton/> + </span> + </Tooltip> + ) : ( + <PasswordToggleButton/> + )} </InputGroupItem> </InputGroup> </> diff --git a/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx b/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx index ad0ddf97..e0704deb 100644 --- a/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx @@ -506,4 +506,30 @@ describe('Users edit mode', () => { const expectedRequest = usersCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); }); + + test('shows tooltip on disabled password eye icon when editing blueprint with existing password', async () => { + const user = userEvent.setup(); + const id = mockBlueprintIds['users']; + await renderEditMode(id); + + const usersNavButtons = await screen.findAllByRole('button', { name: /Users/ }); + await waitFor(() => user.click(usersNavButtons[0])); + + const passwordToggleButton = await screen.findByRole('button', { + name: 'Show password' + }); + + expect(passwordToggleButton).toBeDisabled(); + + await waitFor(() => user.hover(passwordToggleButton)); + + const tooltip = await screen.findByText('Passwords cannot be viewed when editing a blueprint for security reasons'); + expect(tooltip).toBeInTheDocument(); + + await waitFor(() => user.unhover(passwordToggleButton)); + + await waitFor(() => { + expect(screen.queryByText('Passwords cannot be viewed when editing a blueprint for security reasons')).not.toBeInTheDocument(); + }); + }); }); diff --git a/src/test/fixtures/editMode.ts b/src/test/fixtures/editMode.ts index 0934015e..5e00ede2 100644 --- a/src/test/fixtures/editMode.ts +++ b/src/test/fixtures/editMode.ts @@ -502,7 +502,7 @@ export const usersCreateBlueprintRequest: CreateBlueprintRequest = { name: 'best', ssh_key: 'ssh-rsa d', groups: ['wheel'], - hasPassword: false, + hasPassword: true, }, ], }, From 7269b0c7dbc2b75754d0a4e7199e91bd9268825c Mon Sep 17 00:00:00 2001 From: "red-hat-konflux[bot]" <126015336+red-hat-konflux[bot]@users.noreply.github.com> Date: Tue, 5 Aug 2025 06:03:54 +0000 Subject: [PATCH 060/123] chore(deps): update build-tools digest to b496d0a Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com> --- build-tools | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-tools b/build-tools index 37ab5d09..b496d0a8 160000 --- a/build-tools +++ b/build-tools @@ -1 +1 @@ -Subproject commit 37ab5d095e703e5d34e3f02f1040ab5b002d56fe +Subproject commit b496d0a8c1755608bd256a6960869b14a7689d38 From 35c9f32cf83c9917fc31e34cc87f5200398a2c60 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Aug 2025 10:46:36 +0000 Subject: [PATCH 061/123] build(deps-dev): bump @eslint/js from 9.31.0 to 9.32.0 Bumps [@eslint/js](https://github.com/eslint/eslint/tree/HEAD/packages/js) from 9.31.0 to 9.32.0. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/commits/v9.32.0/packages/js) --- updated-dependencies: - dependency-name: "@eslint/js" dependency-version: 9.32.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 33 +++++++-------------------------- package.json | 2 +- 2 files changed, 8 insertions(+), 27 deletions(-) diff --git a/package-lock.json b/package-lock.json index 165c5b51..1ddc27e4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -37,7 +37,7 @@ "@babel/preset-react": "7.27.1", "@babel/preset-typescript": "7.27.1", "@currents/playwright": "1.15.3", - "@eslint/js": "9.31.0", + "@eslint/js": "9.32.0", "@patternfly/react-icons": "6.3.0", "@playwright/test": "1.51.1", "@redhat-cloud-services/eslint-config-redhat-cloud-services": "3.0.0", @@ -3123,9 +3123,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.31.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.31.0.tgz", - "integrity": "sha512-LOm5OVt7D4qiKCqoiPbA7LWmI+tbw1VbTUowBcUMgQSuM6poJufkFkYDcQpo5KfgD39TnNySV26QjOh7VFpSyw==", + "version": "9.32.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.32.0.tgz", + "integrity": "sha512-BBpRFZK3eX6uMLKz8WxFOBIFFcGFJ/g8XuwjTHCqHROSIsopI+ddn/d5Cfh36+7+e5edVS8dbSHnBNhrLEX0zg==", "dev": true, "license": "MIT", "engines": { @@ -9913,19 +9913,6 @@ "node": ">=10" } }, - "node_modules/eslint/node_modules/@eslint/js": { - "version": "9.32.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.32.0.tgz", - "integrity": "sha512-BBpRFZK3eX6uMLKz8WxFOBIFFcGFJ/g8XuwjTHCqHROSIsopI+ddn/d5Cfh36+7+e5edVS8dbSHnBNhrLEX0zg==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "url": "https://eslint.org/donate" - } - }, "node_modules/eslint/node_modules/ajv": { "version": "6.12.6", "dev": true, @@ -21871,9 +21858,9 @@ } }, "@eslint/js": { - "version": "9.31.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.31.0.tgz", - "integrity": "sha512-LOm5OVt7D4qiKCqoiPbA7LWmI+tbw1VbTUowBcUMgQSuM6poJufkFkYDcQpo5KfgD39TnNySV26QjOh7VFpSyw==", + "version": "9.32.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.32.0.tgz", + "integrity": "sha512-BBpRFZK3eX6uMLKz8WxFOBIFFcGFJ/g8XuwjTHCqHROSIsopI+ddn/d5Cfh36+7+e5edVS8dbSHnBNhrLEX0zg==", "dev": true }, "@eslint/object-schema": { @@ -25876,12 +25863,6 @@ "optionator": "^0.9.3" }, "dependencies": { - "@eslint/js": { - "version": "9.32.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.32.0.tgz", - "integrity": "sha512-BBpRFZK3eX6uMLKz8WxFOBIFFcGFJ/g8XuwjTHCqHROSIsopI+ddn/d5Cfh36+7+e5edVS8dbSHnBNhrLEX0zg==", - "dev": true - }, "ajv": { "version": "6.12.6", "dev": true, diff --git a/package.json b/package.json index dc9508a1..7b8904ab 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ "@babel/preset-react": "7.27.1", "@babel/preset-typescript": "7.27.1", "@currents/playwright": "1.15.3", - "@eslint/js": "9.31.0", + "@eslint/js": "9.32.0", "@patternfly/react-icons": "6.3.0", "@playwright/test": "1.51.1", "@redhat-cloud-services/eslint-config-redhat-cloud-services": "3.0.0", From 68b2f74a97db8fee843bf598670c295053c9d823 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Aug 2025 10:55:49 +0000 Subject: [PATCH 062/123] build(deps): bump @redhat-cloud-services/frontend-components-notifications Bumps [@redhat-cloud-services/frontend-components-notifications](https://github.com/RedHatInsights/frontend-components) from 6.1.1 to 6.1.3. - [Release notes](https://github.com/RedHatInsights/frontend-components/releases) - [Changelog](https://github.com/RedHatInsights/frontend-components/blob/master/CHANGELOG.md) - [Commits](https://github.com/RedHatInsights/frontend-components/compare/@redhat-cloud-services/frontend-components-notifications-6.1.1...@redhat-cloud-services/frontend-components-notifications-6.1.3) --- updated-dependencies: - dependency-name: "@redhat-cloud-services/frontend-components-notifications" dependency-version: 6.1.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> --- package-lock.json | 14 +++++++------- package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1ddc27e4..539309e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,7 +15,7 @@ "@patternfly/react-core": "6.3.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", - "@redhat-cloud-services/frontend-components-notifications": "6.1.1", + "@redhat-cloud-services/frontend-components-notifications": "6.1.3", "@redhat-cloud-services/frontend-components-utilities": "6.1.1", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", @@ -4150,9 +4150,9 @@ } }, "node_modules/@redhat-cloud-services/frontend-components-notifications": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.1.tgz", - "integrity": "sha512-pP0KCFdWnOoVO2IWwcqKv+MOJvoZCWX9wxS+ejdvGzaTbu2CZb+w6E1hCL9O7MWdWatUSxtdOWtpbTsbPKt3nw==", + "version": "6.1.3", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.3.tgz", + "integrity": "sha512-GeLVfH+e6M8CLehk4U3LVoUzQ7G2pyw3SY6I8R/WBaYfBuwqBhWRHiHt/bTE+VzZo5yfBsnbKQ59JWNpYniDvA==", "license": "Apache-2.0", "dependencies": { "@redhat-cloud-services/frontend-components": "^6.0.0", @@ -22490,9 +22490,9 @@ } }, "@redhat-cloud-services/frontend-components-notifications": { - "version": "6.1.1", - "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.1.tgz", - "integrity": "sha512-pP0KCFdWnOoVO2IWwcqKv+MOJvoZCWX9wxS+ejdvGzaTbu2CZb+w6E1hCL9O7MWdWatUSxtdOWtpbTsbPKt3nw==", + "version": "6.1.3", + "resolved": "https://registry.npmjs.org/@redhat-cloud-services/frontend-components-notifications/-/frontend-components-notifications-6.1.3.tgz", + "integrity": "sha512-GeLVfH+e6M8CLehk4U3LVoUzQ7G2pyw3SY6I8R/WBaYfBuwqBhWRHiHt/bTE+VzZo5yfBsnbKQ59JWNpYniDvA==", "requires": { "@redhat-cloud-services/frontend-components": "^6.0.0", "@redhat-cloud-services/frontend-components-utilities": "^6.0.0" diff --git a/package.json b/package.json index 7b8904ab..ad53eed3 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "@patternfly/react-core": "6.3.0", "@patternfly/react-table": "6.3.0", "@redhat-cloud-services/frontend-components": "6.1.1", - "@redhat-cloud-services/frontend-components-notifications": "6.1.1", + "@redhat-cloud-services/frontend-components-notifications": "6.1.3", "@redhat-cloud-services/frontend-components-utilities": "6.1.1", "@reduxjs/toolkit": "2.8.2", "@scalprum/react-core": "0.9.5", From 894d2a4d76dec8aa4023ef1107cea2d3e0d36324 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 5 Aug 2025 13:26:08 +0200 Subject: [PATCH 063/123] Wizard: Fix registration validation for Satellite on edit When editing a blueprint with Satellite registration the "Save changes" button was disabled due to registration validation failing with "No activation key selected". Activation key is not required for Satellite. --- .../CreateImageWizard/utilities/useValidation.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Components/CreateImageWizard/utilities/useValidation.tsx b/src/Components/CreateImageWizard/utilities/useValidation.tsx index a5b49803..ced08bcf 100644 --- a/src/Components/CreateImageWizard/utilities/useValidation.tsx +++ b/src/Components/CreateImageWizard/utilities/useValidation.tsx @@ -130,7 +130,11 @@ export function useRegistrationValidation(): StepValidation { } ); - if (registrationType !== 'register-later' && !activationKey) { + if ( + registrationType !== 'register-later' && + registrationType !== 'register-satellite' && + !activationKey + ) { return { errors: { activationKey: 'No activation key selected' }, disabledNext: true, @@ -139,6 +143,7 @@ export function useRegistrationValidation(): StepValidation { if ( registrationType !== 'register-later' && + registrationType !== 'register-satellite' && activationKey && (isFetchingKeyInfo || isErrorKeyInfo) ) { From 2bea0bd50beb580a795b3d23274b3b3e4b8bde75 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 5 Aug 2025 14:03:05 +0200 Subject: [PATCH 064/123] Wizard: Update kernel argument validation regex There are special characters missing from the validation regex. --- playwright/Customizations/Kernel.spec.ts | 2 +- src/Components/CreateImageWizard/validators.ts | 2 +- src/test/Components/Blueprints/ImportBlueprintModal.test.tsx | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/playwright/Customizations/Kernel.spec.ts b/playwright/Customizations/Kernel.spec.ts index c385cbe1..881459d9 100644 --- a/playwright/Customizations/Kernel.spec.ts +++ b/playwright/Customizations/Kernel.spec.ts @@ -47,7 +47,7 @@ test('Create a blueprint with Kernel customization', async ({ await frame.getByRole('button', { name: 'Add kernel argument' }).click(); await frame .getByPlaceholder('Add kernel argument') - .fill('invalid/argument'); + .fill('invalid$argument'); await frame.getByRole('button', { name: 'Add kernel argument' }).click(); await expect( frame.getByText( diff --git a/src/Components/CreateImageWizard/validators.ts b/src/Components/CreateImageWizard/validators.ts index 59b93ce7..35838256 100644 --- a/src/Components/CreateImageWizard/validators.ts +++ b/src/Components/CreateImageWizard/validators.ts @@ -122,7 +122,7 @@ export const isKernelNameValid = (kernelName: string) => { }; export const isKernelArgumentValid = (arg: string) => { - return /^[a-zA-Z0-9=-_,."']*$/.test(arg); + return /^[a-zA-Z0-9=\-_,."'/:#+]*$/.test(arg); }; export const isPortValid = (port: string) => { diff --git a/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx b/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx index 709f32ae..88200855 100644 --- a/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx +++ b/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx @@ -262,7 +262,7 @@ keyboard = "invalid-keyboard" [customizations.kernel] name = "--invalid-kernel-name--" -append = "invalid-kernel-argument" +append = "invalid$kernel$argument" [customizations.firewall] ports = ["invalid-port"] @@ -640,7 +640,7 @@ describe('Import modal', () => { ); await waitFor(() => user.click( - screen.getByRole('button', { name: /close invalid-kernel-argument/i }) + screen.getByRole('button', { name: /close invalid\$kernel\$argument/i }) ) ); From 4c098db796ec6811efd4c697d53ad70b32a5fedf Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 5 Aug 2025 10:45:16 +0200 Subject: [PATCH 065/123] Move prettier config to ESLint config ESLint was not enforcing prettier rules defined in `.prettierrc`, this plugs prettier in and moves the rules to ESLint config so all lint settings are in one place. --- .prettierrc | 9 --------- eslint.config.js | 19 ++++++++++++++++--- package-lock.json | 25 +++++++++++++------------ package.json | 1 + 4 files changed, 30 insertions(+), 24 deletions(-) delete mode 100644 .prettierrc diff --git a/.prettierrc b/.prettierrc deleted file mode 100644 index 258449ff..00000000 --- a/.prettierrc +++ /dev/null @@ -1,9 +0,0 @@ -{ - "semi": true, - "tabWidth": 2, - "singleQuote": false, - "jsxSingleQuote": false, - "bracketSpacing": true, - "tsxSingleQuote": true, - "tsSingleQuote": true -} \ No newline at end of file diff --git a/eslint.config.js b/eslint.config.js index 0c4750c1..39da3786 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -7,6 +7,7 @@ const pluginImport = require('eslint-plugin-import'); const fecConfig = require('@redhat-cloud-services/eslint-config-redhat-cloud-services'); const pluginJsxA11y = require('eslint-plugin-jsx-a11y'); const disableAutofix = require('eslint-plugin-disable-autofix'); +const pluginPrettier = require('eslint-plugin-prettier'); const jestDom = require('eslint-plugin-jest-dom'); const pluginTestingLibrary = require('eslint-plugin-testing-library'); const pluginPlaywright = require('eslint-plugin-playwright'); @@ -61,6 +62,7 @@ module.exports = defineConfig([ import: pluginImport, jsxA11y: pluginJsxA11y, 'disable-autofix': disableAutofix, + prettier: pluginPrettier, }, rules: { ...js.configs.recommended.rules, @@ -118,6 +120,17 @@ module.exports = defineConfig([ }, ], 'jsx-a11y/no-autofocus': 'off', + 'prettier/prettier': ['error', { + semi: true, + tabWidth: 2, + singleQuote: true, + jsxSingleQuote: false, + bracketSpacing: true, + tsxSingleQuote: true, + tsSingleQuote: true, + printWidth: 80, + trailingComma: 'es5', + }], }, settings: { react: { @@ -150,10 +163,10 @@ module.exports = defineConfig([ ...pluginPlaywright.configs.recommended.rules, 'playwright/no-conditional-in-test': 'off', 'playwright/no-conditional-expect': 'off', - "playwright/no-skipped-test": [ - "error", + 'playwright/no-skipped-test': [ + 'error', { - "allowConditional": true + 'allowConditional': true } ] }, diff --git a/package-lock.json b/package-lock.json index 539309e7..8f017617 100644 --- a/package-lock.json +++ b/package-lock.json @@ -69,6 +69,7 @@ "eslint-plugin-jest-dom": "5.5.0", "eslint-plugin-jsx-a11y": "6.10.2", "eslint-plugin-playwright": "2.2.2", + "eslint-plugin-prettier": "5.5.3", "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", @@ -9434,9 +9435,9 @@ } }, "node_modules/eslint-config-prettier": { - "version": "10.1.5", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-10.1.5.tgz", - "integrity": "sha512-zc1UmCpNltmVY34vuLRV61r1K27sWuX39E+uyUnY8xS2Bex88VV9cugG+UZbRSRGtGyFboj+D8JODyme1plMpw==", + "version": "10.1.8", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-10.1.8.tgz", + "integrity": "sha512-82GZUjRS0p/jganf6q1rEO25VSoHH0hKPCTrgillPjdI/3bgBhAE1QzHrHTizjpRvy6pGAvKjDJtk2pF9NDq8w==", "dev": true, "license": "MIT", "bin": { @@ -9708,9 +9709,9 @@ } }, "node_modules/eslint-plugin-prettier": { - "version": "5.5.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.5.1.tgz", - "integrity": "sha512-dobTkHT6XaEVOo8IO90Q4DOSxnm3Y151QxPJlM/vKC0bVy+d6cVWQZLlFiuZPP0wS6vZwSKeJgKkcS+KfMBlRw==", + "version": "5.5.3", + "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.5.3.tgz", + "integrity": "sha512-NAdMYww51ehKfDyDhv59/eIItUVzU0Io9H2E8nHNGKEeeqlnci+1gCvrHib6EmZdf6GxF+LCV5K7UC65Ezvw7w==", "dev": true, "license": "MIT", "dependencies": { @@ -25913,9 +25914,9 @@ } }, "eslint-config-prettier": { - "version": "10.1.5", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-10.1.5.tgz", - "integrity": "sha512-zc1UmCpNltmVY34vuLRV61r1K27sWuX39E+uyUnY8xS2Bex88VV9cugG+UZbRSRGtGyFboj+D8JODyme1plMpw==", + "version": "10.1.8", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-10.1.8.tgz", + "integrity": "sha512-82GZUjRS0p/jganf6q1rEO25VSoHH0hKPCTrgillPjdI/3bgBhAE1QzHrHTizjpRvy6pGAvKjDJtk2pF9NDq8w==", "dev": true, "requires": {} }, @@ -26103,9 +26104,9 @@ } }, "eslint-plugin-prettier": { - "version": "5.5.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.5.1.tgz", - "integrity": "sha512-dobTkHT6XaEVOo8IO90Q4DOSxnm3Y151QxPJlM/vKC0bVy+d6cVWQZLlFiuZPP0wS6vZwSKeJgKkcS+KfMBlRw==", + "version": "5.5.3", + "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.5.3.tgz", + "integrity": "sha512-NAdMYww51ehKfDyDhv59/eIItUVzU0Io9H2E8nHNGKEeeqlnci+1gCvrHib6EmZdf6GxF+LCV5K7UC65Ezvw7w==", "dev": true, "requires": { "prettier-linter-helpers": "^1.0.0", diff --git a/package.json b/package.json index ad53eed3..1395b45c 100644 --- a/package.json +++ b/package.json @@ -67,6 +67,7 @@ "eslint-plugin-jest-dom": "5.5.0", "eslint-plugin-jsx-a11y": "6.10.2", "eslint-plugin-playwright": "2.2.2", + "eslint-plugin-prettier": "5.5.3", "eslint-plugin-react": "7.37.5", "eslint-plugin-react-hooks": "5.2.0", "eslint-plugin-react-redux": "4.2.2", From e9025e460cb42842d7e5a138948a2246136e5f65 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 5 Aug 2025 11:09:03 +0200 Subject: [PATCH 066/123] src: Run lint autofix --- playwright/test.spec.ts | 10 +++---- .../Blueprints/ImportBlueprintModal.tsx | 13 ++++---- .../CloudProviderConfig/AWSConfig.tsx | 2 +- .../CloudProviderConfig.tsx | 2 +- .../CreateImageWizard/CreateImageWizard.tsx | 8 ++--- .../CreateImageWizard/ValidatedInput.tsx | 4 +-- .../components/TargetEnvironment.tsx | 17 +++++++---- .../Oscap/components/ProfileSelector.tsx | 4 +-- .../steps/Packages/Packages.tsx | 20 ++++++------- .../components/SatelliteRegistration.tsx | 16 +++++----- .../steps/Review/ReviewStepTables.tsx | 4 +-- .../steps/Review/ReviewStepTextLists.tsx | 16 +++++----- .../TargetEnvironment/Aws/AwsAccountId.tsx | 2 +- .../steps/TargetEnvironment/Aws/index.tsx | 2 +- .../utilities/PasswordValidatedInput.tsx | 24 +++++++-------- .../utilities/requestMapper.ts | 30 +++++++++---------- src/Components/ImagesTable/Instance.tsx | 12 ++++---- src/Components/ImagesTable/Target.tsx | 5 +++- .../useMutationWithNotification.tsx | 2 +- src/store/listenerMiddleware.ts | 2 +- .../Blueprints/ImportBlueprintModal.test.tsx | 14 ++++----- .../steps/Details/Details.test.tsx | 5 ++-- .../steps/Firewall/Firewall.test.tsx | 15 ++++------ .../steps/FirstBoot/Firstboot.test.tsx | 5 ++-- .../steps/Hostname/Hostname.test.tsx | 5 ++-- .../steps/Locale/Locale.test.tsx | 15 ++++------ .../steps/Oscap/Compliance.test.tsx | 5 ++-- .../steps/Oscap/Oscap.test.tsx | 5 ++-- .../steps/Registration/Registration.test.tsx | 7 ++--- .../steps/Services/Services.test.tsx | 10 +++---- .../TargetEnvironment/AzureTarget.test.tsx | 6 +++- .../steps/Timezone/Timezone.test.tsx | 25 +++++++--------- .../steps/Users/Users.test.tsx | 26 +++++++++------- .../ImagesTable/ImagesTable.test.tsx | 5 ++-- src/test/setup.ts | 10 ++++--- 35 files changed, 177 insertions(+), 176 deletions(-) diff --git a/playwright/test.spec.ts b/playwright/test.spec.ts index 0f46028e..bdd02268 100644 --- a/playwright/test.spec.ts +++ b/playwright/test.spec.ts @@ -87,7 +87,7 @@ test.describe.serial('test', () => { await frame.getByRole('button', { name: 'Create blueprint' }).click(); await expect( - frame.locator('.pf-v6-c-card__title-text').getByText(blueprintName), + frame.locator('.pf-v6-c-card__title-text').getByText(blueprintName) ).toBeVisible(); }); @@ -205,7 +205,7 @@ test.describe.serial('test', () => { if (await switchInput.isChecked()) { await frame.getByRole('button', { name: 'Cancel' }).click(); await expect( - frame.getByRole('heading', { name: 'All images' }), + frame.getByRole('heading', { name: 'All images' }) ).toBeVisible(); } else { const switchToggle = frame.locator('.pf-v6-c-switch'); @@ -219,7 +219,7 @@ test.describe.serial('test', () => { await frame.getByPlaceholder('Path to AWS credentials').fill(credentials); await frame.getByRole('button', { name: 'Submit' }).click(); await expect( - frame.getByRole('heading', { name: 'All images' }), + frame.getByRole('heading', { name: 'All images' }) ).toBeVisible(); } @@ -236,7 +236,7 @@ test.describe.serial('test', () => { await expect(frame.getByPlaceholder('AWS bucket')).toHaveValue(bucket); await expect(frame.getByPlaceholder('Path to AWS credentials')).toHaveValue( - credentials, + credentials ); await frame.getByRole('button', { name: 'Cancel' }).click(); @@ -276,7 +276,7 @@ test.describe.serial('test', () => { frame.getByRole('heading', { name: 'Details' }); await frame.getByTestId('blueprint').fill(cockpitBlueprintname); await expect(frame.getByTestId('blueprint')).toHaveValue( - cockpitBlueprintname, + cockpitBlueprintname ); await frame.getByRole('button', { name: 'Next', exact: true }).click(); diff --git a/src/Components/Blueprints/ImportBlueprintModal.tsx b/src/Components/Blueprints/ImportBlueprintModal.tsx index 88ab60fb..9dfafeca 100644 --- a/src/Components/Blueprints/ImportBlueprintModal.tsx +++ b/src/Components/Blueprints/ImportBlueprintModal.tsx @@ -155,9 +155,8 @@ export const ImportBlueprintModal: React.FunctionComponent< blueprintFromFile.content_sources && blueprintFromFile.content_sources.length > 0 ) { - const imported = await handleRepositoryImport( - blueprintFromFile - ); + const imported = + await handleRepositoryImport(blueprintFromFile); customRepos = imported ?? []; } @@ -308,10 +307,10 @@ export const ImportBlueprintModal: React.FunctionComponent< {isRejected ? 'Must be a valid Blueprint JSON/TOML file no larger than 512 KB' : isInvalidFormat - ? 'Not compatible with the blueprints format.' - : isOnPrem - ? 'Importing on-premises blueprints is currently in beta. Results may vary.' - : 'Upload your blueprint file. Supported formats: JSON, TOML.'} + ? 'Not compatible with the blueprints format.' + : isOnPrem + ? 'Importing on-premises blueprints is currently in beta. Results may vary.' + : 'Upload your blueprint file. Supported formats: JSON, TOML.'} </HelperTextItem> </HelperText> </FormHelperText> diff --git a/src/Components/CloudProviderConfig/AWSConfig.tsx b/src/Components/CloudProviderConfig/AWSConfig.tsx index 4bd2404d..334021b7 100644 --- a/src/Components/CloudProviderConfig/AWSConfig.tsx +++ b/src/Components/CloudProviderConfig/AWSConfig.tsx @@ -38,7 +38,7 @@ type ToggleGroupProps = Omit<FormGroupProps<boolean>, 'isDisabled'>; const AWSConfigToggle = ({ value, onChange }: ToggleGroupProps) => { const handleChange = ( _event: React.FormEvent<HTMLInputElement>, - checked: boolean, + checked: boolean ) => { onChange(checked); }; diff --git a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx index ed5523a4..a8bfe3af 100644 --- a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx +++ b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx @@ -97,7 +97,7 @@ export const CloudProviderConfig = () => { dispatch(changeAWSCredsPath(credentials)); } }, - [dispatch, setEnabled], + [dispatch, setEnabled] ); useEffect(() => { diff --git a/src/Components/CreateImageWizard/CreateImageWizard.tsx b/src/Components/CreateImageWizard/CreateImageWizard.tsx index 3507693e..01f36f0b 100644 --- a/src/Components/CreateImageWizard/CreateImageWizard.tsx +++ b/src/Components/CreateImageWizard/CreateImageWizard.tsx @@ -442,10 +442,10 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { !isAzureSubscriptionIdValid(azureSubscriptionId) || !isAzureResourceGroupValid(azureResourceGroup) : azureShareMethod === 'sources' - ? !isAzureTenantGUIDValid(azureTenantId) || - !isAzureSubscriptionIdValid(azureSubscriptionId) || - !isAzureResourceGroupValid(azureResourceGroup) - : azureSource === undefined + ? !isAzureTenantGUIDValid(azureTenantId) || + !isAzureSubscriptionIdValid(azureSubscriptionId) || + !isAzureResourceGroupValid(azureResourceGroup) + : azureSource === undefined } /> } diff --git a/src/Components/CreateImageWizard/ValidatedInput.tsx b/src/Components/CreateImageWizard/ValidatedInput.tsx index 24f5fbfb..271898a9 100644 --- a/src/Components/CreateImageWizard/ValidatedInput.tsx +++ b/src/Components/CreateImageWizard/ValidatedInput.tsx @@ -116,8 +116,8 @@ const getValidationState = ( const validated = isPristine ? 'default' : (isRequired && errorMessage) || errorMessage - ? 'error' - : 'success'; + ? 'error' + : 'success'; return validated; }; diff --git a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx index 029f7678..2d98e3f7 100644 --- a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx +++ b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx @@ -142,8 +142,14 @@ const TargetEnvironment = () => { }; if (isFetching) { - return <EmptyState titleText="Loading target environments" headingLevel="h6" icon={Spinner} /> - }; + return ( + <EmptyState + titleText="Loading target environments" + headingLevel="h6" + icon={Spinner} + /> + ); + } if (isError) { return ( @@ -152,10 +158,11 @@ const TargetEnvironment = () => { variant="danger" isInline > - Target environments couldn't be loaded, please refresh the page or try again later. + Target environments couldn't be loaded, please refresh the page or + try again later. </Alert> - ) - }; + ); + } return ( <FormGroup diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index 64859ed5..7af83590 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -211,7 +211,7 @@ const ProfileSelector = () => { const onKeyDown = (event: React.KeyboardEvent) => { if (event.key === 'Enter') { event.preventDefault(); - + if (!isOpen) { setIsOpen(true); } else if (selectOptions.length === 1) { @@ -220,7 +220,7 @@ const ProfileSelector = () => { profileID: singleProfile.id, toString: () => singleProfile.name || '', }; - + setInputValue(singleProfile.name || ''); setFilterValue(''); applyChanges(selection); diff --git a/src/Components/CreateImageWizard/steps/Packages/Packages.tsx b/src/Components/CreateImageWizard/steps/Packages/Packages.tsx index 7c278c04..58e186fe 100644 --- a/src/Components/CreateImageWizard/steps/Packages/Packages.tsx +++ b/src/Components/CreateImageWizard/steps/Packages/Packages.tsx @@ -1485,8 +1485,8 @@ const Packages = () => { packages.length + groups.length === 0 ? '' : packages.length + groups.length <= 100 - ? ` (${packages.length + groups.length})` - : ' (100+)' + ? ` (${packages.length + groups.length})` + : ' (100+)' }`} buttonId="toggle-selected" isSelected={toggleSelected === 'toggle-selected'} @@ -1501,10 +1501,10 @@ const Packages = () => { searchTerm === '' && toggleSelected === 'toggle-available' ? 0 : showPackages && showGroups - ? transformedPackages.length + transformedGroups.length - : showPackages - ? transformedPackages.length - : transformedGroups.length + ? transformedPackages.length + transformedGroups.length + : showPackages + ? transformedPackages.length + : transformedGroups.length } perPage={perPage} page={page} @@ -1550,10 +1550,10 @@ const Packages = () => { searchTerm === '' && toggleSelected === 'toggle-available' ? 0 : showPackages && showGroups - ? transformedPackages.length + transformedGroups.length - : showPackages - ? transformedPackages.length - : transformedGroups.length + ? transformedPackages.length + transformedGroups.length + : showPackages + ? transformedPackages.length + : transformedGroups.length } perPage={perPage} page={page} diff --git a/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx b/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx index 5eb8a732..be224058 100644 --- a/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx @@ -26,8 +26,8 @@ const SatelliteRegistration = () => { const validated = stepValidation.errors['certificate'] ? 'error' : stepValidation.errors['certificate'] === undefined && caCertificate - ? 'success' - : 'default'; + ? 'success' + : 'default'; const handleClear = () => { dispatch(changeSatelliteCaCertificate('')); }; @@ -79,17 +79,17 @@ const SatelliteRegistration = () => { isRejected || validated === 'error' ? 'error' : validated === 'success' - ? 'success' - : 'default' + ? 'success' + : 'default' } > {isRejected ? 'Must be a .PEM/.CER/.CRT file no larger than 512 KB' : validated === 'error' - ? stepValidation.errors['certificate'] - : validated === 'success' - ? 'Certificate was uploaded' - : 'Drag and drop a valid certificate file or upload one'} + ? stepValidation.errors['certificate'] + : validated === 'success' + ? 'Certificate was uploaded' + : 'Drag and drop a valid certificate file or upload one'} </HelperTextItem> {(isRejected || validated !== 'success') && ( <HelperTextItem> diff --git a/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx b/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx index c44f4902..71ca07f1 100644 --- a/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx +++ b/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx @@ -140,8 +140,8 @@ export const SnapshotTable = ({ snapshotForDate.length > 0 ? snapshotForDate.map(({ repository_uuid }) => repository_uuid).join() : template && templateData && templateData.repository_uuids - ? templateData.repository_uuids.join(',') - : '', + ? templateData.repository_uuids.join(',') + : '', origin: ContentOrigin.REDHAT + ',' + ContentOrigin.CUSTOM, // Make sure to show both redhat and external }); diff --git a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx index ce0c76ec..5a610f24 100644 --- a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx +++ b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx @@ -313,10 +313,10 @@ export const TargetEnvGCPList = () => { {accountType === 'group' ? 'Google group' : accountType === 'serviceAccount' - ? 'Service account' - : accountType === 'user' - ? 'Google account' - : 'Domain'} + ? 'Service account' + : accountType === 'user' + ? 'Google account' + : 'Domain'} </Content> <Content component={ContentVariants.dt} @@ -520,10 +520,10 @@ export const ContentList = () => { useLatest ? 'Use the latest repository content' : template - ? 'Use content from the content template' - : `Repositories as of ${yyyyMMddFormat( - new Date(snapshotDate) - )}` + ? 'Use content from the content template' + : `Repositories as of ${yyyyMMddFormat( + new Date(snapshotDate) + )}` } hasAutoWidth minWidth="60rem" diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx index e8ce5597..7487ba81 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx @@ -37,7 +37,7 @@ export const AwsAccountId = () => { readOnlyVariant="default" isRequired id="aws-account-id" - value={sourceId && data ? data.aws?.account_id ?? '' : ''} + value={sourceId && data ? (data.aws?.account_id ?? '') : ''} aria-label="aws account id" /> </FormGroup> diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx index bcbaffc9..3c936d18 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx @@ -64,7 +64,7 @@ const AWSRegion = ({ value, onChange }: FormGroupProps<string>) => { const onSelect = ( _event: React.MouseEvent<Element, MouseEvent> | undefined, - value: string | number | undefined, + value: string | number | undefined ) => { onChange(value as string); setIsOpen(false); diff --git a/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx b/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx index 972902d7..716ab254 100644 --- a/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx +++ b/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx @@ -51,14 +51,14 @@ export const PasswordValidatedInput = ({ const PasswordToggleButton = () => { return ( - <Button - variant="control" - onClick={togglePasswordVisibility} - aria-label={isPasswordVisible ? 'Hide password' : 'Show password'} - isDisabled={isEditingWithoutValue} - > - {isPasswordVisible ? <EyeSlashIcon /> : <EyeIcon />} - </Button> + <Button + variant="control" + onClick={togglePasswordVisibility} + aria-label={isPasswordVisible ? 'Hide password' : 'Show password'} + isDisabled={isEditingWithoutValue} + > + {isPasswordVisible ? <EyeSlashIcon /> : <EyeIcon />} + </Button> ); }; @@ -78,13 +78,13 @@ export const PasswordValidatedInput = ({ </InputGroupItem> <InputGroupItem> {isEditingWithoutValue ? ( - <Tooltip content="Passwords cannot be viewed when editing a blueprint for security reasons"> + <Tooltip content="Passwords cannot be viewed when editing a blueprint for security reasons"> <span> - <PasswordToggleButton/> + <PasswordToggleButton /> </span> - </Tooltip> + </Tooltip> ) : ( - <PasswordToggleButton/> + <PasswordToggleButton /> )} </InputGroupItem> </InputGroup> diff --git a/src/Components/CreateImageWizard/utilities/requestMapper.ts b/src/Components/CreateImageWizard/utilities/requestMapper.ts index ec165c69..e41c859b 100644 --- a/src/Components/CreateImageWizard/utilities/requestMapper.ts +++ b/src/Components/CreateImageWizard/utilities/requestMapper.ts @@ -165,12 +165,12 @@ const getLatestRelease = (distribution: Distributions) => { return distribution.startsWith('rhel-10') ? RHEL_10 : distribution.startsWith('rhel-9') - ? RHEL_9 - : distribution.startsWith('rhel-8') - ? RHEL_8 - : distribution === ('centos-8' as Distributions) - ? CENTOS_9 - : distribution; + ? RHEL_9 + : distribution.startsWith('rhel-8') + ? RHEL_8 + : distribution === ('centos-8' as Distributions) + ? CENTOS_9 + : distribution; }; function commonRequestToState( @@ -256,13 +256,13 @@ function commonRequestToState( policyTitle: undefined, } : oscapProfile !== undefined - ? { - complianceType: 'openscap' as ComplianceType, - profileID: oscapProfile, - policyID: undefined, - policyTitle: undefined, - } - : initialState.compliance, + ? { + complianceType: 'openscap' as ComplianceType, + profileID: oscapProfile, + policyID: undefined, + policyTitle: undefined, + } + : initialState.compliance, firstBoot: request.customizations ? { script: getFirstBootScript(request.customizations.files), @@ -393,8 +393,8 @@ export const mapRequestToState = (request: BlueprintResponse): wizardState => { ? 'register-now-rhc' : 'register-now-insights' : getSatelliteCommand(request.customizations.files) - ? 'register-satellite' - : 'register-later', + ? 'register-satellite' + : 'register-later', activationKey: isRhel(request.distribution) ? request.customizations.subscription?.['activation-key'] : undefined, diff --git a/src/Components/ImagesTable/Instance.tsx b/src/Components/ImagesTable/Instance.tsx index dda9892c..5c10cf07 100644 --- a/src/Components/ImagesTable/Instance.tsx +++ b/src/Components/ImagesTable/Instance.tsx @@ -117,7 +117,7 @@ const ProvisioningLink = ({ scope: 'provisioning', module: './ProvisioningWizard', }, - {}, + {} ); const { permissions, isLoading: isLoadingPermission } = @@ -126,7 +126,7 @@ const ProvisioningLink = ({ // Recomputing this value on every render made the modal crash. Using a state // helps avoiding this situation as the value is only set the first time. const [appendTo] = useState( - document.querySelector(MODAL_ANCHOR) as HTMLElement, + document.querySelector(MODAL_ANCHOR) as HTMLElement ); const selectedBlueprintId = useAppSelector(selectSelectedBlueprintId); @@ -137,10 +137,10 @@ const ProvisioningLink = ({ { selectFromResult: ({ data }) => ({ selectedBlueprintVersion: data?.data.find( - (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId, + (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId )?.version, }), - }, + } ); if ( @@ -270,7 +270,7 @@ export const OciInstance = ({ compose, isExpired }: OciInstancePropTypes) => { if (options && !isOciUploadStatus(options)) { throw TypeError( - `Error: options must be of type OciUploadStatus, not ${typeof options}.`, + `Error: options must be of type OciUploadStatus, not ${typeof options}.` ); } @@ -404,7 +404,7 @@ export const AwsS3Instance = ({ if (options && !isAwss3UploadStatus(options)) { throw TypeError( - `Error: options must be of type Awss3UploadStatus, not ${typeof options}.`, + `Error: options must be of type Awss3UploadStatus, not ${typeof options}.` ); } diff --git a/src/Components/ImagesTable/Target.tsx b/src/Components/ImagesTable/Target.tsx index 33a7dea5..1181b824 100644 --- a/src/Components/ImagesTable/Target.tsx +++ b/src/Components/ImagesTable/Target.tsx @@ -3,7 +3,10 @@ import React from 'react'; import { Skeleton } from '@patternfly/react-core'; import { targetOptions } from '../../constants'; -import { ComposesResponseItem, useGetComposeClonesQuery } from '../../store/imageBuilderApi'; +import { + ComposesResponseItem, + useGetComposeClonesQuery, +} from '../../store/imageBuilderApi'; type TargetPropTypes = { compose: ComposesResponseItem; diff --git a/src/Hooks/MutationNotifications/useMutationWithNotification.tsx b/src/Hooks/MutationNotifications/useMutationWithNotification.tsx index 8499c28a..5a32444b 100644 --- a/src/Hooks/MutationNotifications/useMutationWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useMutationWithNotification.tsx @@ -50,7 +50,7 @@ export function useMutationWithNotification< isError: boolean; error?: unknown; reset: () => void; - } + }, >( mutationHook: ( options?: HookOptions diff --git a/src/store/listenerMiddleware.ts b/src/store/listenerMiddleware.ts index a1fd379b..6e5744d2 100644 --- a/src/store/listenerMiddleware.ts +++ b/src/store/listenerMiddleware.ts @@ -4,7 +4,7 @@ import { addListener, createListenerMiddleware, type TypedAddListener, - type TypedStartListening + type TypedStartListening, } from '@reduxjs/toolkit'; import type { AppDispatch, RootState } from './index'; diff --git a/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx b/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx index 88200855..5bad2736 100644 --- a/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx +++ b/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx @@ -469,9 +469,8 @@ describe('Import modal', () => { // Timezone await clickNext(); await screen.findByRole('heading', { name: /Timezone/ }); - const timezoneDropDown = await screen.findByPlaceholderText( - /Select a timezone/i - ); + const timezoneDropDown = + await screen.findByPlaceholderText(/Select a timezone/i); expect(timezoneDropDown).toHaveValue('US/Eastern'); await screen.findByText(/0\.north-america\.pool\.ntp\.org/i); await screen.findByText(/1\.north-america\.pool\.ntp\.org/i); @@ -481,9 +480,8 @@ describe('Import modal', () => { await screen.findByRole('heading', { name: /Locale/ }); await screen.findByText('English - United States (en_US.UTF-8)'); await screen.findByText('Japanese - Japan (ja_JP.UTF-8)'); - const keyboardDropDown = await screen.findByPlaceholderText( - /Select a keyboard/i - ); + const keyboardDropDown = + await screen.findByPlaceholderText(/Select a keyboard/i); expect(keyboardDropDown).toHaveValue('us'); // Hostname @@ -640,7 +638,9 @@ describe('Import modal', () => { ); await waitFor(() => user.click( - screen.getByRole('button', { name: /close invalid\$kernel\$argument/i }) + screen.getByRole('button', { + name: /close invalid\$kernel\$argument/i, + }) ) ); diff --git a/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx b/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx index 7de2f02f..48dbb379 100644 --- a/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx @@ -55,9 +55,8 @@ const goToReviewStep = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('image-details-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-details' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-details'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx b/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx index 72eab036..1013dbdd 100644 --- a/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx @@ -58,26 +58,23 @@ const addPort = async (port: string) => { const addEnabledFirewallService = async (service: string) => { const user = userEvent.setup(); - const enabledServicesInput = await screen.findByPlaceholderText( - /add enabled service/i - ); + const enabledServicesInput = + await screen.findByPlaceholderText(/add enabled service/i); await waitFor(() => user.type(enabledServicesInput, service.concat(' '))); }; const addDisabledFirewallService = async (service: string) => { const user = userEvent.setup(); - const disabledServiceInput = await screen.findByPlaceholderText( - /add disabled service/i - ); + const disabledServiceInput = + await screen.findByPlaceholderText(/add disabled service/i); await waitFor(() => user.type(disabledServiceInput, service.concat(' '))); }; const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('firewall-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-firewall' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-firewall'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx b/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx index c0999e20..4c04f797 100644 --- a/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx @@ -109,9 +109,8 @@ const goToReviewStep = async (): Promise<void> => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('firstboot-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-first-boot' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-first-boot'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx b/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx index 1c12717e..85f2ac5f 100644 --- a/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx @@ -73,9 +73,8 @@ const clearHostname = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('hostname-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-hostname' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-hostname'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx b/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx index 97b63798..41a312c3 100644 --- a/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx @@ -52,17 +52,15 @@ const goToReviewStep = async () => { const clearLanguageSearch = async () => { const user = userEvent.setup(); - const languagesDropdown = await screen.findByPlaceholderText( - /select a language/i - ); + const languagesDropdown = + await screen.findByPlaceholderText(/select a language/i); await waitFor(() => user.clear(languagesDropdown)); }; const searchForLanguage = async (search: string) => { const user = userEvent.setup(); - const languagesDropdown = await screen.findByPlaceholderText( - /select a language/i - ); + const languagesDropdown = + await screen.findByPlaceholderText(/select a language/i); await waitFor(() => user.type(languagesDropdown, search)); }; @@ -83,9 +81,8 @@ const selectLanguages = async () => { const searchForKeyboard = async (keyboard: string) => { const user = userEvent.setup({ delay: null }); - const keyboardDropdown = await screen.findByPlaceholderText( - /select a keyboard/i - ); + const keyboardDropdown = + await screen.findByPlaceholderText(/select a keyboard/i); await waitFor(() => user.type(keyboardDropdown, keyboard)); }; diff --git a/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx b/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx index b0269b75..73341a1d 100644 --- a/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx @@ -85,9 +85,8 @@ const selectPolicy = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('compliance-detail-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-compliance' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-compliance'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx b/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx index 8def9399..ad8273c2 100644 --- a/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx @@ -103,9 +103,8 @@ const goToReviewStep = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('oscap-detail-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-openscap' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-openscap'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx b/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx index d4c2bb7c..cb55d4e7 100644 --- a/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx @@ -98,9 +98,8 @@ const selectActivationKey = async (key: string) => { const addSatelliteRegistrationCommandViaKeyDown = async (command: string) => { const user = userEvent.setup({ delay: null }); - const satelliteRegistrationCommand = await screen.findByPlaceholderText( - /registration command/i - ); + const satelliteRegistrationCommand = + await screen.findByPlaceholderText(/registration command/i); await waitFor(() => user.clear(satelliteRegistrationCommand)); await waitFor(() => user.type(satelliteRegistrationCommand, command)); @@ -108,7 +107,7 @@ const addSatelliteRegistrationCommandViaKeyDown = async (command: string) => { }; const uploadFile = async (scriptName: string): Promise<void> => { - const user = userEvent.setup({ delay: null}); + const user = userEvent.setup({ delay: null }); const fileInput: HTMLElement | null = // eslint-disable-next-line testing-library/no-node-access document.querySelector('input[type="file"]'); diff --git a/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx b/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx index 0255fdc5..004db028 100644 --- a/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx @@ -90,9 +90,8 @@ const addDisabledService = async (service: string) => { const addMaskedService = async (service: string) => { const user = userEvent.setup(); - const maskedServiceInput = await screen.findByPlaceholderText( - 'Add masked service' - ); + const maskedServiceInput = + await screen.findByPlaceholderText('Add masked service'); await waitFor(() => user.type(maskedServiceInput, service.concat(' '))); }; @@ -126,9 +125,8 @@ const selectProfile = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('services-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-services' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-services'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx index 5fa248b8..bc57ea5c 100644 --- a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx @@ -3,7 +3,11 @@ import { screen, waitFor, within } from '@testing-library/react'; import { userEvent } from '@testing-library/user-event'; import { http, HttpResponse } from 'msw'; -import { CREATE_BLUEPRINT, EDIT_BLUEPRINT, PROVISIONING_API } from '../../../../../constants'; +import { + CREATE_BLUEPRINT, + EDIT_BLUEPRINT, + PROVISIONING_API, +} from '../../../../../constants'; import { CreateBlueprintRequest, ImageRequest, diff --git a/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx b/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx index 5adf8503..6209ffa9 100644 --- a/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx @@ -52,9 +52,8 @@ const goToReviewStep = async () => { const selectTimezone = async () => { const user = userEvent.setup({ delay: null }); - const timezoneDropdown = await screen.findByPlaceholderText( - /select a timezone/i - ); + const timezoneDropdown = + await screen.findByPlaceholderText(/select a timezone/i); await waitFor(() => user.type(timezoneDropdown, 'Europe/Am')); const amsterdamTimezone = await screen.findByText('Europe/Amsterdam'); await waitFor(() => user.click(amsterdamTimezone)); @@ -62,25 +61,22 @@ const selectTimezone = async () => { const searchForUnknownTimezone = async () => { const user = userEvent.setup(); - const timezoneDropdown = await screen.findByPlaceholderText( - /select a timezone/i - ); + const timezoneDropdown = + await screen.findByPlaceholderText(/select a timezone/i); await waitFor(() => user.type(timezoneDropdown, 'foo')); }; const addNtpServerViaKeyDown = async (ntpServer: string) => { const user = userEvent.setup(); - const ntpServersInput = await screen.findByPlaceholderText( - /add ntp servers/i - ); + const ntpServersInput = + await screen.findByPlaceholderText(/add ntp servers/i); await waitFor(() => user.type(ntpServersInput, ntpServer.concat(' '))); }; const addNtpServerViaAddButton = async (ntpServer: string) => { const user = userEvent.setup(); - const ntpServersInput = await screen.findByPlaceholderText( - /add ntp servers/i - ); + const ntpServersInput = + await screen.findByPlaceholderText(/add ntp servers/i); const addServerBtn = await screen.findByRole('button', { name: /add ntp server/i, }); @@ -99,9 +95,8 @@ const clearInput = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('timezone-expandable'); - const revisitButton = await within(expandable).findByTestId( - 'revisit-timezone' - ); + const revisitButton = + await within(expandable).findByTestId('revisit-timezone'); await waitFor(() => user.click(revisitButton)); }; diff --git a/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx b/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx index e0704deb..9b84dd2b 100644 --- a/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx @@ -61,9 +61,8 @@ const addAzureTarget = async () => { ); await clickNext(); - const azureSourceDropdown = await screen.findByPlaceholderText( - /select source/i - ); + const azureSourceDropdown = + await screen.findByPlaceholderText(/select source/i); await waitFor(() => user.click(azureSourceDropdown)); const azureSource = await screen.findByRole('option', { name: /azureSource1/i, @@ -182,9 +181,8 @@ const checkAdminCheckbox = async () => { const addUserGroupByUserIndex = async (group: string, index: number) => { const user = userEvent.setup(); - const userGroupInputs = await screen.findAllByPlaceholderText( - 'Add user group' - ); + const userGroupInputs = + await screen.findAllByPlaceholderText('Add user group'); await waitFor(() => user.click(userGroupInputs[index])); await waitFor(() => user.type(userGroupInputs[index], group)); const addGroup = await screen.findByRole('button', { @@ -512,24 +510,32 @@ describe('Users edit mode', () => { const id = mockBlueprintIds['users']; await renderEditMode(id); - const usersNavButtons = await screen.findAllByRole('button', { name: /Users/ }); + const usersNavButtons = await screen.findAllByRole('button', { + name: /Users/, + }); await waitFor(() => user.click(usersNavButtons[0])); const passwordToggleButton = await screen.findByRole('button', { - name: 'Show password' + name: 'Show password', }); expect(passwordToggleButton).toBeDisabled(); await waitFor(() => user.hover(passwordToggleButton)); - const tooltip = await screen.findByText('Passwords cannot be viewed when editing a blueprint for security reasons'); + const tooltip = await screen.findByText( + 'Passwords cannot be viewed when editing a blueprint for security reasons' + ); expect(tooltip).toBeInTheDocument(); await waitFor(() => user.unhover(passwordToggleButton)); await waitFor(() => { - expect(screen.queryByText('Passwords cannot be viewed when editing a blueprint for security reasons')).not.toBeInTheDocument(); + expect( + screen.queryByText( + 'Passwords cannot be viewed when editing a blueprint for security reasons' + ) + ).not.toBeInTheDocument(); }); }); }); diff --git a/src/test/Components/ImagesTable/ImagesTable.test.tsx b/src/test/Components/ImagesTable/ImagesTable.test.tsx index 532420c5..23db3cd6 100644 --- a/src/test/Components/ImagesTable/ImagesTable.test.tsx +++ b/src/test/Components/ImagesTable/ImagesTable.test.tsx @@ -83,9 +83,8 @@ describe('Images Table', () => { // No actual clicking because downloading is hard to test. // Instead, we just check href and download properties of the <a> element. - const downloadLink: HTMLAnchorElement = await within( - downloadButton - ).findByRole('link'); + const downloadLink: HTMLAnchorElement = + await within(downloadButton).findByRole('link'); expect(downloadLink.download).toBe( 'request-1579d95b-8f1d-4982-8c53-8c2afa4ab04c.json' ); diff --git a/src/test/setup.ts b/src/test/setup.ts index a21cefa0..067ab8d1 100644 --- a/src/test/setup.ts +++ b/src/test/setup.ts @@ -8,10 +8,12 @@ import 'vitest-canvas-mock'; window.HTMLElement.prototype.scrollTo = function () {}; // provide a fallback *only* when window.getComputedStyle is missing -// eslint-disable-next-line disable-autofix/@typescript-eslint/no-unnecessary-condition -window.getComputedStyle = window.getComputedStyle || (() => ({ - getPropertyValue: () => '', -})); +window.getComputedStyle = + // eslint-disable-next-line disable-autofix/@typescript-eslint/no-unnecessary-condition + window.getComputedStyle || + (() => ({ + getPropertyValue: () => '', + })); // ResizeObserver is not defined and needs to be mocked and stubbed const MockResizeObserver = vi.fn(() => ({ From eafcd200ae0ad675e5b56b08ed7036cca7500c0f Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 5 Aug 2025 13:48:30 +0200 Subject: [PATCH 067/123] ESLint: Set `trailingComma` to `all` and run lint fix --- eslint.config.js | 2 +- playwright/Customizations/Filesystem.spec.ts | 4 +- playwright/Customizations/Firewall.spec.ts | 8 +- playwright/Customizations/Hostname.spec.ts | 2 +- playwright/Customizations/Kernel.spec.ts | 12 +- playwright/Customizations/Locale.spec.ts | 26 ++-- playwright/Customizations/OpenSCAP.spec.ts | 34 ++--- playwright/Customizations/Systemd.spec.ts | 6 +- playwright/Customizations/Timezone.spec.ts | 8 +- playwright/fixtures/cleanup.ts | 2 +- playwright/helpers/login.ts | 8 +- playwright/helpers/wizardHelpers.ts | 12 +- playwright/test.spec.ts | 10 +- .../Blueprints/BlueprintActionsMenu.tsx | 4 +- .../Blueprints/BlueprintDiffModal.tsx | 4 +- .../Blueprints/BlueprintVersionFilter.tsx | 2 +- .../Blueprints/BlueprintsSideBar.tsx | 2 +- .../Blueprints/BuildImagesButton.tsx | 10 +- .../Blueprints/DeleteBlueprintModal.tsx | 2 +- .../Blueprints/ImportBlueprintModal.tsx | 16 +-- .../helpers/onPremToHostedBlueprintMapper.tsx | 10 +- .../CloudProviderConfig/AWSConfig.tsx | 2 +- .../CloudProviderConfig.tsx | 2 +- .../CloudProviderConfig/validators/index.tsx | 2 +- src/Components/Cockpit/NotReady.tsx | 4 +- .../CreateImageWizard/CreateImageWizard.tsx | 8 +- .../CreateImageWizard/LabelInput.tsx | 14 +- .../CreateImageWizard/ValidatedInput.tsx | 4 +- .../CreateImageWizard/steps/Details/index.tsx | 4 +- .../components/FileSystemConfiguration.tsx | 8 +- .../components/FileSystemPartition.tsx | 2 +- .../FileSystem/components/FileSystemTable.tsx | 18 +-- .../steps/FileSystem/index.tsx | 2 +- .../ImageOutput/components/ArchSelect.tsx | 4 +- .../ImageOutput/components/ReleaseSelect.tsx | 4 +- .../components/TargetEnvironment.tsx | 2 +- .../Kernel/components/KernelArguments.tsx | 4 +- .../steps/Kernel/components/KernelName.tsx | 2 +- .../Locale/components/KeyboardDropDown.tsx | 4 +- .../Locale/components/LanguagesDropDown.tsx | 8 +- .../components/OscapProfileInformation.tsx | 6 +- .../steps/Oscap/components/PolicySelector.tsx | 16 +-- .../Oscap/components/ProfileSelector.tsx | 20 +-- .../Oscap/components/useSelectorHandlers.tsx | 4 +- .../CreateImageWizard/steps/Oscap/index.tsx | 6 +- .../steps/Packages/PackageRecommendations.tsx | 12 +- .../steps/Packages/Packages.tsx | 54 ++++---- .../components/ActivationKeyInformation.tsx | 4 +- .../components/ActivationKeysList.tsx | 16 +-- .../Registration/components/Registration.tsx | 4 +- .../components/SatelliteRegistration.tsx | 2 +- .../SatelliteRegistrationCommand.tsx | 2 +- .../steps/Repositories/Repositories.tsx | 108 ++++++++-------- .../steps/Repositories/RepositoriesStatus.tsx | 4 +- .../Repositories/components/BulkSelect.tsx | 2 +- .../Repositories/components/Utilities.ts | 4 +- .../steps/Review/Footer/CreateDropdown.tsx | 8 +- .../steps/Review/Footer/EditDropdown.tsx | 6 +- .../steps/Review/ReviewStep.tsx | 32 ++--- .../steps/Review/ReviewStepTables.tsx | 8 +- .../steps/Review/ReviewStepTextLists.tsx | 20 +-- .../Services/components/ServicesInputs.tsx | 14 +- .../components/ConditionalTooltip.tsx | 2 +- .../steps/Snapshot/components/Snapshot.tsx | 2 +- .../steps/Snapshot/components/Templates.tsx | 6 +- .../TargetEnvironment/Aws/AwsAccountId.tsx | 2 +- .../Aws/AwsSourcesSelect.tsx | 14 +- .../steps/TargetEnvironment/Aws/index.tsx | 2 +- .../Azure/AzureAuthButton.tsx | 2 +- .../Azure/AzureResourceGroups.tsx | 6 +- .../Azure/AzureSourcesSelect.tsx | 12 +- .../Users/components/RemoveUserModal.tsx | 2 +- .../steps/Users/components/UserInfo.tsx | 14 +- .../Users/components/calculateNewIndex.ts | 2 +- .../utilities/PasswordValidatedInput.tsx | 2 +- .../checkRepositoriesAvailability.ts | 4 +- .../utilities/requestMapper.ts | 36 +++--- .../utilities/useGenerateDefaultName.ts | 2 +- .../utilities/useValidation.tsx | 32 ++--- .../CreateImageWizard/validators.ts | 10 +- src/Components/ImagesTable/ClonesTable.tsx | 2 +- src/Components/ImagesTable/ImageDetails.tsx | 14 +- src/Components/ImagesTable/ImagesTable.tsx | 24 ++-- .../ImagesTable/ImagesTableToolbar.tsx | 8 +- src/Components/ImagesTable/Instance.tsx | 12 +- src/Components/ImagesTable/Status.tsx | 2 +- src/Components/LandingPage/NewAlert.tsx | 4 +- .../ShareImageModal/RegionsSelect.tsx | 10 +- .../sharedComponents/ImageBuilderHeader.tsx | 2 +- .../useCloneComposeWithNotification.tsx | 2 +- .../useComposeBPWithNotification.tsx | 2 +- .../useCreateBPWithNotification.tsx | 2 +- .../useDeleteBPWithNotification.tsx | 2 +- .../useFixupBPWithNotification.tsx | 2 +- .../useMutationWithNotification.tsx | 4 +- .../useUpdateBPWithNotification.tsx | 2 +- src/Router.tsx | 4 +- src/Utilities/analytics.ts | 6 +- src/Utilities/epel.ts | 6 +- src/Utilities/sortfn.ts | 2 +- src/Utilities/time.ts | 2 +- src/Utilities/useComposerStatus.tsx | 4 +- src/Utilities/useDebounce.tsx | 4 +- src/Utilities/useGetEnvironment.ts | 2 +- src/Utilities/useOnPremOpenSCAP.tsx | 2 +- src/Utilities/useProvisioningPermissions.ts | 6 +- src/store/BlueprintSlice.ts | 6 +- src/store/cockpit/baseQuery.ts | 4 +- src/store/cockpit/cockpitApi.ts | 32 ++--- src/store/helpers.ts | 2 +- src/store/index.ts | 12 +- src/store/service/enhancedImageBuilderApi.ts | 6 +- src/store/typeGuards.ts | 14 +- src/store/wizardSlice.ts | 106 ++++++++-------- .../Components/Blueprints/Blueprints.test.tsx | 42 +++--- .../Blueprints/ImportBlueprintModal.test.tsx | 120 +++++++++--------- .../CreateImageWizard.test.tsx | 30 ++--- .../steps/Details/Details.test.tsx | 4 +- .../FileSystemConfiguration.test.tsx | 10 +- .../steps/Firewall/Firewall.test.tsx | 12 +- .../steps/FirstBoot/Firstboot.test.tsx | 4 +- .../steps/Hostname/Hostname.test.tsx | 2 +- .../steps/ImageOutput/ImageOutput.test.tsx | 80 ++++++------ .../steps/Kernel/Kernel.test.tsx | 8 +- .../steps/Locale/Locale.test.tsx | 10 +- .../steps/Oscap/Compliance.test.tsx | 2 +- .../steps/Oscap/Oscap.test.tsx | 18 +-- .../steps/Packages/Packages.test.tsx | 10 +- .../steps/Registration/Registration.test.tsx | 28 ++-- .../steps/Repositories/Repositories.test.tsx | 12 +- .../steps/Review/Review.test.tsx | 8 +- .../steps/Services/Services.test.tsx | 24 ++-- .../steps/Snapshot/Snapshot.test.tsx | 6 +- .../TargetEnvironment/AwsTarget.test.tsx | 12 +- .../TargetEnvironment/AzureTarget.test.tsx | 26 ++-- .../TargetEnvironment/GCPTarget.test.tsx | 16 +-- .../steps/Timezone/Timezone.test.tsx | 14 +- .../steps/Users/Users.test.tsx | 20 +-- .../CreateImageWizard/wizardTestUtils.tsx | 6 +- .../ImagesTable/ImagesTable.test.tsx | 48 +++---- .../LandingPage/LandingPage.test.tsx | 4 +- .../ShareImageModal/ShareImageModal.test.tsx | 10 +- src/test/fixtures/activationKeys.ts | 2 +- src/test/fixtures/architectures.ts | 2 +- src/test/fixtures/oscap.ts | 6 +- src/test/fixtures/packages.ts | 4 +- src/test/fixtures/repositories.ts | 8 +- src/test/fixtures/sources.ts | 4 +- src/test/fixtures/templates.ts | 6 +- src/test/mocks/cockpit/fsinfo.ts | 2 +- src/test/mocks/handlers.js | 14 +- src/test/testUtils.js | 4 +- 152 files changed, 871 insertions(+), 867 deletions(-) diff --git a/eslint.config.js b/eslint.config.js index 39da3786..4c61721d 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -129,7 +129,7 @@ module.exports = defineConfig([ tsxSingleQuote: true, tsSingleQuote: true, printWidth: 80, - trailingComma: 'es5', + trailingComma: 'all', }], }, settings: { diff --git a/playwright/Customizations/Filesystem.spec.ts b/playwright/Customizations/Filesystem.spec.ts index cedcb52d..31f669f5 100644 --- a/playwright/Customizations/Filesystem.spec.ts +++ b/playwright/Customizations/Filesystem.spec.ts @@ -158,8 +158,8 @@ test('Create a blueprint with Filesystem customization', async ({ await frame.getByRole('option', { name: '/usr' }).click(); await expect( frame.getByText( - 'Sub-directories for the /usr mount point are no longer supported' - ) + 'Sub-directories for the /usr mount point are no longer supported', + ), ).toBeVisible(); await frame.getByRole('button', { name: '/usr' }).click(); diff --git a/playwright/Customizations/Firewall.spec.ts b/playwright/Customizations/Firewall.spec.ts index c201f7ac..1bfba62c 100644 --- a/playwright/Customizations/Firewall.spec.ts +++ b/playwright/Customizations/Firewall.spec.ts @@ -66,9 +66,9 @@ test('Create a blueprint with Firewall customization', async ({ await expect( frame .getByText( - 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp' + 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp', ) - .nth(0) + .nth(0), ).toBeVisible(); }); @@ -76,7 +76,7 @@ test('Create a blueprint with Firewall customization', async ({ await frame.getByPlaceholder('Add disabled service').fill('1'); await frame.getByRole('button', { name: 'Add disabled service' }).click(); await expect( - frame.getByText('Expected format: <service-name>. Example: sshd').nth(0) + frame.getByText('Expected format: <service-name>. Example: sshd').nth(0), ).toBeVisible(); }); @@ -84,7 +84,7 @@ test('Create a blueprint with Firewall customization', async ({ await frame.getByPlaceholder('Add enabled service').fill('ťčš'); await frame.getByRole('button', { name: 'Add enabled service' }).click(); await expect( - frame.getByText('Expected format: <service-name>. Example: sshd').nth(1) + frame.getByText('Expected format: <service-name>. Example: sshd').nth(1), ).toBeVisible(); }); diff --git a/playwright/Customizations/Hostname.spec.ts b/playwright/Customizations/Hostname.spec.ts index dcb65af2..fa475178 100644 --- a/playwright/Customizations/Hostname.spec.ts +++ b/playwright/Customizations/Hostname.spec.ts @@ -83,7 +83,7 @@ test('Create a blueprint with Hostname customization', async ({ await fillInImageOutputGuest(page); await page.getByRole('button', { name: 'Hostname' }).click(); await expect( - page.getByRole('textbox', { name: 'hostname input' }) + page.getByRole('textbox', { name: 'hostname input' }), ).toHaveValue(hostname + 'edited'); await page.getByRole('button', { name: 'Cancel' }).click(); }); diff --git a/playwright/Customizations/Kernel.spec.ts b/playwright/Customizations/Kernel.spec.ts index 881459d9..14137446 100644 --- a/playwright/Customizations/Kernel.spec.ts +++ b/playwright/Customizations/Kernel.spec.ts @@ -51,26 +51,26 @@ test('Create a blueprint with Kernel customization', async ({ await frame.getByRole('button', { name: 'Add kernel argument' }).click(); await expect( frame.getByText( - 'Expected format: <kernel-argument>. Example: console=tty0' - ) + 'Expected format: <kernel-argument>. Example: console=tty0', + ), ).toBeVisible(); await frame.getByPlaceholder('Select kernel package').fill('new-package'); await frame .getByRole('option', { name: 'Custom kernel package "new-' }) .click(); await expect( - frame.getByRole('heading', { name: 'Warning alert: Custom kernel' }) + frame.getByRole('heading', { name: 'Warning alert: Custom kernel' }), ).toBeVisible(); await frame.getByRole('button', { name: 'Clear input' }).first().click(); await frame.getByRole('button', { name: 'Menu toggle' }).click(); await expect( - frame.getByRole('option', { name: 'new-package' }) + frame.getByRole('option', { name: 'new-package' }), ).toBeVisible(); await frame.getByPlaceholder('Select kernel package').fill('f'); await expect( frame.getByRole('option', { name: '"f" is not a valid kernel package name', - }) + }), ).toBeVisible(); await frame.getByPlaceholder('Add kernel argument').fill('console=tty0'); await frame.getByRole('button', { name: 'Add kernel argument' }).click(); @@ -121,7 +121,7 @@ test('Create a blueprint with Kernel customization', async ({ await fillInImageOutputGuest(frame); await frame.getByRole('button', { name: 'Kernel' }).click(); await expect(frame.getByPlaceholder('Select kernel package')).toHaveValue( - 'kernel' + 'kernel', ); await expect(frame.getByText('rootwait')).toBeVisible(); await expect(frame.getByText('console=tty0')).toBeVisible(); diff --git a/playwright/Customizations/Locale.spec.ts b/playwright/Customizations/Locale.spec.ts index 1d1e491a..53956a73 100644 --- a/playwright/Customizations/Locale.spec.ts +++ b/playwright/Customizations/Locale.spec.ts @@ -48,7 +48,7 @@ test('Create a blueprint with Locale customization', async ({ await expect( frame.getByRole('button', { name: 'Close Western Frisian - Germany (fy_DE.UTF-8)', - }) + }), ).toBeEnabled(); await frame .getByRole('button', { @@ -58,7 +58,7 @@ test('Create a blueprint with Locale customization', async ({ await expect( frame.getByRole('button', { name: 'Close Western Frisian - Germany (fy_DE.UTF-8)', - }) + }), ).toBeHidden(); await frame.getByPlaceholder('Select a language').fill('fy'); await frame @@ -67,20 +67,20 @@ test('Create a blueprint with Locale customization', async ({ await expect( frame.getByRole('button', { name: 'Close Western Frisian - Germany (fy_DE.UTF-8)', - }) + }), ).toBeEnabled(); await frame.getByPlaceholder('Select a language').fill('aa'); await frame .getByRole('option', { name: 'aa - Djibouti (aa_DJ.UTF-8)' }) .click(); await expect( - frame.getByRole('button', { name: 'Close aa - Djibouti (aa_DJ.UTF-8)' }) + frame.getByRole('button', { name: 'Close aa - Djibouti (aa_DJ.UTF-8)' }), ).toBeEnabled(); await frame.getByPlaceholder('Select a language').fill('aa'); await expect( frame.getByText( - 'aa - Djibouti (aa_DJ.UTF-8)Language already addedaa - Eritrea (aa_ER.UTF-8)aa - Ethiopia (aa_ET.UTF-8)' - ) + 'aa - Djibouti (aa_DJ.UTF-8)Language already addedaa - Eritrea (aa_ER.UTF-8)aa - Ethiopia (aa_ET.UTF-8)', + ), ).toBeAttached(); await frame.getByPlaceholder('Select a language').fill('xxx'); await expect(frame.getByText('No results found for')).toBeAttached(); @@ -104,17 +104,17 @@ test('Create a blueprint with Locale customization', async ({ await expect( frame.getByRole('button', { name: 'Close Western Frisian - Germany (fy_DE.UTF-8)', - }) + }), ).toBeEnabled(); await expect( - frame.getByRole('button', { name: 'Close aa - Djibouti (aa_DJ.UTF-8)' }) + frame.getByRole('button', { name: 'Close aa - Djibouti (aa_DJ.UTF-8)' }), ).toBeEnabled(); await frame.getByPlaceholder('Select a language').fill('aa'); await frame .getByRole('option', { name: 'aa - Eritrea (aa_ER.UTF-8)' }) .click(); await expect( - frame.getByRole('button', { name: 'Close aa - Eritrea (aa_ER.UTF-8)' }) + frame.getByRole('button', { name: 'Close aa - Eritrea (aa_ER.UTF-8)' }), ).toBeEnabled(); await frame.getByRole('button', { name: 'Clear input' }).click(); await frame.getByRole('button', { name: 'Menu toggle' }).nth(1).click(); @@ -143,16 +143,16 @@ test('Create a blueprint with Locale customization', async ({ await expect( frame.getByRole('button', { name: 'Close Western Frisian - Germany (fy_DE.UTF-8)', - }) + }), ).toBeEnabled(); await expect( - frame.getByRole('button', { name: 'Close aa - Djibouti (aa_DJ.UTF-8)' }) + frame.getByRole('button', { name: 'Close aa - Djibouti (aa_DJ.UTF-8)' }), ).toBeEnabled(); await expect( - frame.getByRole('button', { name: 'Close aa - Eritrea (aa_ER.UTF-8)' }) + frame.getByRole('button', { name: 'Close aa - Eritrea (aa_ER.UTF-8)' }), ).toBeEnabled(); await expect(frame.getByPlaceholder('Select a keyboard')).toHaveValue( - 'ANSI-dvorak' + 'ANSI-dvorak', ); await page.getByRole('button', { name: 'Cancel' }).click(); }); diff --git a/playwright/Customizations/OpenSCAP.spec.ts b/playwright/Customizations/OpenSCAP.spec.ts index aa575022..111daf39 100644 --- a/playwright/Customizations/OpenSCAP.spec.ts +++ b/playwright/Customizations/OpenSCAP.spec.ts @@ -60,36 +60,36 @@ test('Create a blueprint with OpenSCAP customization', async ({ name: 'Draggable row draggable button /tmp xfs 1 GiB', }) .getByRole('button') - .nth(3) + .nth(3), ).toBeVisible(); await frame.getByRole('button', { name: 'Additional packages' }).click(); await frame.getByRole('button', { name: 'Selected (8)' }).click(); await expect(frame.getByRole('gridcell', { name: 'aide' })).toBeVisible(); await expect(frame.getByRole('gridcell', { name: 'chrony' })).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'firewalld' }) + frame.getByRole('gridcell', { name: 'firewalld' }), ).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'libpwquality' }) + frame.getByRole('gridcell', { name: 'libpwquality' }), ).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'libselinux' }) + frame.getByRole('gridcell', { name: 'libselinux' }), ).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'nftables' }) + frame.getByRole('gridcell', { name: 'nftables' }), ).toBeVisible(); await expect(frame.getByRole('gridcell', { name: 'sudo' })).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'systemd-journal-remote' }) + frame.getByRole('gridcell', { name: 'systemd-journal-remote' }), ).toBeVisible(); await frame.getByRole('button', { name: 'Systemd services' }).click(); await expect( - frame.getByText('Required by OpenSCAPcrondfirewalldsystemd-journald') + frame.getByText('Required by OpenSCAPcrondfirewalldsystemd-journald'), ).toBeVisible(); await frame.getByPlaceholder('Add masked service').fill('nftables'); await frame.getByPlaceholder('Add masked service').press('Enter'); await expect( - frame.getByText('Masked service already exists') + frame.getByText('Masked service already exists'), ).toBeVisible(); await expect(frame.getByText('Required by OpenSCAPcupsnfs-')).toBeVisible(); await expect(frame.getByText('nfs-server')).toBeVisible(); @@ -123,38 +123,38 @@ test('Create a blueprint with OpenSCAP customization', async ({ await frame.getByRole('button', { name: 'Kernel' }).click(); await expect( - frame.getByText('Required by OpenSCAPaudit_backlog_limit=8192audit=') + frame.getByText('Required by OpenSCAPaudit_backlog_limit=8192audit='), ).toBeVisible(); await frame.getByRole('button', { name: 'Additional packages' }).click(); await frame.getByRole('button', { name: 'Selected (10)' }).click(); await expect(frame.getByRole('gridcell', { name: 'aide' })).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'audit-libs' }) + frame.getByRole('gridcell', { name: 'audit-libs' }), ).toBeVisible(); await expect(frame.getByRole('gridcell', { name: 'chrony' })).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'firewalld' }) + frame.getByRole('gridcell', { name: 'firewalld' }), ).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'libpwquality' }) + frame.getByRole('gridcell', { name: 'libpwquality' }), ).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'libselinux' }) + frame.getByRole('gridcell', { name: 'libselinux' }), ).toBeVisible(); await expect( - frame.getByRole('gridcell', { name: 'nftables' }) + frame.getByRole('gridcell', { name: 'nftables' }), ).toBeVisible(); await expect(frame.getByRole('gridcell', { name: 'sudo' })).toBeVisible(); await frame.getByRole('button', { name: 'Systemd services' }).click(); await expect( frame.getByText( - 'Required by OpenSCAPauditdcrondfirewalldsystemd-journald' - ) + 'Required by OpenSCAPauditdcrondfirewalldsystemd-journald', + ), ).toBeVisible(); await frame.getByPlaceholder('Add masked service').fill('nftables'); await frame.getByPlaceholder('Add masked service').press('Enter'); await expect( - frame.getByText('Masked service already exists') + frame.getByText('Masked service already exists'), ).toBeVisible(); await expect(frame.getByText('Required by OpenSCAPcupsnfs-')).toBeVisible(); await expect(frame.getByText('nfs-server')).toBeVisible(); diff --git a/playwright/Customizations/Systemd.spec.ts b/playwright/Customizations/Systemd.spec.ts index dec29c30..a7360ca9 100644 --- a/playwright/Customizations/Systemd.spec.ts +++ b/playwright/Customizations/Systemd.spec.ts @@ -65,19 +65,19 @@ test('Create a blueprint with Systemd customization', async ({ await frame.getByPlaceholder('Add disabled service').fill('&&'); await frame.getByRole('button', { name: 'Add disabled service' }).click(); await expect( - frame.getByText('Expected format: <service-name>. Example: sshd').nth(0) + frame.getByText('Expected format: <service-name>. Example: sshd').nth(0), ).toBeVisible(); await frame.getByPlaceholder('Add enabled service').fill('áá'); await frame.getByRole('button', { name: 'Add enabled service' }).click(); await expect( - frame.getByText('Expected format: <service-name>. Example: sshd').nth(1) + frame.getByText('Expected format: <service-name>. Example: sshd').nth(1), ).toBeVisible(); await frame.getByPlaceholder('Add masked service').fill('78'); await frame.getByRole('button', { name: 'Add masked service' }).click(); await expect( - frame.getByText('Expected format: <service-name>. Example: sshd').nth(2) + frame.getByText('Expected format: <service-name>. Example: sshd').nth(2), ).toBeVisible(); }); diff --git a/playwright/Customizations/Timezone.spec.ts b/playwright/Customizations/Timezone.spec.ts index f625559a..8a3c51cf 100644 --- a/playwright/Customizations/Timezone.spec.ts +++ b/playwright/Customizations/Timezone.spec.ts @@ -58,7 +58,7 @@ test('Create a blueprint with Timezone customization', async ({ await expect( frame .getByText('Expected format: <ntp-server>. Example: time.redhat.com') - .nth(0) + .nth(0), ).toBeVisible(); await frame.getByPlaceholder('Add NTP servers').fill('0.cz.pool.ntp.org'); await frame.getByRole('button', { name: 'Add NTP server' }).click(); @@ -86,12 +86,12 @@ test('Create a blueprint with Timezone customization', async ({ await frame.getByLabel('Revisit Timezone step').click(); await expect(frame.getByText('Canada/Saskatchewan')).toBeHidden(); await expect(frame.getByPlaceholder('Select a timezone')).toHaveValue( - 'Europe/Stockholm' + 'Europe/Stockholm', ); await frame.getByPlaceholder('Select a timezone').fill('Europe'); await frame.getByRole('option', { name: 'Europe/Oslo' }).click(); await expect(frame.getByPlaceholder('Select a timezone')).toHaveValue( - 'Europe/Oslo' + 'Europe/Oslo', ); await expect(frame.getByText('0.nl.pool.ntp.org')).toBeVisible(); await expect(frame.getByText('0.de.pool.ntp.org')).toBeVisible(); @@ -118,7 +118,7 @@ test('Create a blueprint with Timezone customization', async ({ await fillInImageOutputGuest(page); await frame.getByRole('button', { name: 'Timezone' }).click(); await expect(frame.getByPlaceholder('Select a timezone')).toHaveValue( - 'Europe/Oslo' + 'Europe/Oslo', ); await expect(frame.getByText('0.nl.pool.ntp.org')).toBeVisible(); await expect(frame.getByText('0.de.pool.ntp.org')).toBeVisible(); diff --git a/playwright/fixtures/cleanup.ts b/playwright/fixtures/cleanup.ts index db3fa157..74f1cb8c 100644 --- a/playwright/fixtures/cleanup.ts +++ b/playwright/fixtures/cleanup.ts @@ -38,7 +38,7 @@ export const test = oldTest.extend<WithCleanup>({ async () => { await Promise.all(Array.from(cleanupFns).map(([, fn]) => fn())); }, - { box: true } + { box: true }, ); }, }); diff --git a/playwright/helpers/login.ts b/playwright/helpers/login.ts index 2e33e024..4ae5531b 100644 --- a/playwright/helpers/login.ts +++ b/playwright/helpers/login.ts @@ -68,14 +68,14 @@ const loginCockpit = async (page: Page, user: string, password: string) => { try { // Check if the user already has administrative access await expect( - page.getByRole('button', { name: 'Administrative access' }) + page.getByRole('button', { name: 'Administrative access' }), ).toBeVisible(); } catch { // If not, try to gain it // cockpit-image-builder needs superuser, expect an error message // when the user does not have admin priviliges await expect( - frame.getByRole('heading', { name: 'Access is limited' }) + frame.getByRole('heading', { name: 'Access is limited' }), ).toBeVisible(); await page.getByRole('button', { name: 'Limited access' }).click(); @@ -99,10 +99,10 @@ const loginCockpit = async (page: Page, user: string, password: string) => { // expect to have administrative access await expect( - page.getByRole('button', { name: 'Administrative access' }) + page.getByRole('button', { name: 'Administrative access' }), ).toBeVisible(); await expect( - frame.getByRole('heading', { name: 'All images' }) + frame.getByRole('heading', { name: 'All images' }), ).toBeVisible(); }; diff --git a/playwright/helpers/wizardHelpers.ts b/playwright/helpers/wizardHelpers.ts index bef61f68..3d44a6b6 100644 --- a/playwright/helpers/wizardHelpers.ts +++ b/playwright/helpers/wizardHelpers.ts @@ -10,7 +10,7 @@ import { ibFrame, navigateToLandingPage } from './navHelpers'; */ export const createBlueprint = async ( page: Page | FrameLocator, - blueprintName: string + blueprintName: string, ) => { await page.getByRole('button', { name: 'Create blueprint' }).click(); await page.getByRole('button', { name: 'Close' }).first().click(); @@ -31,7 +31,7 @@ export const createBlueprint = async ( */ export const fillInDetails = async ( page: Page | FrameLocator, - blueprintName: string + blueprintName: string, ) => { await page.getByRole('listitem').filter({ hasText: 'Details' }).click(); await page @@ -86,7 +86,7 @@ export const deleteBlueprint = async (page: Page, blueprintName: string) => { // Check if no blueprints found -> that means no blueprint was created -> fail gracefully and do not raise error try { await expect( - frame.getByRole('heading', { name: 'No blueprints found' }) + frame.getByRole('heading', { name: 'No blueprints found' }), ).toBeVisible({ timeout: 5_000 }); // Shorter timeout to avoid hanging uncessarily return; // Fail gracefully, no blueprint to delete // eslint-disable-next-line @typescript-eslint/no-unused-vars @@ -101,7 +101,7 @@ export const deleteBlueprint = async (page: Page, blueprintName: string) => { await frame.getByRole('menuitem', { name: 'Delete blueprint' }).click(); await frame.getByRole('button', { name: 'Delete' }).click(); }, - { box: true } + { box: true }, ); }; @@ -129,7 +129,7 @@ export const exportBlueprint = async (page: Page, blueprintName: string) => { */ export const importBlueprint = async ( page: Page | FrameLocator, - blueprintName: string + blueprintName: string, ) => { if (isHosted()) { await page.getByRole('button', { name: 'Import' }).click(); @@ -138,7 +138,7 @@ export const importBlueprint = async ( .locator('input[type=file]') .setInputFiles('../../downloads/' + blueprintName + '.json'); await expect( - page.getByRole('textbox', { name: 'File upload' }) + page.getByRole('textbox', { name: 'File upload' }), ).not.toBeEmpty(); await page.getByRole('button', { name: 'Review and Finish' }).click(); } diff --git a/playwright/test.spec.ts b/playwright/test.spec.ts index bdd02268..0f46028e 100644 --- a/playwright/test.spec.ts +++ b/playwright/test.spec.ts @@ -87,7 +87,7 @@ test.describe.serial('test', () => { await frame.getByRole('button', { name: 'Create blueprint' }).click(); await expect( - frame.locator('.pf-v6-c-card__title-text').getByText(blueprintName) + frame.locator('.pf-v6-c-card__title-text').getByText(blueprintName), ).toBeVisible(); }); @@ -205,7 +205,7 @@ test.describe.serial('test', () => { if (await switchInput.isChecked()) { await frame.getByRole('button', { name: 'Cancel' }).click(); await expect( - frame.getByRole('heading', { name: 'All images' }) + frame.getByRole('heading', { name: 'All images' }), ).toBeVisible(); } else { const switchToggle = frame.locator('.pf-v6-c-switch'); @@ -219,7 +219,7 @@ test.describe.serial('test', () => { await frame.getByPlaceholder('Path to AWS credentials').fill(credentials); await frame.getByRole('button', { name: 'Submit' }).click(); await expect( - frame.getByRole('heading', { name: 'All images' }) + frame.getByRole('heading', { name: 'All images' }), ).toBeVisible(); } @@ -236,7 +236,7 @@ test.describe.serial('test', () => { await expect(frame.getByPlaceholder('AWS bucket')).toHaveValue(bucket); await expect(frame.getByPlaceholder('Path to AWS credentials')).toHaveValue( - credentials + credentials, ); await frame.getByRole('button', { name: 'Cancel' }).click(); @@ -276,7 +276,7 @@ test.describe.serial('test', () => { frame.getByRole('heading', { name: 'Details' }); await frame.getByTestId('blueprint').fill(cockpitBlueprintname); await expect(frame.getByTestId('blueprint')).toHaveValue( - cockpitBlueprintname + cockpitBlueprintname, ); await frame.getByRole('button', { name: 'Next', exact: true }).click(); diff --git a/src/Components/Blueprints/BlueprintActionsMenu.tsx b/src/Components/Blueprints/BlueprintActionsMenu.tsx index beb66d94..dec3ff84 100644 --- a/src/Components/Blueprints/BlueprintActionsMenu.tsx +++ b/src/Components/Blueprints/BlueprintActionsMenu.tsx @@ -30,7 +30,7 @@ export const BlueprintActionsMenu: React.FunctionComponent< setShowBlueprintActionsMenu(!showBlueprintActionsMenu); }; const importExportFlag = useFlagWithEphemDefault( - 'image-builder.import.enabled' + 'image-builder.import.enabled', ); const [trigger] = useLazyExportBlueprintQuery(); @@ -81,7 +81,7 @@ export const BlueprintActionsMenu: React.FunctionComponent< async function handleExportBlueprint( blueprintName: string, - blueprint: BlueprintExportResponse + blueprint: BlueprintExportResponse, ) { const jsonData = JSON.stringify(blueprint, null, 2); const blob = new Blob([jsonData], { type: 'application/json' }); diff --git a/src/Components/Blueprints/BlueprintDiffModal.tsx b/src/Components/Blueprints/BlueprintDiffModal.tsx index 28cf5868..96effe58 100644 --- a/src/Components/Blueprints/BlueprintDiffModal.tsx +++ b/src/Components/Blueprints/BlueprintDiffModal.tsx @@ -34,11 +34,11 @@ const BlueprintDiffModal = ({ const { data: baseBlueprint } = useGetBlueprintQuery( { id: selectedBlueprintId as string, version: baseVersion || -1 }, - { skip: !selectedBlueprintId || !baseVersion } + { skip: !selectedBlueprintId || !baseVersion }, ); const { data: blueprint } = useGetBlueprintQuery( { id: selectedBlueprintId as string }, - { skip: !selectedBlueprintId } + { skip: !selectedBlueprintId }, ); if (!baseBlueprint || !blueprint) { diff --git a/src/Components/Blueprints/BlueprintVersionFilter.tsx b/src/Components/Blueprints/BlueprintVersionFilter.tsx index 7d7b885e..2ba17a9e 100644 --- a/src/Components/Blueprints/BlueprintVersionFilter.tsx +++ b/src/Components/Blueprints/BlueprintVersionFilter.tsx @@ -33,7 +33,7 @@ const BlueprintVersionFilter: React.FC<blueprintVersionFilterProps> = ({ const onSelect = ( _event: React.MouseEvent<Element, MouseEvent> | undefined, - value: versionFilterType + value: versionFilterType, ) => { dispatch(setBlueprintVersionFilter(value)); if (onFilterChange) onFilterChange(); diff --git a/src/Components/Blueprints/BlueprintsSideBar.tsx b/src/Components/Blueprints/BlueprintsSideBar.tsx index 02337d32..e2197693 100644 --- a/src/Components/Blueprints/BlueprintsSideBar.tsx +++ b/src/Components/Blueprints/BlueprintsSideBar.tsx @@ -194,7 +194,7 @@ const BlueprintSearch = ({ blueprintsTotal }: blueprintSearchProps) => { dispatch(imageBuilderApi.util.invalidateTags([{ type: 'Blueprints' }])); dispatch(setBlueprintSearchInput(filter.length > 0 ? filter : undefined)); }, DEBOUNCED_SEARCH_WAIT_TIME), - [] + [], ); React.useEffect(() => { return () => { diff --git a/src/Components/Blueprints/BuildImagesButton.tsx b/src/Components/Blueprints/BuildImagesButton.tsx index 2ca2498a..10abfbd2 100644 --- a/src/Components/Blueprints/BuildImagesButton.tsx +++ b/src/Components/Blueprints/BuildImagesButton.tsx @@ -56,7 +56,7 @@ export const BuildImagesButton = ({ children }: BuildImagesButtonPropTypes) => { id: selectedBlueprintId, body: { image_types: blueprintImageType?.filter( - (target) => !deselectedTargets.includes(target) + (target) => !deselectedTargets.includes(target), ), }, }); @@ -74,21 +74,21 @@ export const BuildImagesButton = ({ children }: BuildImagesButtonPropTypes) => { setIsOpen(!isOpen); }; const { data: blueprintDetails } = useGetBlueprintQuery( - selectedBlueprintId ? { id: selectedBlueprintId } : skipToken + selectedBlueprintId ? { id: selectedBlueprintId } : skipToken, ); const blueprintImageType = blueprintDetails?.image_requests.map( - (image) => image.image_type + (image) => image.image_type, ); const onSelect = ( _event: React.MouseEvent<Element, MouseEvent>, - itemId: number + itemId: number, ) => { const imageType = blueprintImageType?.[itemId]; if (imageType && deselectedTargets.includes(imageType)) { setDeselectedTargets( - deselectedTargets.filter((target) => target !== imageType) + deselectedTargets.filter((target) => target !== imageType), ); } else if (imageType) { setDeselectedTargets([...deselectedTargets, imageType]); diff --git a/src/Components/Blueprints/DeleteBlueprintModal.tsx b/src/Components/Blueprints/DeleteBlueprintModal.tsx index ca1dcc79..14a27d98 100644 --- a/src/Components/Blueprints/DeleteBlueprintModal.tsx +++ b/src/Components/Blueprints/DeleteBlueprintModal.tsx @@ -67,7 +67,7 @@ export const DeleteBlueprintModal: React.FunctionComponent< selectFromResult: ({ data }) => ({ blueprintName: data?.data.find( (blueprint: { id: string | undefined }) => - blueprint.id === selectedBlueprintId + blueprint.id === selectedBlueprintId, )?.name, }), }); diff --git a/src/Components/Blueprints/ImportBlueprintModal.tsx b/src/Components/Blueprints/ImportBlueprintModal.tsx index 9dfafeca..52b82820 100644 --- a/src/Components/Blueprints/ImportBlueprintModal.tsx +++ b/src/Components/Blueprints/ImportBlueprintModal.tsx @@ -71,19 +71,19 @@ export const ImportBlueprintModal: React.FunctionComponent< const handleFileInputChange = ( _event: React.ChangeEvent<HTMLInputElement> | React.DragEvent<HTMLElement>, - file: File + file: File, ) => { setFileContent(''); setFilename(file.name); }; async function handleRepositoryImport( - blueprintExportedResponse: BlueprintExportResponse + blueprintExportedResponse: BlueprintExportResponse, ): Promise<CustomRepository[] | undefined> { if (isCheckedImportRepos && blueprintExportedResponse.content_sources) { const customRepositories: ApiRepositoryRequest[] = blueprintExportedResponse.content_sources.map( - (item) => item as ApiRepositoryRequest + (item) => item as ApiRepositoryRequest, ); try { @@ -98,7 +98,7 @@ export const ImportBlueprintModal: React.FunctionComponent< repository as ApiRepositoryImportResponseRead; if (contentSourcesRepo.uuid) { newCustomRepos.push( - ...mapToCustomRepositories(contentSourcesRepo) + ...mapToCustomRepositories(contentSourcesRepo), ); } if (repository.warnings?.length === 0 && repository.url) { @@ -139,11 +139,11 @@ export const ImportBlueprintModal: React.FunctionComponent< if (isToml) { const tomlBlueprint = parse(fileContent); const blueprintFromFile = mapOnPremToHosted( - tomlBlueprint as BlueprintItem + tomlBlueprint as BlueprintItem, ); const importBlueprintState = mapExportRequestToState( blueprintFromFile, - [] + [], ); setIsOnPrem(true); setImportedBlueprint(importBlueprintState); @@ -174,7 +174,7 @@ export const ImportBlueprintModal: React.FunctionComponent< undefined; const importBlueprintState = mapExportRequestToState( blueprintExportedResponse, - blueprintFromFile.image_requests || [] + blueprintFromFile.image_requests || [], ); setIsOnPrem(false); @@ -184,7 +184,7 @@ export const ImportBlueprintModal: React.FunctionComponent< mapOnPremToHosted(blueprintFromFile); const importBlueprintState = mapExportRequestToState( blueprintFromFileMapped, - [] + [], ); setIsOnPrem(true); setImportedBlueprint(importBlueprintState); diff --git a/src/Components/Blueprints/helpers/onPremToHostedBlueprintMapper.tsx b/src/Components/Blueprints/helpers/onPremToHostedBlueprintMapper.tsx index fe85b87b..6139d8d2 100644 --- a/src/Components/Blueprints/helpers/onPremToHostedBlueprintMapper.tsx +++ b/src/Components/Blueprints/helpers/onPremToHostedBlueprintMapper.tsx @@ -101,7 +101,7 @@ export type SshKeyOnPrem = { }; export const mapOnPremToHosted = ( - blueprint: BlueprintOnPrem + blueprint: BlueprintOnPrem, ): BlueprintExportResponse => { const users = blueprint.customizations?.user?.map((u) => ({ name: u.name, @@ -132,7 +132,7 @@ export const mapOnPremToHosted = ( ({ baseurls, ...fs }) => ({ baseurl: baseurls, ...fs, - }) + }), ), packages: packages !== undefined || groups !== undefined @@ -147,7 +147,7 @@ export const mapOnPremToHosted = ( ({ minsize, ...fs }) => ({ min_size: minsize, ...fs, - }) + }), ), fips: blueprint.customizations?.fips !== undefined @@ -189,7 +189,7 @@ export const mapOnPremToHosted = ( }; export const mapHostedToOnPrem = ( - blueprint: CreateBlueprintRequest + blueprint: CreateBlueprintRequest, ): CloudApiBlueprint => { const result: CloudApiBlueprint = { name: blueprint.name, @@ -224,7 +224,7 @@ export const mapHostedToOnPrem = ( mountpoint: fs.mountpoint, minsize: fs.min_size, }; - } + }, ); } diff --git a/src/Components/CloudProviderConfig/AWSConfig.tsx b/src/Components/CloudProviderConfig/AWSConfig.tsx index 334021b7..4bd2404d 100644 --- a/src/Components/CloudProviderConfig/AWSConfig.tsx +++ b/src/Components/CloudProviderConfig/AWSConfig.tsx @@ -38,7 +38,7 @@ type ToggleGroupProps = Omit<FormGroupProps<boolean>, 'isDisabled'>; const AWSConfigToggle = ({ value, onChange }: ToggleGroupProps) => { const handleChange = ( _event: React.FormEvent<HTMLInputElement>, - checked: boolean + checked: boolean, ) => { onChange(checked); }; diff --git a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx index a8bfe3af..ed5523a4 100644 --- a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx +++ b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx @@ -97,7 +97,7 @@ export const CloudProviderConfig = () => { dispatch(changeAWSCredsPath(credentials)); } }, - [dispatch, setEnabled] + [dispatch, setEnabled], ); useEffect(() => { diff --git a/src/Components/CloudProviderConfig/validators/index.tsx b/src/Components/CloudProviderConfig/validators/index.tsx index 1503adfe..33918fc7 100644 --- a/src/Components/CloudProviderConfig/validators/index.tsx +++ b/src/Components/CloudProviderConfig/validators/index.tsx @@ -21,7 +21,7 @@ export const isAwsCredsPathValid = (credsPath?: string): boolean => { }; export const isAwsStepValid = ( - config: AWSWorkerConfig | undefined + config: AWSWorkerConfig | undefined, ): boolean => { if (!config) { return true; diff --git a/src/Components/Cockpit/NotReady.tsx b/src/Components/Cockpit/NotReady.tsx index c41d0e61..2d17ff04 100644 --- a/src/Components/Cockpit/NotReady.tsx +++ b/src/Components/Cockpit/NotReady.tsx @@ -30,7 +30,7 @@ export const NotReady = ({ enabled }: { enabled: boolean }) => { { superuser: 'require', err: 'message', - } + }, ) .then(() => window.location.reload()); }} @@ -45,7 +45,7 @@ export const NotReady = ({ enabled }: { enabled: boolean }) => { event.preventDefault(); cockpit.jump( '/system/services#/osbuild-composer.socket', - cockpit.transport.host + cockpit.transport.host, ); }} > diff --git a/src/Components/CreateImageWizard/CreateImageWizard.tsx b/src/Components/CreateImageWizard/CreateImageWizard.tsx index 01f36f0b..c8f93fea 100644 --- a/src/Components/CreateImageWizard/CreateImageWizard.tsx +++ b/src/Components/CreateImageWizard/CreateImageWizard.tsx @@ -309,7 +309,7 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { step: WizardStepType, activeStep: WizardStepType, steps: WizardStepType[], - goToStepByIndex: (index: number) => void + goToStepByIndex: (index: number) => void, ) => { const isVisitOptional = 'parentId' in step && step.parentId === 'step-optional-steps'; @@ -325,7 +325,7 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { }, [step.id, step.isVisited]); const hasVisitedNextStep = steps.some( - (s) => s.index > step.index && s.isVisited + (s) => s.index > step.index && s.isVisited, ); // Only this code is different from the original @@ -353,7 +353,7 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { { module: AMPLITUDE_MODULE_NAME, isPreview: isBeta(), - } + }, ); } }} @@ -389,7 +389,7 @@ const CreateImageWizard = ({ isEdit }: CreateImageWizardProps) => { isHidden={ !targetEnvironments.find( (target: string) => - target === 'aws' || target === 'gcp' || target === 'azure' + target === 'aws' || target === 'gcp' || target === 'azure', ) } steps={[ diff --git a/src/Components/CreateImageWizard/LabelInput.tsx b/src/Components/CreateImageWizard/LabelInput.tsx index 5e3e2dd7..a2796355 100644 --- a/src/Components/CreateImageWizard/LabelInput.tsx +++ b/src/Components/CreateImageWizard/LabelInput.tsx @@ -58,7 +58,7 @@ const LabelInput = ({ const onTextInputChange = ( _event: React.FormEvent<HTMLInputElement>, - value: string + value: string, ) => { setInputValue(value); setOnStepInputErrorText(''); @@ -74,27 +74,27 @@ const LabelInput = ({ switch (fieldName) { case 'ports': setOnStepInputErrorText( - 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp' + 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp', ); break; case 'kernelAppend': setOnStepInputErrorText( - 'Expected format: <kernel-argument>. Example: console=tty0' + 'Expected format: <kernel-argument>. Example: console=tty0', ); break; case 'kernelName': setOnStepInputErrorText( - 'Expected format: <kernel-name>. Example: kernel-5.14.0-284.11.1.el9_2.x86_64' + 'Expected format: <kernel-name>. Example: kernel-5.14.0-284.11.1.el9_2.x86_64', ); break; case 'groups': setOnStepInputErrorText( - 'Expected format: <group-name>. Example: admin' + 'Expected format: <group-name>. Example: admin', ); break; case 'ntpServers': setOnStepInputErrorText( - 'Expected format: <ntp-server>. Example: time.redhat.com' + 'Expected format: <ntp-server>. Example: time.redhat.com', ); break; case 'enabledSystemdServices': @@ -103,7 +103,7 @@ const LabelInput = ({ case 'disabledServices': case 'enabledServices': setOnStepInputErrorText( - 'Expected format: <service-name>. Example: sshd' + 'Expected format: <service-name>. Example: sshd', ); break; default: diff --git a/src/Components/CreateImageWizard/ValidatedInput.tsx b/src/Components/CreateImageWizard/ValidatedInput.tsx index 271898a9..e893a1a2 100644 --- a/src/Components/CreateImageWizard/ValidatedInput.tsx +++ b/src/Components/CreateImageWizard/ValidatedInput.tsx @@ -31,7 +31,7 @@ type ValidationInputProp = TextInputProps & ariaLabel: string; onChange: ( event: React.FormEvent<HTMLInputElement | HTMLTextAreaElement>, - value: string + value: string, ) => void; isRequired?: boolean; warning?: string; @@ -111,7 +111,7 @@ export const ValidatedInputAndTextArea = ({ const getValidationState = ( isPristine: boolean, errorMessage: string, - isRequired: boolean | undefined + isRequired: boolean | undefined, ): ValidationResult => { const validated = isPristine ? 'default' diff --git a/src/Components/CreateImageWizard/steps/Details/index.tsx b/src/Components/CreateImageWizard/steps/Details/index.tsx index 0e19316b..127595af 100644 --- a/src/Components/CreateImageWizard/steps/Details/index.tsx +++ b/src/Components/CreateImageWizard/steps/Details/index.tsx @@ -28,7 +28,7 @@ const DetailsStep = () => { const handleNameChange = ( _event: React.FormEvent<HTMLInputElement | HTMLTextAreaElement>, - name: string + name: string, ) => { dispatch(changeBlueprintName(name)); dispatch(setIsCustomName()); @@ -36,7 +36,7 @@ const DetailsStep = () => { const handleDescriptionChange = ( _event: React.FormEvent<HTMLInputElement | HTMLTextAreaElement>, - description: string + description: string, ) => { dispatch(changeBlueprintDescription(description)); }; diff --git a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx index 763577dd..e042bb81 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx @@ -38,7 +38,7 @@ const FileSystemConfiguration = () => { mountpoint: '/home', min_size: '1', unit: 'GiB', - }) + }), ); }; @@ -49,7 +49,7 @@ const FileSystemConfiguration = () => { const filteredTargets = ( automaticPartitioningOnlyTargets.filter((env) => - environments.includes(env) + environments.includes(env), ) as ImageTypes[] ).map((env) => targetOptions[env]); @@ -59,7 +59,7 @@ const FileSystemConfiguration = () => { <Content component={ContentVariants.h3}>Configure partitions</Content> </Content> {partitions.find((partition) => - partition.mountpoint.includes('/usr') + partition.mountpoint.includes('/usr'), ) && <UsrSubDirectoriesDisabled />} <Content> <Content> @@ -90,7 +90,7 @@ const FileSystemConfiguration = () => { variant="warning" isInline title={`Filesystem customizations are not applied to ${filteredTargets.join( - ' and ' + ' and ', )} images`} /> )} diff --git a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemPartition.tsx b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemPartition.tsx index 8d24a3dd..8f8647a8 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemPartition.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemPartition.tsx @@ -12,7 +12,7 @@ import { const FileSystemPartition = () => { const dispatch = useAppDispatch(); const fileSystemConfigurationType = useAppSelector( - selectFileSystemConfigurationType + selectFileSystemConfigurationType, ); const hasOscapProfile = useAppSelector(selectComplianceProfileID); diff --git a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx index 4e269537..b4adb712 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemTable.tsx @@ -180,7 +180,7 @@ const MountpointPrefix = ({ partition }: MountpointPrefixPropTypes) => { setIsOpen(false); const mountpoint = selection + (suffix.length > 0 ? '/' + suffix : ''); dispatch( - changePartitionMountpoint({ id: partition.id, mountpoint: mountpoint }) + changePartitionMountpoint({ id: partition.id, mountpoint: mountpoint }), ); }; @@ -241,7 +241,7 @@ const MountpointSuffix = ({ partition }: MountpointSuffixPropTypes) => { changePartitionMountpoint({ id: partition.id, mountpoint: mountpoint, - }) + }), ); }} aria-label="mountpoint suffix" @@ -292,10 +292,10 @@ const MinimumSize = ({ partition }: MinimumSizePropTypes) => { changePartitionMinSize({ id: partition.id, min_size: minSize, - }) + }), ); dispatch( - changePartitionUnit({ id: partition.id, unit: partition.unit }) + changePartitionUnit({ id: partition.id, unit: partition.unit }), ); } }} @@ -319,7 +319,7 @@ const SizeUnit = ({ partition }: SizeUnitPropTypes) => { changePartitionMinSize({ id: partition.id, min_size: initialValue.min_size, - }) + }), ); } dispatch(changePartitionUnit({ id: partition.id, unit: selection })); @@ -364,7 +364,7 @@ const SizeUnit = ({ partition }: SizeUnitPropTypes) => { const FileSystemTable = () => { const [draggedItemId, setDraggedItemId] = useState<string | null>(null); const [draggingToItemIndex, setDraggingToItemIndex] = useState<number | null>( - null + null, ); const [isDragging, setIsDragging] = useState(false); const [tempItemOrder, setTempItemOrder] = useState<string[]>([]); @@ -374,7 +374,7 @@ const FileSystemTable = () => { const itemOrder = partitions.map((partition) => partition.id); const dispatch = useAppDispatch(); const isValidDrop = ( - evt: React.DragEvent<HTMLTableSectionElement | HTMLTableRowElement> + evt: React.DragEvent<HTMLTableSectionElement | HTMLTableRowElement>, ) => { const ulRect = bodyRef.current?.getBoundingClientRect(); if (!ulRect) return false; @@ -439,13 +439,13 @@ const FileSystemTable = () => { } const dragId = curListItem.id; const newDraggingToItemIndex = Array.from( - bodyRef.current.children + bodyRef.current.children, ).findIndex((item) => item.id === dragId); if (newDraggingToItemIndex !== draggingToItemIndex && draggedItemId) { const tempItemOrder = moveItem( [...itemOrder], draggedItemId, - newDraggingToItemIndex + newDraggingToItemIndex, ); move(tempItemOrder); setDraggingToItemIndex(newDraggingToItemIndex); diff --git a/src/Components/CreateImageWizard/steps/FileSystem/index.tsx b/src/Components/CreateImageWizard/steps/FileSystem/index.tsx index 39b3fb0d..ddc8ced4 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/index.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/index.tsx @@ -14,7 +14,7 @@ export type FileSystemConfigurationType = 'automatic' | 'manual'; const FileSystemStep = () => { const fileSystemConfigurationType = useAppSelector( - selectFileSystemConfigurationType + selectFileSystemConfigurationType, ); const hasIsoTargetOnly = useHasSpecificTargetOnly('image-installer'); diff --git a/src/Components/CreateImageWizard/steps/ImageOutput/components/ArchSelect.tsx b/src/Components/CreateImageWizard/steps/ImageOutput/components/ArchSelect.tsx index 24ea739e..3d775989 100644 --- a/src/Components/CreateImageWizard/steps/ImageOutput/components/ArchSelect.tsx +++ b/src/Components/CreateImageWizard/steps/ImageOutput/components/ArchSelect.tsx @@ -24,7 +24,7 @@ const ArchSelect = () => { const setArch = ( _event: React.MouseEvent, - selection: ImageRequest['architecture'] + selection: ImageRequest['architecture'], ) => { dispatch(changeArchitecture(selection)); setIsOpen(false); @@ -44,7 +44,7 @@ const ArchSelect = () => { options.push( <SelectOption key={arch} value={arch}> {arch} - </SelectOption> + </SelectOption>, ); }); diff --git a/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx b/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx index fc0e3164..2b0adb3d 100644 --- a/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx +++ b/src/Components/CreateImageWizard/steps/ImageOutput/components/ReleaseSelect.tsx @@ -100,7 +100,7 @@ const ReleaseSelect = () => { return true; } return isRhel(key); - }) + }), ); filteredRhel.forEach((value, key) => { @@ -111,7 +111,7 @@ const ReleaseSelect = () => { description={setDescription(key as Distributions)} > {releases.get(key)} - </SelectOption> + </SelectOption>, ); }); diff --git a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx index 2d98e3f7..6b09c8dd 100644 --- a/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx +++ b/src/Components/CreateImageWizard/steps/ImageOutput/components/TargetEnvironment.tsx @@ -111,7 +111,7 @@ const TargetEnvironment = () => { }, []); const supportedEnvironments = data?.find( - (elem) => elem.arch === arch + (elem) => elem.arch === arch, )?.image_types; const handleToggleEnvironment = (environment: ImageTypes) => { diff --git a/src/Components/CreateImageWizard/steps/Kernel/components/KernelArguments.tsx b/src/Components/CreateImageWizard/steps/Kernel/components/KernelArguments.tsx index 042a9a86..24e85ddf 100644 --- a/src/Components/CreateImageWizard/steps/Kernel/components/KernelArguments.tsx +++ b/src/Components/CreateImageWizard/steps/Kernel/components/KernelArguments.tsx @@ -31,11 +31,11 @@ const KernelArguments = () => { }, { skip: !complianceProfileID, - } + }, ); const requiredByOpenSCAP = kernelAppend.filter((arg) => - oscapProfileInfo?.kernel?.append?.split(' ').includes(arg) + oscapProfileInfo?.kernel?.append?.split(' ').includes(arg), ); return ( diff --git a/src/Components/CreateImageWizard/steps/Kernel/components/KernelName.tsx b/src/Components/CreateImageWizard/steps/Kernel/components/KernelName.tsx index 06b6d42b..e99084b0 100644 --- a/src/Components/CreateImageWizard/steps/Kernel/components/KernelName.tsx +++ b/src/Components/CreateImageWizard/steps/Kernel/components/KernelName.tsx @@ -44,7 +44,7 @@ const KernelName = () => { if (filterValue) { filteredKernelPkgs = kernelOptions.filter((kernel: string) => - String(kernel).toLowerCase().includes(filterValue.toLowerCase()) + String(kernel).toLowerCase().includes(filterValue.toLowerCase()), ); if (!filteredKernelPkgs.some((kernel) => kernel === filterValue)) { filteredKernelPkgs = [ diff --git a/src/Components/CreateImageWizard/steps/Locale/components/KeyboardDropDown.tsx b/src/Components/CreateImageWizard/steps/Locale/components/KeyboardDropDown.tsx index 1eada1ab..d3d04387 100644 --- a/src/Components/CreateImageWizard/steps/Locale/components/KeyboardDropDown.tsx +++ b/src/Components/CreateImageWizard/steps/Locale/components/KeyboardDropDown.tsx @@ -42,14 +42,14 @@ const KeyboardDropDown = () => { if (filterValue) { filteredKeyboards = keyboardsList.filter((keyboard: string) => - String(keyboard).toLowerCase().includes(filterValue.toLowerCase()) + String(keyboard).toLowerCase().includes(filterValue.toLowerCase()), ); if (!isOpen) { setIsOpen(true); } } setSelectOptions( - filteredKeyboards.sort((a, b) => sortfn(a, b, filterValue)) + filteredKeyboards.sort((a, b) => sortfn(a, b, filterValue)), ); // This useEffect hook should run *only* on when the filter value changes. diff --git a/src/Components/CreateImageWizard/steps/Locale/components/LanguagesDropDown.tsx b/src/Components/CreateImageWizard/steps/Locale/components/LanguagesDropDown.tsx index 938fecaa..fa02afaf 100644 --- a/src/Components/CreateImageWizard/steps/Locale/components/LanguagesDropDown.tsx +++ b/src/Components/CreateImageWizard/steps/Locale/components/LanguagesDropDown.tsx @@ -37,7 +37,7 @@ const parseLanguageOption = (language: string) => { type: 'language', }).of(languageCode); const countryName = new Intl.DisplayNames(['en'], { type: 'region' }).of( - countryCode + countryCode, ); return `${languageName} - ${countryName} (${language})`; @@ -72,7 +72,7 @@ const LanguagesDropDown = () => { if (filterValue) { filteredLanguages = filteredLanguages.filter(([, parsed]) => - String(parsed).toLowerCase().includes(filterValue.toLowerCase()) + String(parsed).toLowerCase().includes(filterValue.toLowerCase()), ); if (!isOpen) { setIsOpen(true); @@ -81,7 +81,7 @@ const LanguagesDropDown = () => { setSelectOptions( filteredLanguages .sort((a, b) => sortfn(a[1], b[1], filterValue)) - .map(([raw]) => raw) + .map(([raw]) => raw), ); // This useEffect hook should run *only* on when the filter value changes. @@ -194,7 +194,7 @@ const LanguagesDropDown = () => { <HelperTextItem variant={'error'} >{`Unknown languages: ${unknownLanguages.join( - ', ' + ', ', )}`}</HelperTextItem> </HelperText> )} diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/OscapProfileInformation.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/OscapProfileInformation.tsx index 8ecde737..47b3d578 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/OscapProfileInformation.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/OscapProfileInformation.tsx @@ -43,7 +43,7 @@ export const OscapProfileInformation = ({ }, { skip: !complianceProfileID, - } + }, ); const { @@ -57,7 +57,7 @@ export const OscapProfileInformation = ({ { skip: !allowChangingCompliancePolicy || complianceProfileID ? true : false, - } + }, ); useEffect(() => { @@ -70,7 +70,7 @@ export const OscapProfileInformation = ({ policyID: pol.id, profileID: pol.ref_id, policyTitle: pol.title, - }) + }), ); }, [isSuccessPolicyInfo]); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx index 25586d37..a5785dc5 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/PolicySelector.tsx @@ -45,7 +45,7 @@ const ComplianceSelectOption = ({ policy }: ComplianceSelectOptionPropType) => { const selectObj = ( policyID: string, profileID: string, - title: string + title: string, ): ComplianceSelectOptionValueType => ({ policyID, profileID, @@ -101,7 +101,7 @@ const PolicySelector = () => { distribution: release, policy: policyID!, }, - { skip: !policyID } + { skip: !policyID }, ); const [trigger] = useLazyGetOscapCustomizationsForPolicyQuery(); @@ -120,7 +120,7 @@ const PolicySelector = () => { policyID: pol.id, profileID: pol.ref_id, policyTitle: pol.title, - }) + }), ); } } @@ -137,7 +137,7 @@ const PolicySelector = () => { profileID: undefined, policyID: undefined, policyTitle: undefined, - }) + }), ); clearCompliancePackages(currentProfileData?.packages || []); dispatch(changeFileSystemConfigurationType('automatic')); @@ -156,7 +156,7 @@ const PolicySelector = () => { distribution: release, policy: selection.policyID, }, - true // preferCacheValue + true, // preferCacheValue ) .unwrap() .then((response) => { @@ -166,7 +166,7 @@ const PolicySelector = () => { handlePackages( oldOscapPackages, newOscapPackages, - 'Required by chosen compliance policy' + 'Required by chosen compliance policy', ); handleServices(response.services); handleKernelAppend(response.kernel?.append); @@ -175,7 +175,7 @@ const PolicySelector = () => { profileID: selection.profileID, policyID: selection.policyID, policyTitle: selection.title, - }) + }), ); }); } @@ -183,7 +183,7 @@ const PolicySelector = () => { const handleSelect = ( _event: React.MouseEvent<Element, MouseEvent>, - selection: string + selection: string, ) => { if (selection) { applyChanges(selection as unknown as ComplianceSelectOptionValueType); diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx index 7af83590..a90ab809 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/ProfileSelector.tsx @@ -94,7 +94,7 @@ const ProfileSelector = () => { // @ts-ignore if openScapProfile is undefined the query is going to get skipped profile: profileID, }, - { skip: !profileID } + { skip: !profileID }, ); const [trigger] = useLazyGetOscapCustomizationsQuery(); @@ -118,7 +118,7 @@ const ProfileSelector = () => { const promises = profiles.map(async (profileID) => { const response = await trigger( { distribution: release, profile: profileID }, - true + true, ).unwrap(); const oscap = response?.openscap; @@ -153,7 +153,7 @@ const ProfileSelector = () => { } const trimmedFilter = filterValue.toLowerCase().trim(); const filtered = profileDetails.filter(({ name }) => - name?.toLowerCase().includes(trimmedFilter) + name?.toLowerCase().includes(trimmedFilter), ); setSelectOptions(filtered); @@ -175,7 +175,7 @@ const ProfileSelector = () => { profileID: undefined, policyID: undefined, policyTitle: undefined, - }) + }), ); clearCompliancePackages(currentProfileData?.packages || []); dispatch(changeFileSystemConfigurationType('automatic')); @@ -203,7 +203,7 @@ const ProfileSelector = () => { profileID: undefined, policyID: undefined, policyTitle: undefined, - }) + }), ); } }; @@ -240,7 +240,7 @@ const ProfileSelector = () => { distribution: release, profile: selection.profileID as DistributionProfileItem, }, - true // preferCacheValue + true, // preferCacheValue ) .unwrap() .then((response) => { @@ -250,7 +250,7 @@ const ProfileSelector = () => { handlePackages( oldOscapPackages, newOscapPackages, - 'Required by chosen OpenSCAP profile' + 'Required by chosen OpenSCAP profile', ); handleServices(response.services); handleKernelAppend(response.kernel?.append); @@ -259,7 +259,7 @@ const ProfileSelector = () => { profileID: selection.profileID, policyID: undefined, policyTitle: undefined, - }) + }), ); }); } @@ -267,7 +267,7 @@ const ProfileSelector = () => { const handleSelect = ( _event: React.MouseEvent<Element, MouseEvent>, - selection: string + selection: string, ) => { if (selection) { setInputValue(selection); @@ -356,7 +356,7 @@ const ProfileSelector = () => { > {name} </SelectOption> - )) + )), )} {isSuccess && selectOptions.length === 0 && ( <SelectOption isDisabled> diff --git a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx index 53fb74f1..1496f5d6 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/components/useSelectorHandlers.tsx @@ -40,7 +40,7 @@ export const useSelectorHandlers = () => { const handlePackages = ( oldOscapPackages: string[], newOscapPackages: string[], - reason: string + reason: string, ) => { clearCompliancePackages(oldOscapPackages); @@ -50,7 +50,7 @@ export const useSelectorHandlers = () => { name: pkg, summary: reason, repository: 'distro', - }) + }), ); } }; diff --git a/src/Components/CreateImageWizard/steps/Oscap/index.tsx b/src/Components/CreateImageWizard/steps/Oscap/index.tsx index 7dcfe331..4b50145f 100644 --- a/src/Components/CreateImageWizard/steps/Oscap/index.tsx +++ b/src/Components/CreateImageWizard/steps/Oscap/index.tsx @@ -56,7 +56,7 @@ const OscapContent = () => { // @ts-ignore if openScapProfile is undefined the query is going to get skipped profile: profileID, }, - { skip: !profileID } + { skip: !profileID }, ); useEffect(() => { @@ -76,7 +76,7 @@ const OscapContent = () => { profileID: undefined, policyID: undefined, policyTitle: undefined, - }) + }), ); const pkgs = currentProfileData?.packages || []; for (const pkg of pkgs) { @@ -102,7 +102,7 @@ const OscapContent = () => { }, { skip: complianceType === 'openscap', - } + }, ); return ( diff --git a/src/Components/CreateImageWizard/steps/Packages/PackageRecommendations.tsx b/src/Components/CreateImageWizard/steps/Packages/PackageRecommendations.tsx index fc5fdea6..cfeb4ba3 100644 --- a/src/Components/CreateImageWizard/steps/Packages/PackageRecommendations.tsx +++ b/src/Components/CreateImageWizard/steps/Packages/PackageRecommendations.tsx @@ -101,7 +101,7 @@ const PackageRecommendations = () => { selectedPackages: packages.map((pkg) => pkg.name), distribution: distribution.replace('-', ''), modelVersion: response.data.modelVersion, - } + }, ); } })(); @@ -127,8 +127,8 @@ const PackageRecommendations = () => { name: pkg, summary: 'Added from recommended packages', repository: 'distro', - }) - ) + }), + ), ); } }; @@ -139,7 +139,7 @@ const PackageRecommendations = () => { name: pkg, summary: 'Added from recommended packages', repository: 'distro', - }) + }), ); }; @@ -264,12 +264,12 @@ const PackageRecommendations = () => { isPreview: isBeta(), packageName: pkg, selectedPackages: packages.map( - (pkg) => pkg.name + (pkg) => pkg.name, ), shownRecommendations: data.packages, distribution: distribution.replace('-', ''), modelVersion: data.modelVersion, - } + }, ); addRecommendedPackage(pkg); }} diff --git a/src/Components/CreateImageWizard/steps/Packages/Packages.tsx b/src/Components/CreateImageWizard/steps/Packages/Packages.tsx index 58e186fe..eef1c864 100644 --- a/src/Components/CreateImageWizard/steps/Packages/Packages.tsx +++ b/src/Components/CreateImageWizard/steps/Packages/Packages.tsx @@ -294,7 +294,7 @@ const Packages = () => { : reposInTemplate .filter((r) => r.org_id === '-1' && !!r.url) .flatMap((r) => - r.url!.endsWith('/') ? r.url!.slice(0, -1) : r.url! + r.url!.endsWith('/') ? r.url!.slice(0, -1) : r.url!, ), limit: 500, include_package_sources: true, @@ -679,7 +679,7 @@ const Packages = () => { } let combinedPackageData = transformedDistroData.concat( - transformedCustomData + transformedCustomData, ); if ( @@ -696,7 +696,7 @@ const Packages = () => { })); combinedPackageData = combinedPackageData.concat( - transformedRecommendedData + transformedRecommendedData, ); } @@ -772,7 +772,7 @@ const Packages = () => { description: values.description!, repository: 'distro', package_list: values.package_list!, - })) + })), ); } if (isSuccessCustomGroups) { @@ -782,7 +782,7 @@ const Packages = () => { description: values.description!, repository: 'custom', package_list: values.package_list!, - })) + })), ); } if (isSuccessRecommendedGroups) { @@ -792,18 +792,18 @@ const Packages = () => { description: values.description!, repository: 'recommended', package_list: values.package_list!, - })) + })), ); } if (toggleSelected === 'toggle-available') { if (activeTabKey === Repos.INCLUDED) { return combinedGroupData.filter( - (pkg) => pkg.repository !== 'recommended' + (pkg) => pkg.repository !== 'recommended', ); } else { return combinedGroupData.filter( - (pkg) => pkg.repository === 'recommended' + (pkg) => pkg.repository === 'recommended', ); } } else { @@ -829,7 +829,7 @@ const Packages = () => { const handleSearch = async ( event: React.FormEvent<HTMLInputElement>, - selection: string + selection: string, ) => { setSearchTerm(selection); setActiveTabKey(Repos.INCLUDED); @@ -851,7 +851,7 @@ const Packages = () => { const handleSelect = ( pkg: IBPackageWithRepositoryInfo, _: number, - isSelecting: boolean + isSelecting: boolean, ) => { if (isSelecting) { if ( @@ -872,11 +872,11 @@ const Packages = () => { addModule({ name: pkg.module_name || '', stream: pkg.stream || '', - }) + }), ); } setCurrentlyRemovedPackages((prev) => - prev.filter((curr) => curr.name !== pkg.name) + prev.filter((curr) => curr.name !== pkg.name), ); } } else { @@ -900,7 +900,7 @@ const Packages = () => { const handleGroupSelect = ( grp: GroupWithRepositoryInfo, _: number, - isSelecting: boolean + isSelecting: boolean, ) => { if (isSelecting) { if ( @@ -941,7 +941,7 @@ const Packages = () => { const handlePerPageSelect = ( _: React.MouseEvent, newPerPage: number, - newPage: number + newPage: number, ) => { setPerPage(newPerPage); setPage(newPage); @@ -958,7 +958,7 @@ const Packages = () => { const handleConfirmModalToggle = async () => { if (!epelRepo || !epelRepo.data) { throw new Error( - `There was an error while adding the recommended repository.` + `There was an error while adding the recommended repository.`, ); } @@ -970,8 +970,8 @@ const Packages = () => { }); dispatch( addRecommendedRepository( - (result as { data: ApiRepositoryResponseRead }).data - ) + (result as { data: ApiRepositoryResponseRead }).data, + ), ); } else { dispatch(addRecommendedRepository(epelRepo.data[0])); @@ -998,7 +998,7 @@ const Packages = () => { const setPkgExpanded = ( pkg: IBPackageWithRepositoryInfo, - isExpanding: boolean + isExpanding: boolean, ) => setExpandedPkgs((prevExpanded) => { const otherExpandedPkgs = prevExpanded.filter((p) => p.name !== pkg.name); @@ -1013,7 +1013,7 @@ const Packages = () => { const setGroupsExpanded = ( group: GroupWithRepositoryInfo['name'], - isExpanding: boolean + isExpanding: boolean, ) => setExpandedGroups((prevExpanded) => { const otherExpandedGroups = prevExpanded.filter((g) => g !== group); @@ -1031,7 +1031,7 @@ const Packages = () => { >('asc'); const getSortableRowValues = ( - pkg: IBPackageWithRepositoryInfo + pkg: IBPackageWithRepositoryInfo, ): (string | number | ApiPackageSourcesResponse[] | undefined)[] => { return [pkg.name, pkg.summary, pkg.stream, pkg.end_date, pkg.repository]; }; @@ -1084,7 +1084,7 @@ const Packages = () => { onSort: ( _event: React.MouseEvent, index: number, - direction: 'asc' | 'desc' + direction: 'asc' | 'desc', ) => { setActiveSortIndex(index); setActiveSortDirection(direction); @@ -1097,7 +1097,7 @@ const Packages = () => { if (!pkg.type || pkg.type === 'package') { const isModuleWithSameName = modules.some( - (module) => module.name === pkg.name + (module) => module.name === pkg.name, ); isSelected = packages.some((p) => p.name === pkg.name) && !isModuleWithSameName; @@ -1109,7 +1109,7 @@ const Packages = () => { isSelected = packages.some((p) => p.name === pkg.name) && modules.some( - (m) => m.name === pkg.module_name && m.stream === pkg.stream + (m) => m.name === pkg.module_name && m.stream === pkg.stream, ); } @@ -1131,7 +1131,7 @@ const Packages = () => { const isModuleDisabledByPackage = pkg.type === 'module' && packages.some( - (p) => (!p.type || p.type === 'package') && p.name === pkg.module_name + (p) => (!p.type || p.type === 'package') && p.name === pkg.module_name, ); const isPackageDisabledByModule = @@ -1160,7 +1160,7 @@ const Packages = () => { const currentDate = new Date(); const msPerDay = 1000 * 60 * 60 * 24; const differenceInDays = Math.round( - (retirementDate.getTime() - currentDate.getTime()) / msPerDay + (retirementDate.getTime() - currentDate.getTime()) / msPerDay, ); let icon; @@ -1298,7 +1298,7 @@ const Packages = () => { </Td> </Tr> </Tbody> - )) + )), ); } @@ -1360,7 +1360,7 @@ const Packages = () => { </Td> </Tr> </Tbody> - )) + )), ); } return rows; diff --git a/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeyInformation.tsx b/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeyInformation.tsx index 12aea39a..49e4bf90 100644 --- a/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeyInformation.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeyInformation.tsx @@ -27,7 +27,7 @@ const ActivationKeyInformation = (): JSX.Element => { { name: activationKey! }, { skip: !activationKey, - } + }, ); return ( @@ -100,7 +100,7 @@ const ActivationKeyInformation = (): JSX.Element => { <Tr key={index}> <Td>{repo.repositoryLabel}</Td> </Tr> - ) + ), )} </Tbody> </Table> diff --git a/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeysList.tsx b/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeysList.tsx index 4a2b27d8..c224198b 100644 --- a/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeysList.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/components/ActivationKeysList.tsx @@ -62,7 +62,7 @@ const ActivationKeysList = () => { useCreateActivationKeysMutation(); const recentActivationKey = window.localStorage.getItem( - 'imageBuilder.recentActivationKey' + 'imageBuilder.recentActivationKey', ); useEffect(() => { @@ -76,7 +76,7 @@ const ActivationKeysList = () => { }, [dispatch, isProd]); const [selectOptions, setSelectOptions] = useState<(string | undefined)[]>( - activationKeys?.body ? activationKeys.body.map((key) => key.name) : [] + activationKeys?.body ? activationKeys.body.map((key) => key.name) : [], ); useEffect(() => { @@ -86,7 +86,7 @@ const ActivationKeysList = () => { filteredKeys = activationKeys?.body ?.map((key) => key.name) .filter((keyName: string) => - String(keyName).toLowerCase().includes(filterValue.toLowerCase()) + String(keyName).toLowerCase().includes(filterValue.toLowerCase()), ); if (!isOpen) { setIsOpen(true); @@ -120,7 +120,7 @@ const ActivationKeysList = () => { window.localStorage.setItem( 'imageBuilder.recentActivationKey', - defaultActivationKeyName + defaultActivationKeyName, ); dispatch(changeActivationKey(defaultActivationKeyName)); } catch (error) { @@ -200,8 +200,8 @@ const ActivationKeysList = () => { selectOptionsElement.push( <SelectOption key={index} value={key}> {key} - </SelectOption> - ) + </SelectOption>, + ), ); } @@ -209,7 +209,7 @@ const ActivationKeysList = () => { selectOptionsElement.push( <SelectOption key="Fetching" value="loader"> <Spinner size="md" /> - </SelectOption> + </SelectOption>, ); } @@ -217,7 +217,7 @@ const ActivationKeysList = () => { selectOptionsElement.push( <SelectOption key="no_results" value="no_results" isDisabled> No results found - </SelectOption> + </SelectOption>, ); } diff --git a/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx b/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx index 3d8acf53..9be52f71 100644 --- a/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/components/Registration.tsx @@ -100,11 +100,11 @@ const Registration = () => { const registrationType = useAppSelector(selectRegistrationType); const [showOptions, setShowOptions] = useState( - registrationType === 'register-later' + registrationType === 'register-later', ); const isSatelliteRegistrationEnabled = useFlag( - 'image-builder.satellite.enabled' + 'image-builder.satellite.enabled', ); return ( diff --git a/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx b/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx index be224058..179d898e 100644 --- a/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistration.tsx @@ -34,7 +34,7 @@ const SatelliteRegistration = () => { const handleTextChange = ( _event: React.ChangeEvent<HTMLTextAreaElement>, - value: string + value: string, ) => { dispatch(changeSatelliteCaCertificate(value)); }; diff --git a/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistrationCommand.tsx b/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistrationCommand.tsx index 8683e6f2..c7882a4a 100644 --- a/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistrationCommand.tsx +++ b/src/Components/CreateImageWizard/steps/Registration/components/SatelliteRegistrationCommand.tsx @@ -21,7 +21,7 @@ import { ValidatedInputAndTextArea } from '../../../ValidatedInput'; const SatelliteRegistrationCommand = () => { const dispatch = useAppDispatch(); const registrationCommand = useAppSelector( - selectSatelliteRegistrationCommand + selectSatelliteRegistrationCommand, ); const stepValidation = useRegistrationValidation(); const registrationDocs = diff --git a/src/Components/CreateImageWizard/steps/Repositories/Repositories.tsx b/src/Components/CreateImageWizard/steps/Repositories/Repositories.tsx index 55f6c06b..ef84a986 100644 --- a/src/Components/CreateImageWizard/steps/Repositories/Repositories.tsx +++ b/src/Components/CreateImageWizard/steps/Repositories/Repositories.tsx @@ -99,7 +99,7 @@ const Repositories = () => { } const archParam = repositoryParameters.distribution_arches.find( - (arch) => arch.label === technicalArch + (arch) => arch.label === technicalArch, ); return archParam?.name || technicalArch; @@ -112,7 +112,7 @@ const Repositories = () => { const readableVersions = technicalVersions.map((version) => { const versionParam = repositoryParameters.distribution_versions?.find( - (v) => v.label === version + (v) => v.label === version, ); return versionParam?.name || version; }); @@ -127,9 +127,9 @@ const Repositories = () => { ...customRepositories.map(({ id }) => id).flat(1), ...payloadRepositories.map(({ id }) => id), ...recommendedRepos.map(({ uuid }) => uuid), - ].filter((id) => !!id) as string[] + ].filter((id) => !!id) as string[], ), - [customRepositories, payloadRepositories, recommendedRepos] + [customRepositories, payloadRepositories, recommendedRepos], ); // eslint-disable-next-line react-hooks/exhaustive-deps @@ -149,7 +149,7 @@ const Repositories = () => { offset: 0, uuid: [...initialSelectedState].join(','), }, - { refetchOnMountOrArgChange: false, skip: isTemplateSelected } + { refetchOnMountOrArgChange: false, skip: isTemplateSelected }, ); useEffect(() => { @@ -182,7 +182,7 @@ const Repositories = () => { ? [...selected].join(',') : '', }, - { refetchOnMountOrArgChange: 60, skip: isTemplateSelected } + { refetchOnMountOrArgChange: 60, skip: isTemplateSelected }, ); const refresh = () => { @@ -193,7 +193,7 @@ const Repositories = () => { }; const addSelected = ( - repo: ApiRepositoryResponseRead | ApiRepositoryResponseRead[] + repo: ApiRepositoryResponseRead | ApiRepositoryResponseRead[], ) => { let reposToAdd: ApiRepositoryResponseRead[] = []; // Check if array of items @@ -202,7 +202,7 @@ const Repositories = () => { (r) => r.uuid && !isRepoDisabled(r, selected.has(r.uuid))[0] && - !selected.has(r.uuid) + !selected.has(r.uuid), ); } else { // Then it should be a single item @@ -217,25 +217,25 @@ const Repositories = () => { } const customToAdd = reposToAdd.map((repo) => - convertSchemaToIBCustomRepo(repo!) + convertSchemaToIBCustomRepo(repo!), ); const payloadToAdd = reposToAdd.map((repo) => - convertSchemaToIBPayloadRepo(repo!) + convertSchemaToIBPayloadRepo(repo!), ); dispatch(changeCustomRepositories([...customRepositories, ...customToAdd])); dispatch( - changePayloadRepositories([...payloadRepositories, ...payloadToAdd]) + changePayloadRepositories([...payloadRepositories, ...payloadToAdd]), ); }; const clearSelected = () => { const recommendedReposSet = new Set( - recommendedRepos.map(({ uuid }) => uuid) + recommendedRepos.map(({ uuid }) => uuid), ); const initiallySelected = [...selected].some( - (uuid) => uuid && initialSelectedState.has(uuid) + (uuid) => uuid && initialSelectedState.has(uuid), ); if (initiallySelected) { @@ -246,34 +246,34 @@ const Repositories = () => { dispatch( changeCustomRepositories( - customRepositories.filter(({ id }) => recommendedReposSet.has(id)) - ) + customRepositories.filter(({ id }) => recommendedReposSet.has(id)), + ), ); dispatch( changePayloadRepositories( - payloadRepositories.filter(({ id }) => recommendedReposSet.has(id)) - ) + payloadRepositories.filter(({ id }) => recommendedReposSet.has(id)), + ), ); }; const removeSelected = ( - repo: ApiRepositoryResponseRead | ApiRepositoryResponseRead[] + repo: ApiRepositoryResponseRead | ApiRepositoryResponseRead[], ) => { if ((repo as ApiRepositoryResponseRead[])?.length) { const itemsToRemove = new Set( - (repo as ApiRepositoryResponseRead[]).map(({ uuid }) => uuid) + (repo as ApiRepositoryResponseRead[]).map(({ uuid }) => uuid), ); dispatch( changeCustomRepositories( - customRepositories.filter(({ id }) => !itemsToRemove.has(id)) - ) + customRepositories.filter(({ id }) => !itemsToRemove.has(id)), + ), ); dispatch( changePayloadRepositories( - payloadRepositories.filter(({ id }) => !itemsToRemove.has(id)) - ) + payloadRepositories.filter(({ id }) => !itemsToRemove.has(id)), + ), ); return; @@ -283,29 +283,29 @@ const Repositories = () => { if (uuidToRemove) { dispatch( changeCustomRepositories( - customRepositories.filter(({ id }) => uuidToRemove !== id) - ) + customRepositories.filter(({ id }) => uuidToRemove !== id), + ), ); dispatch( changePayloadRepositories( - payloadRepositories.filter(({ id }) => uuidToRemove !== id) - ) + payloadRepositories.filter(({ id }) => uuidToRemove !== id), + ), ); } }; const handleAddRemove = ( repo: ApiRepositoryResponseRead | ApiRepositoryResponseRead[], - selected: boolean + selected: boolean, ) => { if (selected) return addSelected(repo); if ((repo as ApiRepositoryResponseRead[])?.length) { const initiallySelectedItems = (repo as ApiRepositoryResponseRead[]).map( - ({ uuid }) => uuid + ({ uuid }) => uuid, ); const hasSome = initiallySelectedItems.some( - (uuid) => uuid && initialSelectedState.has(uuid) + (uuid) => uuid && initialSelectedState.has(uuid), ); if (hasSome) { @@ -317,7 +317,7 @@ const Repositories = () => { const isInitiallySelected = (repo as ApiRepositoryResponseRead).uuid && initialSelectedState.has( - (repo as ApiRepositoryResponseRead).uuid || '' + (repo as ApiRepositoryResponseRead).uuid || '', ); if (isInitiallySelected) { setModalOpen(true); @@ -352,7 +352,7 @@ const Repositories = () => { ]); const handleToggleClick = ( - toggleType: 'toggle-group-all' | 'toggle-group-selected' + toggleType: 'toggle-group-all' | 'toggle-group-selected', ) => { setPage(1); setToggleSelected(toggleType); @@ -360,7 +360,7 @@ const Repositories = () => { const isRepoDisabled = ( repo: ApiRepositoryResponseRead, - isSelected: boolean + isSelected: boolean, ): [boolean, string] => { if (isFetching) { return [true, 'Repository data is still fetching, please wait.']; @@ -399,7 +399,7 @@ const Repositories = () => { const handlePerPageSelect = ( _: React.MouseEvent, newPerPage: number, - newPage: number + newPage: number, ) => { setPerPage(newPerPage); setPage(newPage); @@ -407,7 +407,7 @@ const Repositories = () => { const handleFilterRepositories = ( e: React.FormEvent<HTMLInputElement>, - value: string + value: string, ) => { e.preventDefault(); setPage(1); @@ -421,14 +421,14 @@ const Repositories = () => { dispatch( changeCustomRepositories( - customRepositories.filter(({ id }) => !itemsToRemove.has(id)) - ) + customRepositories.filter(({ id }) => !itemsToRemove.has(id)), + ), ); dispatch( changePayloadRepositories( - payloadRepositories.filter(({ id }) => !itemsToRemove.has(id || '')) - ) + payloadRepositories.filter(({ id }) => !itemsToRemove.has(id || '')), + ), ); setReposToRemove([]); @@ -443,7 +443,7 @@ const Repositories = () => { { uuid: templateUuid, }, - { refetchOnMountOrArgChange: true, skip: templateUuid === '' } + { refetchOnMountOrArgChange: true, skip: templateUuid === '' }, ); const { @@ -463,40 +463,40 @@ const Repositories = () => { ? selectedTemplateData.repository_uuids?.join(',') : '', }, - { refetchOnMountOrArgChange: true, skip: !isTemplateSelected } + { refetchOnMountOrArgChange: true, skip: !isTemplateSelected }, ); useEffect(() => { if (isTemplateSelected && reposInTemplate.length > 0) { const customReposInTemplate = reposInTemplate.filter( - (repo) => repo.origin !== ContentOrigin.REDHAT + (repo) => repo.origin !== ContentOrigin.REDHAT, ); const redHatReposInTemplate = reposInTemplate.filter( - (repo) => repo.origin === ContentOrigin.REDHAT + (repo) => repo.origin === ContentOrigin.REDHAT, ); dispatch( changeCustomRepositories( customReposInTemplate.map((repo) => - convertSchemaToIBCustomRepo(repo!) - ) - ) + convertSchemaToIBCustomRepo(repo!), + ), + ), ); dispatch( changePayloadRepositories( customReposInTemplate.map((repo) => - convertSchemaToIBPayloadRepo(repo!) - ) - ) + convertSchemaToIBPayloadRepo(repo!), + ), + ), ); dispatch( changeRedHatRepositories( redHatReposInTemplate.map((repo) => - convertSchemaToIBPayloadRepo(repo!) - ) - ) + convertSchemaToIBPayloadRepo(repo!), + ), + ), ); } }, [templateUuid, reposInTemplate]); @@ -547,7 +547,7 @@ const Repositories = () => { contentList.every( (repo) => repo.uuid && - isRepoDisabled(repo, selected.has(repo.uuid))[0] + isRepoDisabled(repo, selected.has(repo.uuid))[0], ) } /> @@ -633,7 +633,7 @@ const Repositories = () => { const [isDisabled, disabledReason] = isRepoDisabled( repo, - selected.has(uuid) + selected.has(uuid), ); return ( diff --git a/src/Components/CreateImageWizard/steps/Repositories/RepositoriesStatus.tsx b/src/Components/CreateImageWizard/steps/Repositories/RepositoriesStatus.tsx index 255a5de1..7e84141d 100644 --- a/src/Components/CreateImageWizard/steps/Repositories/RepositoriesStatus.tsx +++ b/src/Components/CreateImageWizard/steps/Repositories/RepositoriesStatus.tsx @@ -28,12 +28,12 @@ import { import '../../../ImagesTable/ImageBuildStatus.scss'; const getLastIntrospection = ( - repoIntrospections: RepositoryStatusProps['repoIntrospections'] + repoIntrospections: RepositoryStatusProps['repoIntrospections'], ) => { const currentDate = Date.now(); const lastIntrospectionDate = convertStringToDate(repoIntrospections); const timeDeltaInSeconds = Math.floor( - (currentDate - lastIntrospectionDate) / 1000 + (currentDate - lastIntrospectionDate) / 1000, ); if (timeDeltaInSeconds <= 60) { diff --git a/src/Components/CreateImageWizard/steps/Repositories/components/BulkSelect.tsx b/src/Components/CreateImageWizard/steps/Repositories/components/BulkSelect.tsx index 56db40ac..bbf5ef9a 100644 --- a/src/Components/CreateImageWizard/steps/Repositories/components/BulkSelect.tsx +++ b/src/Components/CreateImageWizard/steps/Repositories/components/BulkSelect.tsx @@ -18,7 +18,7 @@ interface BulkSelectProps { perPage: number; handleAddRemove: ( repo: ApiRepositoryResponseRead | ApiRepositoryResponseRead[], - selected: boolean + selected: boolean, ) => void; isDisabled: boolean; } diff --git a/src/Components/CreateImageWizard/steps/Repositories/components/Utilities.ts b/src/Components/CreateImageWizard/steps/Repositories/components/Utilities.ts index 0d216081..717509f2 100644 --- a/src/Components/CreateImageWizard/steps/Repositories/components/Utilities.ts +++ b/src/Components/CreateImageWizard/steps/Repositories/components/Utilities.ts @@ -7,7 +7,7 @@ import { // Utility function to convert from Content Sources to Image Builder custom repo API schema export const convertSchemaToIBCustomRepo = ( - repo: ApiRepositoryResponseRead + repo: ApiRepositoryResponseRead, ) => { const imageBuilderRepo: CustomRepository = { id: repo.uuid!, @@ -30,7 +30,7 @@ export const convertSchemaToIBCustomRepo = ( // Utility function to convert from Content Sources to Image Builder payload repo API schema export const convertSchemaToIBPayloadRepo = ( - repo: ApiRepositoryResponseRead + repo: ApiRepositoryResponseRead, ) => { const imageBuilderRepo: Repository = { id: repo.uuid!, diff --git a/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx b/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx index 43e72414..747f1417 100644 --- a/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx +++ b/src/Components/CreateImageWizard/steps/Review/Footer/CreateDropdown.tsx @@ -73,7 +73,7 @@ export const CreateSaveAndBuildBtn = ({ const analyticsData = createAnalytics( requestBody as CreateBlueprintRequest, packages, - isBeta + isBeta, ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Created`, { ...analyticsData, @@ -84,7 +84,7 @@ export const CreateSaveAndBuildBtn = ({ module: AMPLITUDE_MODULE_NAME, trigger: 'blueprint_created', image_request_types: requestBody.image_requests.map( - (req) => req.image_type + (req) => req.image_type, ), }); } @@ -133,7 +133,7 @@ export const CreateSaveButton = ({ const dispatch = useAppDispatch(); const [showModal, setShowModal] = useState(false); const wasModalSeen = window.localStorage.getItem( - 'imageBuilder.saveAndBuildModalSeen' + 'imageBuilder.saveAndBuildModalSeen', ); const SaveAndBuildImagesModal = () => { @@ -180,7 +180,7 @@ export const CreateSaveButton = ({ const analyticsData = createAnalytics( requestBody as CreateBlueprintRequest, packages, - isBeta + isBeta, ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Created`, { ...analyticsData, diff --git a/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx b/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx index c4577e4f..3a6adc30 100644 --- a/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx +++ b/src/Components/CreateImageWizard/steps/Review/Footer/EditDropdown.tsx @@ -65,7 +65,7 @@ export const EditSaveAndBuildBtn = ({ const analyticsData = createAnalytics( requestBody as CreateBlueprintRequest, packages, - isBeta + isBeta, ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Updated`, { ...analyticsData, @@ -76,7 +76,7 @@ export const EditSaveAndBuildBtn = ({ module: AMPLITUDE_MODULE_NAME, trigger: 'blueprint_updated', image_request_types: requestBody.image_requests.map( - (req) => req.image_type + (req) => req.image_type, ), }); } @@ -131,7 +131,7 @@ export const EditSaveButton = ({ const analyticsData = createAnalytics( requestBody as CreateBlueprintRequest, packages, - isBeta + isBeta, ); analytics.track(`${AMPLITUDE_MODULE_NAME} - Blueprint Updated`, { ...analyticsData, diff --git a/src/Components/CreateImageWizard/steps/Review/ReviewStep.tsx b/src/Components/CreateImageWizard/steps/Review/ReviewStep.tsx index 9e515428..67ab07de 100644 --- a/src/Components/CreateImageWizard/steps/Review/ReviewStep.tsx +++ b/src/Components/CreateImageWizard/steps/Review/ReviewStep.tsx @@ -195,7 +195,7 @@ const Review = () => { toggleContent={composeExpandable( 'Image output', 'revisit-image-output', - 'step-image-output' + 'step-image-output', )} onToggle={(_event, isExpandedImageOutput) => onToggleImageOutput(isExpandedImageOutput) @@ -210,7 +210,7 @@ const Review = () => { toggleContent={composeExpandable( 'Target environments', 'revisit-target-environments', - 'step-image-output' + 'step-image-output', )} onToggle={(_event, isExpandedTargetEnvs) => onToggleTargetEnvs(isExpandedTargetEnvs) @@ -297,7 +297,7 @@ const Review = () => { toggleContent={composeExpandable( 'Registration', 'revisit-registration', - 'step-register' + 'step-register', )} onToggle={(_event, isExpandedRegistration) => onToggleRegistration(isExpandedRegistration) @@ -318,7 +318,7 @@ const Review = () => { toggleContent={composeExpandable( 'OpenSCAP', 'revisit-openscap', - 'step-oscap' + 'step-oscap', )} onToggle={(_event, isExpandedOscapDetail) => onToggleOscapDetails(isExpandedOscapDetail) @@ -335,7 +335,7 @@ const Review = () => { toggleContent={composeExpandable( 'Compliance', 'revisit-compliance', - 'step-oscap' + 'step-oscap', )} onToggle={(_event, isExpandedComplianceDetail) => onToggleComplianceDetails(isExpandedComplianceDetail) @@ -352,7 +352,7 @@ const Review = () => { toggleContent={composeExpandable( 'File system configuration', 'revisit-file-system', - 'step-file-system' + 'step-file-system', )} onToggle={(_event, isExpandedFSC) => onToggleFSC(isExpandedFSC)} isExpanded={isExpandedFSC} @@ -366,7 +366,7 @@ const Review = () => { toggleContent={composeExpandable( 'Content', 'revisit-custom-repositories', - 'wizard-custom-repositories' + 'wizard-custom-repositories', )} onToggle={(_event, isExpandedContent) => onToggleContent(isExpandedContent) @@ -382,7 +382,7 @@ const Review = () => { toggleContent={composeExpandable( 'Users', 'revisit-users', - 'wizard-users' + 'wizard-users', )} onToggle={(_event, isExpandedUsers) => onToggleUsers(isExpandedUsers)} isExpanded={isExpandedUsers} @@ -397,7 +397,7 @@ const Review = () => { toggleContent={composeExpandable( 'Timezone', 'revisit-timezone', - 'wizard-timezone' + 'wizard-timezone', )} onToggle={(_event, isExpandedTimezone) => onToggleTimezone(isExpandedTimezone) @@ -415,7 +415,7 @@ const Review = () => { toggleContent={composeExpandable( 'Locale', 'revisit-locale', - 'wizard-locale' + 'wizard-locale', )} onToggle={(_event, isExpandedLocale) => onToggleLocale(isExpandedLocale) @@ -432,7 +432,7 @@ const Review = () => { toggleContent={composeExpandable( 'Hostname', 'revisit-hostname', - 'wizard-hostname' + 'wizard-hostname', )} onToggle={(_event, isExpandedHostname) => onToggleHostname(isExpandedHostname) @@ -449,7 +449,7 @@ const Review = () => { toggleContent={composeExpandable( 'Kernel', 'revisit-kernel', - 'wizard-kernel' + 'wizard-kernel', )} onToggle={(_event, isExpandedKernel) => onToggleKernel(isExpandedKernel) @@ -468,7 +468,7 @@ const Review = () => { toggleContent={composeExpandable( 'Firewall', 'revisit-firewall', - 'wizard-firewall' + 'wizard-firewall', )} onToggle={(_event, isExpandedFirewall) => onToggleFirewall(isExpandedFirewall) @@ -487,7 +487,7 @@ const Review = () => { toggleContent={composeExpandable( 'Systemd services', 'revisit-services', - 'wizard-services' + 'wizard-services', )} onToggle={(_event, isExpandedServices) => onToggleServices(isExpandedServices) @@ -503,7 +503,7 @@ const Review = () => { toggleContent={composeExpandable( 'First boot', 'revisit-first-boot', - 'wizard-first-boot' + 'wizard-first-boot', )} onToggle={(_event, isExpandableFirstBoot) => onToggleFirstBoot(isExpandableFirstBoot) @@ -519,7 +519,7 @@ const Review = () => { toggleContent={composeExpandable( 'Details', 'revisit-details', - 'step-details' + 'step-details', )} onToggle={(_event, isExpandedImageDetail) => onToggleImageDetail(isExpandedImageDetail) diff --git a/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx b/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx index 71ca07f1..e6b40ab2 100644 --- a/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx +++ b/src/Components/CreateImageWizard/steps/Review/ReviewStepTables.tsx @@ -40,7 +40,7 @@ const RepoName = ({ repoUuid }: repoPropType) => { contentType: 'rpm', origin: ContentOrigin.ALL, }, - { skip: !repoUuid } + { skip: !repoUuid }, ); const errorLoading = () => { @@ -132,7 +132,7 @@ export const SnapshotTable = ({ { uuid: template, }, - { refetchOnMountOrArgChange: true, skip: template === '' } + { refetchOnMountOrArgChange: true, skip: template === '' }, ); const { data, isSuccess, isLoading, isError } = useListRepositoriesQuery({ @@ -148,7 +148,7 @@ export const SnapshotTable = ({ const isAfterSet = new Set( snapshotForDate .filter(({ is_after }) => is_after) - .map(({ repository_uuid }) => repository_uuid) + .map(({ repository_uuid }) => repository_uuid), ); const stringToDateToMMDDYYYY = (strDate: string) => { @@ -244,7 +244,7 @@ export const RepositoriesTable = () => { const distribution = useAppSelector(selectDistribution); const repositoriesList = useAppSelector(selectCustomRepositories); const recommendedRepositoriesList = useAppSelector( - selectRecommendedRepositories + selectRecommendedRepositories, ); return ( <Panel isScrollable> diff --git a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx index 5a610f24..b77a11c3 100644 --- a/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx +++ b/src/Components/CreateImageWizard/steps/Review/ReviewStepTextLists.tsx @@ -115,13 +115,13 @@ export const ImageOutputList = () => { {toMonthAndYear( distribution === RHEL_8 ? RHEL_8_FULL_SUPPORT[1] - : RHEL_9_FULL_SUPPORT[1] + : RHEL_9_FULL_SUPPORT[1], )} , with optional ELS support through{' '} {toMonthAndYear( distribution === RHEL_8 ? RHEL_8_MAINTENANCE_SUPPORT[1] - : RHEL_9_MAINTENANCE_SUPPORT[1] + : RHEL_9_MAINTENANCE_SUPPORT[1], )} . Consider building an image with {RELEASES.get(RHEL_10)} to extend the support period. @@ -149,7 +149,7 @@ export const ImageOutputList = () => { }; export const FSCList = () => { const fileSystemConfigurationType = useAppSelector( - selectFileSystemConfigurationType + selectFileSystemConfigurationType, ); const partitions = useAppSelector(selectPartitions); @@ -235,7 +235,7 @@ export const TargetEnvAWSList = () => { selectFromResult: ({ data }) => ({ source: data?.data?.find((source) => source?.id === sourceId), }), - } + }, ); return ( @@ -367,7 +367,7 @@ export const TargetEnvAzureList = () => { <Content component={ContentVariants.dd}> { rawAzureSources?.data?.find( - (source) => source?.id === azureSource + (source) => source?.id === azureSource, )?.name } </Content> @@ -445,7 +445,7 @@ export const ContentList = () => { ...customRepositories.map(({ id }) => id), ...recommendedRepositories.map(({ uuid }) => uuid), ] as string[], - [customRepositories, recommendedRepositories] + [customRepositories, recommendedRepositories], ); const [listSnapshotsByDate, { data, isSuccess, isLoading, isError }] = @@ -470,7 +470,7 @@ export const ContentList = () => { ]); const duplicatePackages = packages.filter( - (item, index) => packages.indexOf(item) !== index + (item, index) => packages.indexOf(item) !== index, ); const noRepositoriesSelected = @@ -484,7 +484,7 @@ export const ContentList = () => { { uuid: template, }, - { refetchOnMountOrArgChange: true, skip: template === '' } + { refetchOnMountOrArgChange: true, skip: template === '' }, ); const snapshottingText = useMemo(() => { @@ -522,7 +522,7 @@ export const ContentList = () => { : template ? 'Use content from the content template' : `Repositories as of ${yyyyMMddFormat( - new Date(snapshotDate) + new Date(snapshotDate), )}` } hasAutoWidth @@ -657,7 +657,7 @@ export const RegisterNowList = () => { { name: activationKey }, { skip: !activationKey, - } + }, ); return ( <> diff --git a/src/Components/CreateImageWizard/steps/Services/components/ServicesInputs.tsx b/src/Components/CreateImageWizard/steps/Services/components/ServicesInputs.tsx index 5838bdd7..b28fd0a8 100644 --- a/src/Components/CreateImageWizard/steps/Services/components/ServicesInputs.tsx +++ b/src/Components/CreateImageWizard/steps/Services/components/ServicesInputs.tsx @@ -37,19 +37,19 @@ const ServicesInput = () => { }, { skip: !complianceProfileID, - } + }, ); const disabledRequiredByOpenSCAP = disabledServices.filter((service) => - oscapProfileInfo?.services?.disabled?.includes(service) + oscapProfileInfo?.services?.disabled?.includes(service), ); const maskedRequiredByOpenSCAP = maskedServices.filter((service) => - oscapProfileInfo?.services?.masked?.includes(service) + oscapProfileInfo?.services?.masked?.includes(service), ); const enabledRequiredByOpenSCAP = enabledServices.filter((service) => - oscapProfileInfo?.services?.enabled?.includes(service) + oscapProfileInfo?.services?.enabled?.includes(service), ); return ( @@ -60,7 +60,7 @@ const ServicesInput = () => { placeholder="Add enabled service" validator={isServiceValid} list={enabledServices.filter( - (service) => !enabledRequiredByOpenSCAP.includes(service) + (service) => !enabledRequiredByOpenSCAP.includes(service), )} requiredList={enabledRequiredByOpenSCAP} requiredCategoryName="Required by OpenSCAP" @@ -78,7 +78,7 @@ const ServicesInput = () => { validator={isServiceValid} list={disabledServices.filter( (service) => - !oscapProfileInfo?.services?.disabled?.includes(service) + !oscapProfileInfo?.services?.disabled?.includes(service), )} requiredList={disabledRequiredByOpenSCAP} requiredCategoryName="Required by OpenSCAP" @@ -95,7 +95,7 @@ const ServicesInput = () => { placeholder="Add masked service" validator={isServiceValid} list={maskedServices.filter( - (service) => !oscapProfileInfo?.services?.masked?.includes(service) + (service) => !oscapProfileInfo?.services?.masked?.includes(service), )} requiredList={maskedRequiredByOpenSCAP} requiredCategoryName="Required by OpenSCAP" diff --git a/src/Components/CreateImageWizard/steps/Snapshot/components/ConditionalTooltip.tsx b/src/Components/CreateImageWizard/steps/Snapshot/components/ConditionalTooltip.tsx index 72c7c551..150c1cd4 100644 --- a/src/Components/CreateImageWizard/steps/Snapshot/components/ConditionalTooltip.tsx +++ b/src/Components/CreateImageWizard/steps/Snapshot/components/ConditionalTooltip.tsx @@ -14,7 +14,7 @@ const ConditionalTooltip = ({ show, children, setDisabled, ...rest }: Props) => {children && cloneElement( children, - setDisabled ? { isDisabled: setDisabled } : undefined + setDisabled ? { isDisabled: setDisabled } : undefined, )} </div> </Tooltip> diff --git a/src/Components/CreateImageWizard/steps/Snapshot/components/Snapshot.tsx b/src/Components/CreateImageWizard/steps/Snapshot/components/Snapshot.tsx index b9f8d536..a74d1d95 100644 --- a/src/Components/CreateImageWizard/steps/Snapshot/components/Snapshot.tsx +++ b/src/Components/CreateImageWizard/steps/Snapshot/components/Snapshot.tsx @@ -39,7 +39,7 @@ export default function Snapshot() { const isTemplatesEnabled = useFlag('image-builder.templates.enabled'); const handleOptionChange = ( - option: 'latest' | 'snapshotDate' | 'template' + option: 'latest' | 'snapshotDate' | 'template', ): void => { setSelectedOption(option); switch (option) { diff --git a/src/Components/CreateImageWizard/steps/Snapshot/components/Templates.tsx b/src/Components/CreateImageWizard/steps/Snapshot/components/Templates.tsx index d30f581d..121dc57e 100644 --- a/src/Components/CreateImageWizard/steps/Snapshot/components/Templates.tsx +++ b/src/Components/CreateImageWizard/steps/Snapshot/components/Templates.tsx @@ -51,12 +51,12 @@ const Templates = () => { limit: perPage, offset: perPage * (page - 1), }, - { refetchOnMountOrArgChange: 60 } + { refetchOnMountOrArgChange: 60 }, ); const handleRowSelect = ( templateUuid: string | undefined, - templateName: string | undefined + templateName: string | undefined, ): void => { if (templateUuid) { dispatch(changeTemplate(templateUuid)); @@ -69,7 +69,7 @@ const Templates = () => { const handlePerPageSelect = ( _: React.MouseEvent, newPerPage: number, - newPage: number + newPage: number, ) => { setPerPage(newPerPage); setPage(newPage); diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx index 7487ba81..1773d4b1 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsAccountId.tsx @@ -23,7 +23,7 @@ export const AwsAccountId = () => { { id: parseInt(sourceId as string), }, - { skip: sourceId === undefined || sourceId === '' } + { skip: sourceId === undefined || sourceId === '' }, ); useEffect(() => { diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsSourcesSelect.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsSourcesSelect.tsx index b28cf4ea..0bbf1946 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsSourcesSelect.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/AwsSourcesSelect.tsx @@ -39,7 +39,7 @@ export const AwsSourcesSelect = () => { const chosenSource = sources?.find((source) => source?.id === sourceId); const [selectOptions, setSelectOptions] = useState<(string | undefined)[]>( - sources ? sources.map((source) => source?.name) : [] + sources ? sources.map((source) => source?.name) : [], ); useEffect(() => { @@ -49,7 +49,7 @@ export const AwsSourcesSelect = () => { filteredSources = sources .map((source) => source?.name) .filter((source: string) => - String(source).toLowerCase().includes(filterValue.toLowerCase()) + String(source).toLowerCase().includes(filterValue.toLowerCase()), ); if (!isOpen) { setIsOpen(true); @@ -85,7 +85,7 @@ export const AwsSourcesSelect = () => { const handleSelect = ( _event: React.MouseEvent<Element, MouseEvent>, - value: string + value: string, ) => { const source = sources?.find((source) => source?.name === value); dispatch(changeAwsSourceId(source?.id)); @@ -114,15 +114,15 @@ export const AwsSourcesSelect = () => { selectOptionsElement.push( <SelectOption key={index} value={key}> {key} - </SelectOption> - ) + </SelectOption>, + ), ); if (isFetching) { selectOptionsElement.push( <SelectOption key="fetching" value="loader"> <Spinner size="lg" /> - </SelectOption> + </SelectOption>, ); } @@ -130,7 +130,7 @@ export const AwsSourcesSelect = () => { selectOptionsElement.push( <SelectOption key="no_results" value="no_results" isDisabled> No results found - </SelectOption> + </SelectOption>, ); } diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx index 3c936d18..bcbaffc9 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Aws/index.tsx @@ -64,7 +64,7 @@ const AWSRegion = ({ value, onChange }: FormGroupProps<string>) => { const onSelect = ( _event: React.MouseEvent<Element, MouseEvent> | undefined, - value: string | number | undefined + value: string | number | undefined, ) => { onChange(value as string); setIsOpen(false); diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureAuthButton.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureAuthButton.tsx index 213183f7..23f86fbf 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureAuthButton.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureAuthButton.tsx @@ -9,7 +9,7 @@ export const AzureAuthButton = () => { const tenantId = useAppSelector(selectAzureTenantId); const guidRegex = new RegExp( '^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$', - 'i' + 'i', ); return ( diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureResourceGroups.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureResourceGroups.tsx index 70218bda..cb395d47 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureResourceGroups.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureResourceGroups.tsx @@ -42,7 +42,7 @@ export const AzureResourceGroups = () => { { id: parseInt(azureSource as string) }, { skip: !azureSource, - } + }, ); // use a static empty array to avoid an infinite render loop in useEffect functions depending @@ -54,7 +54,7 @@ export const AzureResourceGroups = () => { if (filterValue) { filteredGroups = resourceGroups.filter((group: string) => - String(group).toLowerCase().includes(filterValue.toLowerCase()) + String(group).toLowerCase().includes(filterValue.toLowerCase()), ); if (!isOpen) { setIsOpen(true); @@ -86,7 +86,7 @@ export const AzureResourceGroups = () => { const setResourceGroup = ( _event: React.MouseEvent<Element, MouseEvent>, - selection: string + selection: string, ) => { const resource = resourceGroups.find((resource) => resource === selection) || ''; diff --git a/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureSourcesSelect.tsx b/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureSourcesSelect.tsx index 22df5640..d9caa2ee 100644 --- a/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureSourcesSelect.tsx +++ b/src/Components/CreateImageWizard/steps/TargetEnvironment/Azure/AzureSourcesSelect.tsx @@ -53,18 +53,18 @@ export const AzureSourcesSelect = () => { { id: parseInt(azureSource as string) }, { skip: !azureSource, - } + }, ); const [selectOptions, setSelectOptions] = useState<(string | undefined)[]>( - rawSources?.data?.map((source) => source?.name) || [] + rawSources?.data?.map((source) => source?.name) || [], ); useEffect(() => { if (isFetchingDetails || !isSuccessDetails) return; dispatch(changeAzureTenantId(sourceDetails?.azure?.tenant_id || '')); dispatch( - changeAzureSubscriptionId(sourceDetails?.azure?.subscription_id || '') + changeAzureSubscriptionId(sourceDetails?.azure?.subscription_id || ''), ); }, [ isFetchingDetails, @@ -81,7 +81,7 @@ export const AzureSourcesSelect = () => { filteredSources = rawSources?.data ?.map((source) => source?.name) .filter((source: string) => - String(source).toLowerCase().includes(filterValue.toLowerCase()) + String(source).toLowerCase().includes(filterValue.toLowerCase()), ); if (!isOpen) { setIsOpen(true); @@ -116,10 +116,10 @@ export const AzureSourcesSelect = () => { const handleSelect = ( _event: React.MouseEvent<Element, MouseEvent>, - sourceName: string + sourceName: string, ) => { const sourceId = rawSources?.data?.find( - (source) => source?.name === sourceName + (source) => source?.name === sourceName, )?.id; dispatch(changeAzureSource(sourceId || '')); dispatch(changeAzureResourceGroup('')); diff --git a/src/Components/CreateImageWizard/steps/Users/components/RemoveUserModal.tsx b/src/Components/CreateImageWizard/steps/Users/components/RemoveUserModal.tsx index 42b3311a..ddc251ca 100644 --- a/src/Components/CreateImageWizard/steps/Users/components/RemoveUserModal.tsx +++ b/src/Components/CreateImageWizard/steps/Users/components/RemoveUserModal.tsx @@ -43,7 +43,7 @@ const RemoveUserModal = ({ const nextTabIndex = calculateNewIndex( tabIndex, activeTabKey, - users.length + users.length, ); setActiveTabKey(nextTabIndex); diff --git a/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx b/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx index eb20a91a..53e11eb6 100644 --- a/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx +++ b/src/Components/CreateImageWizard/steps/Users/components/UserInfo.tsx @@ -84,7 +84,7 @@ const UserInfo = () => { const nextTabIndex = calculateNewIndex( tabIndex, activeTabKey, - users.length + users.length, ); setActiveTabKey(nextTabIndex); setIndex(nextTabIndex); @@ -97,31 +97,31 @@ const UserInfo = () => { const handleNameChange = ( _e: React.FormEvent<HTMLInputElement | HTMLTextAreaElement>, - value: string + value: string, ) => { dispatch(setUserNameByIndex({ index: index, name: value })); }; const handlePasswordChange = ( _event: React.FormEvent<HTMLInputElement>, - value: string + value: string, ) => { dispatch(setUserPasswordByIndex({ index: index, password: value })); }; const handleSshKeyChange = ( _event: React.FormEvent<HTMLInputElement | HTMLTextAreaElement>, - value: string + value: string, ) => { dispatch(setUserSshKeyByIndex({ index: index, sshKey: value })); }; const handleCheckboxChange = ( _event: React.FormEvent<HTMLInputElement>, - value: boolean + value: boolean, ) => { dispatch( - setUserAdministratorByIndex({ index: index, isAdministrator: value }) + setUserAdministratorByIndex({ index: index, isAdministrator: value }), ); }; @@ -164,7 +164,7 @@ const UserInfo = () => { {Object.entries(getValidationByIndex(index).errors).some( ([field, error]) => Boolean(error) && - !(field === 'userName' && error === 'Required value') + !(field === 'userName' && error === 'Required value'), ) && ( <Icon status="danger"> <ExclamationCircleIcon title="Validation error" /> diff --git a/src/Components/CreateImageWizard/steps/Users/components/calculateNewIndex.ts b/src/Components/CreateImageWizard/steps/Users/components/calculateNewIndex.ts index d2548195..3b58fa84 100644 --- a/src/Components/CreateImageWizard/steps/Users/components/calculateNewIndex.ts +++ b/src/Components/CreateImageWizard/steps/Users/components/calculateNewIndex.ts @@ -1,7 +1,7 @@ function calculateNewIndex( tabIndex: number, activeTabKey: number, - usersLength: number + usersLength: number, ) { const tabIndexNum = tabIndex; let nextTabIndex = activeTabKey; diff --git a/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx b/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx index 716ab254..0c50e08d 100644 --- a/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx +++ b/src/Components/CreateImageWizard/utilities/PasswordValidatedInput.tsx @@ -39,7 +39,7 @@ export const PasswordValidatedInput = ({ const { validationState } = checkPasswordValidity( value, - environments.includes('azure') + environments.includes('azure'), ); const { ruleLength, ruleCharacters } = validationState; diff --git a/src/Components/CreateImageWizard/utilities/checkRepositoriesAvailability.ts b/src/Components/CreateImageWizard/utilities/checkRepositoriesAvailability.ts index 1bdef4ed..b0337e58 100644 --- a/src/Components/CreateImageWizard/utilities/checkRepositoriesAvailability.ts +++ b/src/Components/CreateImageWizard/utilities/checkRepositoriesAvailability.ts @@ -46,7 +46,7 @@ export const useCheckRepositoriesAvailability = () => { }, { skip: skip, - } + }, ); const { data: freshRepos, isSuccess } = useMemo(() => { @@ -64,7 +64,7 @@ export const useCheckRepositoriesAvailability = () => { // Transform the fresh repos array into a Set to access its elements in O(1) // complexity later in the for loop. const freshReposUrls = new Set( - freshRepos?.data?.map((freshRepo) => freshRepo.url) + freshRepos?.data?.map((freshRepo) => freshRepo.url), ); for (const customRepo of customRepositories) { if (customRepo.baseurl && !freshReposUrls.has(customRepo.baseurl[0])) { diff --git a/src/Components/CreateImageWizard/utilities/requestMapper.ts b/src/Components/CreateImageWizard/utilities/requestMapper.ts index e41c859b..ef7f1d87 100644 --- a/src/Components/CreateImageWizard/utilities/requestMapper.ts +++ b/src/Components/CreateImageWizard/utilities/requestMapper.ts @@ -127,7 +127,7 @@ import { GcpAccountType, GcpShareMethod } from '../steps/TargetEnvironment/Gcp'; */ export const mapRequestFromState = ( store: Store, - orgID: string + orgID: string, ): CreateBlueprintRequest | CockpitCreateBlueprintRequest => { const state = store.getState(); const imageRequests = getImageRequests(state); @@ -174,17 +174,17 @@ const getLatestRelease = (distribution: Distributions) => { }; function commonRequestToState( - request: BlueprintResponse | CreateBlueprintRequest + request: BlueprintResponse | CreateBlueprintRequest, ) { const gcp = request.image_requests.find( - (image) => image.image_type === 'gcp' + (image) => image.image_type === 'gcp', ); const aws = request.image_requests.find( - (image) => image.image_type === 'aws' + (image) => image.image_type === 'aws', ); const azure = request.image_requests.find( - (image) => image.image_type === 'azure' + (image) => image.image_type === 'azure', ); const snapshotDateFromRequest = @@ -272,7 +272,7 @@ function commonRequestToState( ? { mode: 'manual' as FileSystemConfigurationType, partitions: request.customizations?.filesystem.map((fs) => - convertFilesystemToPartition(fs) + convertFilesystemToPartition(fs), ), } : { @@ -298,7 +298,7 @@ function commonRequestToState( ? 'withGoogle' : 'withInsights') as GcpShareMethod, accountType: gcpUploadOptions?.share_with_accounts?.[0].split( - ':' + ':', )[0] as GcpAccountType, email: gcpUploadOptions?.share_with_accounts?.[0].split(':')[1] || '', }, @@ -408,7 +408,7 @@ export const mapRequestToState = (request: BlueprintResponse): wizardState => { }; export function mapToCustomRepositories( - repo: ApiRepositoryImportResponseRead + repo: ApiRepositoryImportResponseRead, ): CustomRepository[] { if (!repo.uuid) return []; return [ @@ -432,7 +432,7 @@ export function mapToCustomRepositories( */ export const mapExportRequestToState = ( request: BlueprintExportResponse, - image_requests: ImageRequest[] + image_requests: ImageRequest[], ): wizardState => { const wizardMode = 'create'; const blueprintResponse: CreateBlueprintRequest = { @@ -462,7 +462,7 @@ const getFirstBootScript = (files?: File[]): string => { }; const getImageRequests = ( - state: RootState + state: RootState, ): ImageRequest[] | CockpitImageRequest[] => { const imageTypes = selectImageTypes(state); const snapshotDate = selectSnapshotDate(state); @@ -484,13 +484,13 @@ const getImageRequests = ( const getSatelliteCommand = (files?: File[]): string => { const satelliteCommandFile = files?.find( - (file) => file.path === SATELLITE_PATH + (file) => file.path === SATELLITE_PATH, ); return satelliteCommandFile?.data ? atob(satelliteCommandFile.data) : ''; }; const uploadTypeByTargetEnv = ( - imageType: ImageTypes + imageType: ImageTypes, ): UploadTypes | CockpitUploadTypes => { switch (imageType) { case 'aws': @@ -520,7 +520,7 @@ const uploadTypeByTargetEnv = ( }; const getImageOptions = ( imageType: ImageTypes, - state: RootState + state: RootState, ): | AwsUploadRequestOptions | AzureUploadRequestOptions @@ -715,7 +715,7 @@ const getFileSystem = (state: RootState): Filesystem[] | undefined => { return { min_size: convertToBytes( partition.min_size, - getConversionFactor(partition.unit) + getConversionFactor(partition.unit), ), mountpoint: partition.mountpoint, }; @@ -761,7 +761,7 @@ const getTimezone = (state: RootState) => { const getSubscription = ( state: RootState, - orgID: string + orgID: string, ): Subscription | undefined => { const registrationType = selectRegistrationType(state); const activationKey = selectActivationKey(state); @@ -775,7 +775,7 @@ const getSubscription = ( if (activationKey === undefined) { throw new Error( - 'Activation key unexpectedly undefined while generating subscription customization' + 'Activation key unexpectedly undefined while generating subscription customization', ); } @@ -845,7 +845,7 @@ const getCustomRepositories = (state: RootState) => { for (const repo in recommendedRepositories) { customAndRecommendedRepositories.push( - convertSchemaToIBCustomRepo(recommendedRepositories[repo]) + convertSchemaToIBCustomRepo(recommendedRepositories[repo]), ); } @@ -863,7 +863,7 @@ const getPayloadRepositories = (state: RootState) => { for (const repo in recommendedRepositories) { payloadAndRecommendedRepositories.push( - convertSchemaToIBPayloadRepo(recommendedRepositories[repo]) + convertSchemaToIBPayloadRepo(recommendedRepositories[repo]), ); } diff --git a/src/Components/CreateImageWizard/utilities/useGenerateDefaultName.ts b/src/Components/CreateImageWizard/utilities/useGenerateDefaultName.ts index 8c159415..4cbfb764 100644 --- a/src/Components/CreateImageWizard/utilities/useGenerateDefaultName.ts +++ b/src/Components/CreateImageWizard/utilities/useGenerateDefaultName.ts @@ -2,7 +2,7 @@ import { Distributions, ImageRequest } from '../../../store/imageBuilderApi'; export const generateDefaultName = ( distribution: Distributions, - arch: ImageRequest['architecture'] + arch: ImageRequest['architecture'], ) => { const date = new Date(); const day = date.getDate().toString().padStart(2, '0'); diff --git a/src/Components/CreateImageWizard/utilities/useValidation.tsx b/src/Components/CreateImageWizard/utilities/useValidation.tsx index ced08bcf..70023391 100644 --- a/src/Components/CreateImageWizard/utilities/useValidation.tsx +++ b/src/Components/CreateImageWizard/utilities/useValidation.tsx @@ -118,7 +118,7 @@ export function useRegistrationValidation(): StepValidation { const registrationType = useAppSelector(selectRegistrationType); const activationKey = useAppSelector(selectActivationKey); const registrationCommand = useAppSelector( - selectSatelliteRegistrationCommand + selectSatelliteRegistrationCommand, ); const caCertificate = useAppSelector(selectSatelliteCaCertificate); @@ -127,7 +127,7 @@ export function useRegistrationValidation(): StepValidation { { name: activationKey! }, { skip: !activationKey, - } + }, ); if ( @@ -168,7 +168,7 @@ export function useRegistrationValidation(): StepValidation { } try { const match = registrationCommand?.match( - /Bearer\s+([\w-]+\.[\w-]+\.[\w-]+)/ + /Bearer\s+([\w-]+\.[\w-]+\.[\w-]+)/, ); if (!match) { Object.assign(errors, { command: 'Invalid or missing token' }); @@ -410,10 +410,10 @@ export function useFirewallValidation(): StepValidation { const duplicatePorts = getListOfDuplicates(firewall.ports); const duplicateDisabledServices = getListOfDuplicates( - firewall.services.disabled + firewall.services.disabled, ); const duplicateEnabledServices = getListOfDuplicates( - firewall.services.enabled + firewall.services.enabled, ); const portsError = @@ -425,13 +425,13 @@ export function useFirewallValidation(): StepValidation { const duplicateDisabledServicesError = duplicateDisabledServices.length > 0 ? `Includes duplicate disabled services: ${duplicateDisabledServices.join( - ', ' + ', ', )}` : ''; const duplicateEnabledServicesError = duplicateEnabledServices.length > 0 ? `Includes duplicate enabled services: ${duplicateEnabledServices.join( - ', ' + ', ', )}` : ''; const disabledServicesError = @@ -509,19 +509,19 @@ export function useServicesValidation(): StepValidation { const duplicateDisabledServicesError = duplicateDisabledServices.length > 0 ? `Includes duplicate disabled services: ${duplicateDisabledServices.join( - ', ' + ', ', )}` : ''; const duplicateMaskedServicesError = duplicateMaskedServices.length > 0 ? `Includes duplicate masked services: ${duplicateMaskedServices.join( - ', ' + ', ', )}` : ''; const duplicateEnabledServicesError = duplicateEnabledServices.length > 0 ? `Includes duplicate enabled services: ${duplicateEnabledServices.join( - ', ' + ', ', )}` : ''; @@ -547,7 +547,7 @@ export function useServicesValidation(): StepValidation { const validateUserName = ( users: UserWithAdditionalInfo[], userName: string, - currentIndex: number + currentIndex: number, ): string => { if (!userName) { return 'Required value'; @@ -558,7 +558,7 @@ const validateUserName = ( // check for duplicate names const count = users.filter( - (user, index) => user.name === userName && index !== currentIndex + (user, index) => user.name === userName && index !== currentIndex, ).length; if (count > 0) { return 'Username already exists'; @@ -591,7 +591,7 @@ export function useUsersValidation(): UsersStepValidation { const sshKeyError = validateSshKey(users[index].ssh_key); const isPasswordValid = checkPasswordValidity( users[index].password, - environments.includes('azure') + environments.includes('azure'), ).isValid; const passwordError = users[index].password && !isPasswordValid ? 'Invalid password' : ''; @@ -643,7 +643,7 @@ export function useUsersValidation(): UsersStepValidation { export const checkPasswordValidity = ( password: string, - isAzure: boolean + isAzure: boolean, ): PasswordValidationResult => { if (!password) { return { @@ -686,7 +686,7 @@ export const checkPasswordValidity = ( const getStrength = ( strCount: number, rulesCount: number, - isAzure: boolean + isAzure: boolean, ): PasswordValidationResult['strength'] => { return isAzure && strCount >= 6 && rulesCount >= 3 ? { variant: 'success', icon: <CheckCircleIcon />, text: 'Strong' } @@ -743,7 +743,7 @@ export function useDetailsValidation(): StepValidation { setUniqueName(true); }); }, - UNIQUE_VALIDATION_DELAY // If name is empty string, instantly return + UNIQUE_VALIDATION_DELAY, // If name is empty string, instantly return ); return () => { diff --git a/src/Components/CreateImageWizard/validators.ts b/src/Components/CreateImageWizard/validators.ts index 35838256..ad3c8dd4 100644 --- a/src/Components/CreateImageWizard/validators.ts +++ b/src/Components/CreateImageWizard/validators.ts @@ -10,13 +10,13 @@ export const isAwsAccountIdValid = (awsAccountId: string | undefined) => { export const isAzureTenantGUIDValid = (azureTenantGUID: string) => { return /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test( - azureTenantGUID + azureTenantGUID, ); }; export const isAzureSubscriptionIdValid = (azureSubscriptionId: string) => { return /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test( - azureSubscriptionId + azureSubscriptionId, ); }; @@ -57,7 +57,7 @@ export const isUserNameValid = (userName: string) => { const isLengthValid = userName.length <= 32; const isNotNumericOnly = !/^\d+$/.test(userName); const isPatternValid = /^[a-zA-Z0-9][a-zA-Z0-9_.-]*[a-zA-Z0-9_$]$/.test( - userName + userName, ); return isLengthValid && isNotNumericOnly && isPatternValid; @@ -78,7 +78,7 @@ export const isSshKeyValid = (sshKey: string) => { // 3. Optional comment at the end. const isPatternValid = /^(ssh-(rsa|dss|ed25519)|ecdsa-sha2-nistp(256|384|521))\s+[A-Za-z0-9+/=]+(\s+\S+)?$/.test( - sshKey + sshKey, ); return isPatternValid; }; @@ -108,7 +108,7 @@ export const isHostnameValid = (hostname: string) => { return ( hostname.length < 65 && /^(([a-z0-9]|[a-z0-9][a-z0-9-]*[a-z0-9])\.)*([a-z0-9]|[a-z0-9][a-z0-9-]*[a-z0-9])$/.test( - hostname + hostname, ) ); }; diff --git a/src/Components/ImagesTable/ClonesTable.tsx b/src/Components/ImagesTable/ClonesTable.tsx index 165b39cc..c4d43c08 100644 --- a/src/Components/ImagesTable/ClonesTable.tsx +++ b/src/Components/ImagesTable/ClonesTable.tsx @@ -81,7 +81,7 @@ const CloneRow = ({ clone }: CloneRowPropTypes) => { { id: clone.id, }, - { pollingInterval: pollingInterval } + { pollingInterval: pollingInterval }, ); useEffect(() => { diff --git a/src/Components/ImagesTable/ImageDetails.tsx b/src/Components/ImagesTable/ImageDetails.tsx index a0ab0a97..da517aa5 100644 --- a/src/Components/ImagesTable/ImageDetails.tsx +++ b/src/Components/ImagesTable/ImageDetails.tsx @@ -120,7 +120,7 @@ const AwsSourceName = ({ id }: AwsSourceNamePropTypes) => { }; const parseGcpSharedWith = ( - sharedWith: GcpUploadRequestOptions['share_with_accounts'] + sharedWith: GcpUploadRequestOptions['share_with_accounts'], ) => { if (sharedWith) { const splitGCPSharedWith = sharedWith[0].split(':'); @@ -150,7 +150,7 @@ export const AwsDetails = ({ compose }: AwsDetailsPropTypes) => { if (!isAwsUploadRequestOptions(options)) { throw TypeError( - `Error: options must be of type AwsUploadRequestOptions, not ${typeof options}.` + `Error: options must be of type AwsUploadRequestOptions, not ${typeof options}.`, ); } @@ -254,7 +254,7 @@ export const AzureDetails = ({ compose }: AzureDetailsPropTypes) => { if (!isAzureUploadRequestOptions(options)) { throw TypeError( - `Error: options must be of type AzureUploadRequestOptions, not ${typeof options}.` + `Error: options must be of type AzureUploadRequestOptions, not ${typeof options}.`, ); } @@ -265,7 +265,7 @@ export const AzureDetails = ({ compose }: AzureDetailsPropTypes) => { if (uploadStatus && !isAzureUploadStatus(uploadStatus)) { throw TypeError( - `Error: uploadStatus must be of type AzureUploadStatus, not ${typeof uploadStatus}.` + `Error: uploadStatus must be of type AzureUploadStatus, not ${typeof uploadStatus}.`, ); } @@ -343,7 +343,7 @@ export const GcpDetails = ({ compose }: GcpDetailsPropTypes) => { if (!isGcpUploadRequestOptions(options)) { throw TypeError( - `Error: options must be of type GcpUploadRequestOptions, not ${typeof options}.` + `Error: options must be of type GcpUploadRequestOptions, not ${typeof options}.`, ); } @@ -351,7 +351,7 @@ export const GcpDetails = ({ compose }: GcpDetailsPropTypes) => { if (uploadStatus && !isGcpUploadStatus(uploadStatus)) { throw TypeError( - `Error: uploadStatus must be of type GcpUploadStatus, not ${typeof uploadStatus}.` + `Error: uploadStatus must be of type GcpUploadStatus, not ${typeof uploadStatus}.`, ); } @@ -431,7 +431,7 @@ export const OciDetails = ({ compose }: OciDetailsPropTypes) => { if (options && !isOciUploadStatus(options)) { throw TypeError( - `Error: uploadStatus must be of type OciUploadStatus, not ${typeof options}.` + `Error: uploadStatus must be of type OciUploadStatus, not ${typeof options}.`, ); } diff --git a/src/Components/ImagesTable/ImagesTable.tsx b/src/Components/ImagesTable/ImagesTable.tsx index f0a52bee..a1835291 100644 --- a/src/Components/ImagesTable/ImagesTable.tsx +++ b/src/Components/ImagesTable/ImagesTable.tsx @@ -98,7 +98,7 @@ const ImagesTable = () => { useAppSelector(selectBlueprintSearchInput) || SEARCH_INPUT; const blueprintVersionFilter = useAppSelector(selectBlueprintVersionFilter); const blueprintVersionFilterAPI = useAppSelector( - selectBlueprintVersionFilterAPI + selectBlueprintVersionFilterAPI, ); const blueprintsOffset = useAppSelector(selectOffset) || PAGINATION_OFFSET; const blueprintsLimit = useAppSelector(selectLimit) || PAGINATION_LIMIT; @@ -129,10 +129,10 @@ const ImagesTable = () => { { selectFromResult: ({ data }) => ({ selectedBlueprintVersion: data?.data.find( - (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId + (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId, )?.version, }), - } + }, ); const onSetPage: OnSetPage = (_, page) => setPage(page); @@ -177,7 +177,7 @@ const ImagesTable = () => { 'edge-installer', ], }, - { skip: !!selectedBlueprintId } + { skip: !!selectedBlueprintId }, ); const data = selectedBlueprintId ? blueprintsComposes : composesData; @@ -310,14 +310,14 @@ type ImagesTableRowPropTypes = { const ImagesTableRow = ({ compose, rowIndex }: ImagesTableRowPropTypes) => { const [pollingInterval, setPollingInterval] = useState( - STATUS_POLLING_INTERVAL + STATUS_POLLING_INTERVAL, ); const { data: composeStatus } = useGetComposeStatusQuery( { composeId: compose.id, }, - { pollingInterval: pollingInterval } + { pollingInterval: pollingInterval }, ); useEffect(() => { @@ -404,7 +404,7 @@ type OciRowPropTypes = { const OciRow = ({ compose, rowIndex }: OciRowPropTypes) => { const daysToExpiration = Math.floor( - computeHoursToExpiration(compose.created_at) / 24 + computeHoursToExpiration(compose.created_at) / 24, ); const isExpired = daysToExpiration >= OCI_STORAGE_EXPIRATION_TIME_IN_DAYS; @@ -492,7 +492,7 @@ const AwsRow = ({ compose, composeStatus, rowIndex }: AwsRowPropTypes) => { composeStatus, navigate, analytics, - userData?.identity.internal?.account_id + userData?.identity.internal?.account_id, )} /> ); @@ -633,7 +633,7 @@ const Row = ({ items={defaultActions( compose, analytics, - userData?.identity.internal?.account_id + userData?.identity.internal?.account_id, )} /> )} @@ -651,7 +651,7 @@ const Row = ({ const defaultActions = ( compose: ComposesResponseItem, analytics: Analytics, - account_id: string | undefined + account_id: string | undefined, ) => { const name = `request-${compose.id}.json`; @@ -661,7 +661,7 @@ const defaultActions = ( <a className="ib-subdued-link" href={`data:text/plain;charset=utf-8,${encodeURIComponent( - JSON.stringify(compose.request, null, ' ') + JSON.stringify(compose.request, null, ' '), )}`} download={name} onClick={() => { @@ -685,7 +685,7 @@ const awsActions = ( status: ComposeStatus | undefined, navigate: NavigateFunction, analytics: Analytics, - account_id: string | undefined + account_id: string | undefined, ) => { return [ { diff --git a/src/Components/ImagesTable/ImagesTableToolbar.tsx b/src/Components/ImagesTable/ImagesTableToolbar.tsx index 65bd0d6b..18dbf9e6 100644 --- a/src/Components/ImagesTable/ImagesTableToolbar.tsx +++ b/src/Components/ImagesTable/ImagesTableToolbar.tsx @@ -57,7 +57,7 @@ const ImagesTableToolbar: React.FC<imagesTableToolbarProps> = ({ const selectedBlueprintId = useAppSelector(selectSelectedBlueprintId); const blueprintSearchInput = useAppSelector(selectBlueprintSearchInput); const blueprintVersionFilterAPI = useAppSelector( - selectBlueprintVersionFilterAPI + selectBlueprintVersionFilterAPI, ); const searchParams: GetBlueprintComposesApiArg = { @@ -84,14 +84,14 @@ const ImagesTableToolbar: React.FC<imagesTableToolbarProps> = ({ { selectFromResult: ({ data }) => { const bp = data?.data.find( - (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId + (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId, ); return { selectedBlueprintName: bp?.name, selectedBlueprintVersion: bp?.version, }; }, - } + }, ); const latestImageVersion = blueprintsComposes?.data[0]?.blueprint_version; @@ -125,7 +125,7 @@ const ImagesTableToolbar: React.FC<imagesTableToolbarProps> = ({ const { data: blueprintDetails } = useGetBlueprintQuery( { id: selectedBlueprintId! }, - { skip: !selectedBlueprintId } + { skip: !selectedBlueprintId }, ); const { trigger: fixupBlueprint } = useFixupBlueprintMutation(); diff --git a/src/Components/ImagesTable/Instance.tsx b/src/Components/ImagesTable/Instance.tsx index 5c10cf07..dda9892c 100644 --- a/src/Components/ImagesTable/Instance.tsx +++ b/src/Components/ImagesTable/Instance.tsx @@ -117,7 +117,7 @@ const ProvisioningLink = ({ scope: 'provisioning', module: './ProvisioningWizard', }, - {} + {}, ); const { permissions, isLoading: isLoadingPermission } = @@ -126,7 +126,7 @@ const ProvisioningLink = ({ // Recomputing this value on every render made the modal crash. Using a state // helps avoiding this situation as the value is only set the first time. const [appendTo] = useState( - document.querySelector(MODAL_ANCHOR) as HTMLElement + document.querySelector(MODAL_ANCHOR) as HTMLElement, ); const selectedBlueprintId = useAppSelector(selectSelectedBlueprintId); @@ -137,10 +137,10 @@ const ProvisioningLink = ({ { selectFromResult: ({ data }) => ({ selectedBlueprintVersion: data?.data.find( - (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId + (blueprint: BlueprintItem) => blueprint.id === selectedBlueprintId, )?.version, }), - } + }, ); if ( @@ -270,7 +270,7 @@ export const OciInstance = ({ compose, isExpired }: OciInstancePropTypes) => { if (options && !isOciUploadStatus(options)) { throw TypeError( - `Error: options must be of type OciUploadStatus, not ${typeof options}.` + `Error: options must be of type OciUploadStatus, not ${typeof options}.`, ); } @@ -404,7 +404,7 @@ export const AwsS3Instance = ({ if (options && !isAwss3UploadStatus(options)) { throw TypeError( - `Error: options must be of type Awss3UploadStatus, not ${typeof options}.` + `Error: options must be of type Awss3UploadStatus, not ${typeof options}.`, ); } diff --git a/src/Components/ImagesTable/Status.tsx b/src/Components/ImagesTable/Status.tsx index 4785f293..5dfa8c15 100644 --- a/src/Components/ImagesTable/Status.tsx +++ b/src/Components/ImagesTable/Status.tsx @@ -485,7 +485,7 @@ const ErrorStatus = ({ icon, text, error }: ErrorStatusPropTypes) => { variant="link" onClick={() => navigator.clipboard.writeText( - reason + '\n\n' + detailsArray.join('\n') + reason + '\n\n' + detailsArray.join('\n'), ) } className="pf-v6-u-pl-0 pf-v6-u-mt-md" diff --git a/src/Components/LandingPage/NewAlert.tsx b/src/Components/LandingPage/NewAlert.tsx index e5c19a60..f18c141d 100644 --- a/src/Components/LandingPage/NewAlert.tsx +++ b/src/Components/LandingPage/NewAlert.tsx @@ -18,7 +18,7 @@ type NewAlertPropTypes = { export const NewAlert = ({ setShowAlert }: NewAlertPropTypes) => { const isAlertDismissed = window.localStorage.getItem( - 'imageBuilder.newFeatureNewCustomizationsAlertDismissed' + 'imageBuilder.newFeatureNewCustomizationsAlertDismissed', ); const [displayAlert, setDisplayAlert] = useState(!isAlertDismissed); @@ -26,7 +26,7 @@ export const NewAlert = ({ setShowAlert }: NewAlertPropTypes) => { setDisplayAlert(false); window.localStorage.setItem( 'imageBuilder.newFeatureNewCustomizationsAlertDismissed', - 'true' + 'true', ); }; diff --git a/src/Components/ShareImageModal/RegionsSelect.tsx b/src/Components/ShareImageModal/RegionsSelect.tsx index a508f3f1..f1d8a6d2 100644 --- a/src/Components/ShareImageModal/RegionsSelect.tsx +++ b/src/Components/ShareImageModal/RegionsSelect.tsx @@ -39,7 +39,7 @@ import { resolveRelPath } from '../../Utilities/path'; const generateRequests = ( composeId: string, composeStatus: ComposeStatus, - regions: string[] + regions: string[], ) => { return regions.map((region) => { const options = @@ -72,7 +72,7 @@ const RegionsSelect = ({ composeId, handleClose }: RegionsSelectPropTypes) => { const [isOpen, setIsOpen] = useState(false); const [isSaving, setIsSaving] = useState(false); const [validated, setValidated] = useState<ValidatedOptions>( - ValidatedOptions.default + ValidatedOptions.default, ); const initialRegions = AWS_REGIONS; @@ -87,7 +87,7 @@ const RegionsSelect = ({ composeId, handleClose }: RegionsSelectPropTypes) => { if (inputValue) { newSelectOptions = initialRegions.filter((region) => - region.value.toLowerCase().includes(inputValue.toLowerCase()) + region.value.toLowerCase().includes(inputValue.toLowerCase()), ); // When no options are found after filtering, display 'No results found' @@ -112,7 +112,7 @@ const RegionsSelect = ({ composeId, handleClose }: RegionsSelectPropTypes) => { const onTextInputChange = ( _event: React.FormEvent<HTMLInputElement>, - value: string + value: string, ) => { setInputValue(value); }; @@ -122,7 +122,7 @@ const RegionsSelect = ({ composeId, handleClose }: RegionsSelectPropTypes) => { setSelected( selected.includes(value) ? selected.filter((selection) => selection !== value) - : [...selected, value] + : [...selected, value], ); setValidated(ValidatedOptions.success); } else { diff --git a/src/Components/sharedComponents/ImageBuilderHeader.tsx b/src/Components/sharedComponents/ImageBuilderHeader.tsx index 954fd48b..232fbfba 100644 --- a/src/Components/sharedComponents/ImageBuilderHeader.tsx +++ b/src/Components/sharedComponents/ImageBuilderHeader.tsx @@ -75,7 +75,7 @@ export const ImageBuilderHeader = ({ const prefetchTargets = useBackendPrefetch('getArchitectures'); const importExportFlag = useFlagWithEphemDefault( - 'image-builder.import.enabled' + 'image-builder.import.enabled', ); const [showImportModal, setShowImportModal] = useState(false); return ( diff --git a/src/Hooks/MutationNotifications/useCloneComposeWithNotification.tsx b/src/Hooks/MutationNotifications/useCloneComposeWithNotification.tsx index 80178d37..fa5da4b6 100644 --- a/src/Hooks/MutationNotifications/useCloneComposeWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useCloneComposeWithNotification.tsx @@ -14,7 +14,7 @@ export const useCloneComposeWithNotification = () => { `Your image is being shared to ${cloneRequest.region} region`, error: () => 'Your image could not be shared', }, - } + }, ); return { diff --git a/src/Hooks/MutationNotifications/useComposeBPWithNotification.tsx b/src/Hooks/MutationNotifications/useComposeBPWithNotification.tsx index 61ef2b28..d20d4f77 100644 --- a/src/Hooks/MutationNotifications/useComposeBPWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useComposeBPWithNotification.tsx @@ -10,7 +10,7 @@ export const useComposeBPWithNotification = () => { success: () => 'Image is being built', error: () => 'Image could not be built', }, - } + }, ); return { diff --git a/src/Hooks/MutationNotifications/useCreateBPWithNotification.tsx b/src/Hooks/MutationNotifications/useCreateBPWithNotification.tsx index 182679e4..6995523d 100644 --- a/src/Hooks/MutationNotifications/useCreateBPWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useCreateBPWithNotification.tsx @@ -14,7 +14,7 @@ export const useCreateBPWithNotification = (options?: HookOptions) => { success: () => 'Blueprint was created', error: () => 'Blueprint could not be created', }, - } + }, ); return { diff --git a/src/Hooks/MutationNotifications/useDeleteBPWithNotification.tsx b/src/Hooks/MutationNotifications/useDeleteBPWithNotification.tsx index 40a331fa..b460c3ab 100644 --- a/src/Hooks/MutationNotifications/useDeleteBPWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useDeleteBPWithNotification.tsx @@ -14,7 +14,7 @@ export const useDeleteBPWithNotification = (options?: HookOptions) => { success: () => 'Blueprint was deleted', error: () => 'Blueprint could not be deleted', }, - } + }, ); return { diff --git a/src/Hooks/MutationNotifications/useFixupBPWithNotification.tsx b/src/Hooks/MutationNotifications/useFixupBPWithNotification.tsx index d2cb62be..f66b412d 100644 --- a/src/Hooks/MutationNotifications/useFixupBPWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useFixupBPWithNotification.tsx @@ -14,7 +14,7 @@ export const useFixupBPWithNotification = (options?: HookOptions) => { success: () => 'Blueprint was fixed', error: () => 'Blueprint could not be fixed', }, - } + }, ); return { diff --git a/src/Hooks/MutationNotifications/useMutationWithNotification.tsx b/src/Hooks/MutationNotifications/useMutationWithNotification.tsx index 5a32444b..bf285ffa 100644 --- a/src/Hooks/MutationNotifications/useMutationWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useMutationWithNotification.tsx @@ -53,9 +53,9 @@ export function useMutationWithNotification< }, >( mutationHook: ( - options?: HookOptions + options?: HookOptions, ) => readonly [TypedMutationTrigger<Result, Arg, BaseQueryFn>, State], - { options, messages }: MutationOptions<Arg> + { options, messages }: MutationOptions<Arg>, ) { const [trigger, state] = mutationHook(options); const addNotification = useAddNotification(); diff --git a/src/Hooks/MutationNotifications/useUpdateBPWithNotification.tsx b/src/Hooks/MutationNotifications/useUpdateBPWithNotification.tsx index 9a0f9e21..532bc71a 100644 --- a/src/Hooks/MutationNotifications/useUpdateBPWithNotification.tsx +++ b/src/Hooks/MutationNotifications/useUpdateBPWithNotification.tsx @@ -14,7 +14,7 @@ export const useUpdateBPWithNotification = (options?: HookOptions) => { success: () => 'Blueprint was updated', error: () => 'Blueprint could not be updated', }, - } + }, ); return { trigger: updateBlueprint, diff --git a/src/Router.tsx b/src/Router.tsx index a9427074..b7dce6b6 100644 --- a/src/Router.tsx +++ b/src/Router.tsx @@ -8,13 +8,13 @@ import { useFlagWithEphemDefault } from './Utilities/useGetEnvironment'; const LandingPage = lazy(() => import('./Components/LandingPage/LandingPage')); const ImportImageWizard = lazy( - () => import('./Components/CreateImageWizard/ImportImageWizard') + () => import('./Components/CreateImageWizard/ImportImageWizard'), ); const CreateImageWizard = lazy(() => import('./Components/CreateImageWizard')); export const Router = () => { const importExportFlag = useFlagWithEphemDefault( - 'image-builder.import.enabled' + 'image-builder.import.enabled', ); return ( <Routes> diff --git a/src/Utilities/analytics.ts b/src/Utilities/analytics.ts index 09beb482..7723c122 100644 --- a/src/Utilities/analytics.ts +++ b/src/Utilities/analytics.ts @@ -5,7 +5,7 @@ import { CreateBlueprintRequest } from '../store/imageBuilderApi'; export const createAnalytics = ( requestBody: CreateBlueprintRequest, packages: IBPackageWithRepositoryInfo[], - isBeta: () => boolean + isBeta: () => boolean, ) => { const analyticsData = { image_name: requestBody.name, @@ -13,10 +13,10 @@ export const createAnalytics = ( distribution: requestBody.distribution, openscap: requestBody.customizations.openscap, image_request_types: requestBody.image_requests.map( - (req) => req.image_type + (req) => req.image_type, ), image_request_architectures: requestBody.image_requests.map( - (req) => req.architecture + (req) => req.architecture, ), image_requests: requestBody.image_requests, organization: requestBody.customizations.subscription?.organization, diff --git a/src/Utilities/epel.ts b/src/Utilities/epel.ts index 09005536..8c0315a7 100644 --- a/src/Utilities/epel.ts +++ b/src/Utilities/epel.ts @@ -46,7 +46,7 @@ const getKeyForDistribution = (distribution: string): string => * @returns The matching EPEL repository definition, or `undefined` if no match is found. */ export const getEpelDefinitionForDistribution = ( - distribution: string + distribution: string, ): EpelRepoDefinition | undefined => epelMap.get(getKeyForDistribution(distribution)); @@ -57,7 +57,7 @@ export const getEpelDefinitionForDistribution = ( * @returns The URL for the EPEL repository, or `undefined` if no match is found. */ export const getEpelUrlForDistribution = ( - distribution: string + distribution: string, ): string | undefined => getEpelDefinitionForDistribution(distribution)?.url; /** @@ -67,7 +67,7 @@ export const getEpelUrlForDistribution = ( * @returns The version number for the EPEL repository, or `undefined` if no match is found. */ export const getEpelVersionForDistribution = ( - distribution: string + distribution: string, ): string | undefined => { const split = getKeyForDistribution(distribution).split('-'); return split.length > 1 ? split[1] : undefined; diff --git a/src/Utilities/sortfn.ts b/src/Utilities/sortfn.ts index 2b5a8d75..fda9d218 100644 --- a/src/Utilities/sortfn.ts +++ b/src/Utilities/sortfn.ts @@ -1,7 +1,7 @@ const sortfn = ( a: string | undefined, b: string | undefined, - searchTerm: string + searchTerm: string, ) => { if (!a) { return -1; diff --git a/src/Utilities/time.ts b/src/Utilities/time.ts index 5cef0690..a8cc6161 100644 --- a/src/Utilities/time.ts +++ b/src/Utilities/time.ts @@ -73,7 +73,7 @@ export const computeHoursToExpiration = (imageCreatedAt: string) => { // between current date and the date of the image creation const msInHour = 1000 * 60 * 60; const timeUntilExpiration = Math.floor( - (currentTime - convertStringToDate(imageCreatedAt)) / msInHour + (currentTime - convertStringToDate(imageCreatedAt)) / msInHour, ); return timeUntilExpiration; } else { diff --git a/src/Utilities/useComposerStatus.tsx b/src/Utilities/useComposerStatus.tsx index c3af9984..2ebcd2e8 100644 --- a/src/Utilities/useComposerStatus.tsx +++ b/src/Utilities/useComposerStatus.tsx @@ -11,7 +11,7 @@ export const useGetComposerSocketStatus = () => { try { const result = await cockpit.spawn( ['systemctl', 'is-enabled', 'osbuild-composer.socket'], - { superuser: 'try' } + { superuser: 'try' }, ); setEnabled((result as string).trim() === 'enabled'); } catch { @@ -24,7 +24,7 @@ export const useGetComposerSocketStatus = () => { try { const result = await cockpit.spawn( ['systemctl', 'is-active', 'osbuild-composer.socket'], - { superuser: 'try' } + { superuser: 'try' }, ); setStarted((result as string).trim() === 'active'); } catch { diff --git a/src/Utilities/useDebounce.tsx b/src/Utilities/useDebounce.tsx index d104ef96..7d876f3e 100644 --- a/src/Utilities/useDebounce.tsx +++ b/src/Utilities/useDebounce.tsx @@ -6,7 +6,7 @@ import { DEBOUNCED_SEARCH_WAIT_TIME } from '../constants'; function useDebounce<T>( value: T, - delay: number = DEBOUNCED_SEARCH_WAIT_TIME + delay: number = DEBOUNCED_SEARCH_WAIT_TIME, ): T { const [debouncedValue, setDebouncedValue] = useState<T>(value); @@ -15,7 +15,7 @@ function useDebounce<T>( if (!isEqual(value, debouncedValue)) { const timer = setTimeout( () => setDebouncedValue(value), - value === '' ? 0 : delay //If value is empty string, instantly return + value === '' ? 0 : delay, //If value is empty string, instantly return ); return () => { diff --git a/src/Utilities/useGetEnvironment.ts b/src/Utilities/useGetEnvironment.ts index db6dc91f..8b2ad39a 100644 --- a/src/Utilities/useGetEnvironment.ts +++ b/src/Utilities/useGetEnvironment.ts @@ -22,7 +22,7 @@ export const useGetEnvironment = process.env.IS_ON_PREMISE */ export const useFlagWithEphemDefault = ( flag: string, - ephemDefault: boolean = true + ephemDefault: boolean = true, ): boolean => { const getFlag = useFlag(flag); const { getEnvironment } = useChrome(); diff --git a/src/Utilities/useOnPremOpenSCAP.tsx b/src/Utilities/useOnPremOpenSCAP.tsx index 6629ed4f..d1b369cf 100644 --- a/src/Utilities/useOnPremOpenSCAP.tsx +++ b/src/Utilities/useOnPremOpenSCAP.tsx @@ -15,7 +15,7 @@ export const useOnPremOpenSCAPAvailable = () => { .then((res: string) => { setPackagesAvailable( res.includes('openscap-scanner') && - res.includes('scap-security-guide') + res.includes('scap-security-guide'), ); setIsLoading(false); }) diff --git a/src/Utilities/useProvisioningPermissions.ts b/src/Utilities/useProvisioningPermissions.ts index ca0a7828..3031f7e2 100644 --- a/src/Utilities/useProvisioningPermissions.ts +++ b/src/Utilities/useProvisioningPermissions.ts @@ -8,19 +8,19 @@ const useProvisioningPermissions = () => { APP, [...GLOBAL_PERMISSIONS, 'provisioning:reservation.aws:write'], false, - true + true, ); const { hasAccess: hasAzureAccess, isLoading: azureLoading } = usePermissions( APP, [...GLOBAL_PERMISSIONS, 'provisioning:reservation.azure:write'], false, - true + true, ); const { hasAccess: hasGCPAccess, isLoading: gcpLoading } = usePermissions( APP, [...GLOBAL_PERMISSIONS, 'provisioning:reservation.gcp:write'], false, - true + true, ); const isLoading = awsLoading || azureLoading || gcpLoading; return { diff --git a/src/store/BlueprintSlice.ts b/src/store/BlueprintSlice.ts index cc18a3e8..511fc46f 100644 --- a/src/store/BlueprintSlice.ts +++ b/src/store/BlueprintSlice.ts @@ -29,7 +29,7 @@ export const selectLimit = (state: RootState) => state.blueprints.limit; export const selectBlueprintVersionFilter = (state: RootState) => state.blueprints.versionFilter; export const selectBlueprintVersionFilterAPI = ( - state: RootState + state: RootState, ): number | undefined => { const blueprintVersionFilter = state.blueprints.versionFilter; // We allow only 'latest' filtering, everything else is understood as 'all' @@ -48,7 +48,7 @@ export const blueprintsSlice = createSlice({ }, setBlueprintSearchInput: ( state, - action: PayloadAction<string | undefined> + action: PayloadAction<string | undefined>, ) => { state.searchInput = action.payload; }, @@ -60,7 +60,7 @@ export const blueprintsSlice = createSlice({ }, setBlueprintVersionFilter: ( state, - action: PayloadAction<versionFilterType> + action: PayloadAction<versionFilterType>, ) => { state.versionFilter = action.payload; }, diff --git a/src/store/cockpit/baseQuery.ts b/src/store/cockpit/baseQuery.ts index 482204a2..bac653e6 100644 --- a/src/store/cockpit/baseQuery.ts +++ b/src/store/cockpit/baseQuery.ts @@ -5,7 +5,7 @@ import type { Headers, Method, Params } from './types.js'; export const baseQuery = ( - { baseUrl }: { baseUrl: string } = { baseUrl: '' } + { baseUrl }: { baseUrl: string } = { baseUrl: '' }, ): BaseQueryFn< { url: string; @@ -60,7 +60,7 @@ export const baseQuery = body, }); } - } + }, ); }); }; diff --git a/src/store/cockpit/cockpitApi.ts b/src/store/cockpit/cockpitApi.ts index b2487b29..aafdcf14 100644 --- a/src/store/cockpit/cockpitApi.ts +++ b/src/store/cockpit/cockpitApi.ts @@ -104,7 +104,7 @@ const readComposes = async (bpID: string) => { ['entries', 'mtime'], { superuser: 'try', - } + }, ); const bpEntries = Object.entries(bpInfo?.entries || {}); for (const entry of bpEntries) { @@ -130,7 +130,7 @@ const readComposes = async (bpID: string) => { const getCloudConfigs = async () => { try { const worker_config = cockpit.file( - '/etc/osbuild-worker/osbuild-worker.toml' + '/etc/osbuild-worker/osbuild-worker.toml', ); const contents = await worker_config.read(); const parsed = TOML.parse(contents); @@ -143,7 +143,7 @@ const getCloudConfigs = async () => { const mapToOnpremRequest = ( blueprint: Blueprint, distribution: string, - image_requests: CockpitImageRequest[] + image_requests: CockpitImageRequest[], ) => { return { blueprint, @@ -252,7 +252,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ let blueprints: BlueprintItem[] = await Promise.all( entries.map(async ([filename]) => { const file = cockpit.file( - path.join(blueprintsDir, filename, `${filename}.json`) + path.join(blueprintsDir, filename, `${filename}.json`), ); const contents = await file.read(); const parsed = JSON.parse(contents); @@ -262,7 +262,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ version: 1, last_modified_at: Date.now().toString(), }; - }) + }), ); blueprints = blueprints.filter((blueprint) => { @@ -318,7 +318,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ const blueprintsDir = await getBlueprintsPath(); await cockpit.spawn( ['mkdir', '-p', path.join(blueprintsDir, id)], - {} + {}, ); await cockpit .file(path.join(blueprintsDir, id, `${id}.json`)) @@ -390,7 +390,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ ], { superuser: 'try', - } + }, )) as string; const profiles = result @@ -428,7 +428,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ ], { superuser: 'try', - } + }, )) as string; const parsed = TOML.parse(result); @@ -444,7 +444,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ ], { superuser: 'try', - } + }, )) as string; const descriptionLine = result @@ -480,7 +480,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ try { const blueprintsDir = await getBlueprintsPath(); const file = cockpit.file( - path.join(blueprintsDir, filename, `${filename}.json`) + path.join(blueprintsDir, filename, `${filename}.json`), ); const contents = await file.read(); const parsed = JSON.parse(contents); @@ -512,8 +512,8 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ mapToOnpremRequest( mapHostedToOnPrem(blueprint as CreateBlueprintRequest), crcComposeRequest.distribution, - [ir] - ) + [ir], + ), ), headers: { 'content-type': 'application/json', @@ -636,7 +636,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ await cockpit.spawn( ['touch', '/etc/osbuild-worker/osbuild-worker.toml'], - { superuser: 'require' } + { superuser: 'require' }, ); const config = await cockpit @@ -659,7 +659,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ '/etc/osbuild-worker/osbuild-worker.toml', { superuser: 'required', - } + }, ); const contents = await workerConfig.modify((prev: string) => { @@ -705,7 +705,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ ], { superuser: 'require', - } + }, ); await cockpit.spawn( @@ -719,7 +719,7 @@ export const cockpitApi = contentSourcesApi.injectEndpoints({ ], { superuser: 'require', - } + }, ); return { data: TOML.parse(contents) }; diff --git a/src/store/helpers.ts b/src/store/helpers.ts index 4b72380b..2862fd17 100644 --- a/src/store/helpers.ts +++ b/src/store/helpers.ts @@ -1,5 +1,5 @@ import type { V1ListSourceResponse } from './provisioningApi'; export const extractProvisioningList = ( - list: V1ListSourceResponse | undefined + list: V1ListSourceResponse | undefined, ) => list?.data; diff --git a/src/store/index.ts b/src/store/index.ts index 3759201a..bb840a47 100644 --- a/src/store/index.ts +++ b/src/store/index.ts @@ -63,11 +63,11 @@ startAppListening({ })(state as serviceState); const allowedImageTypes = architecturesResponse.data?.find( - (elem) => elem.arch === architecture + (elem) => elem.arch === architecture, )?.image_types; const filteredImageTypes = imageTypes.filter((imageType: string) => - allowedImageTypes?.includes(imageType) + allowedImageTypes?.includes(imageType), ); listenerApi.dispatch(changeImageTypes(filteredImageTypes)); @@ -93,11 +93,11 @@ startAppListening({ })(state as serviceState); const allowedImageTypes = architecturesResponse?.data?.find( - (elem) => elem.arch === architecture + (elem) => elem.arch === architecture, )?.image_types; const filteredImageTypes = imageTypes.filter((imageType: string) => - allowedImageTypes?.includes(imageType) + allowedImageTypes?.includes(imageType), ); listenerApi.dispatch(changeImageTypes(filteredImageTypes)); @@ -116,7 +116,7 @@ export const serviceMiddleware = (getDefaultMiddleware: Function) => imageBuilderApi.middleware, rhsmApi.middleware, provisioningApi.middleware, - complianceApi.middleware + complianceApi.middleware, ); // Listener middleware must be prepended according to RTK docs: @@ -132,7 +132,7 @@ export const onPremMiddleware = (getDefaultMiddleware: Function) => provisioningApi.middleware, complianceApi.middleware, imageBuilderApi.middleware, - cockpitApi.middleware + cockpitApi.middleware, ); export const onPremStore = configureStore({ diff --git a/src/store/service/enhancedImageBuilderApi.ts b/src/store/service/enhancedImageBuilderApi.ts index 0d50ea94..373fd687 100644 --- a/src/store/service/enhancedImageBuilderApi.ts +++ b/src/store/service/enhancedImageBuilderApi.ts @@ -52,7 +52,7 @@ const enhancedApi = imageBuilderApi.enhanceEndpoints({ queryFulfilled.then(() => { dispatch( // @ts-expect-error Typescript is unaware of tag types being defined concurrently in enhanceEndpoints() - imageBuilderApi.util.invalidateTags(['Blueprints', 'Blueprint']) + imageBuilderApi.util.invalidateTags(['Blueprints', 'Blueprint']), ); }); }, @@ -72,7 +72,7 @@ const enhancedApi = imageBuilderApi.enhanceEndpoints({ imageBuilderApi.util.invalidateTags([ // @ts-expect-error Typescript is unaware of tag types being defined concurrently in enhanceEndpoints() { type: 'Clone', id: composeId }, - ]) + ]), ); }); }, @@ -85,7 +85,7 @@ const enhancedApi = imageBuilderApi.enhanceEndpoints({ queryFulfilled.then(() => { dispatch( // @ts-expect-error Typescript is unaware of tag types being defined concurrently in enhanceEndpoints() - imageBuilderApi.util.invalidateTags(['Blueprints', 'Compose']) + imageBuilderApi.util.invalidateTags(['Blueprints', 'Compose']), ); }); }, diff --git a/src/store/typeGuards.ts b/src/store/typeGuards.ts index fbcfceca..291d820e 100644 --- a/src/store/typeGuards.ts +++ b/src/store/typeGuards.ts @@ -11,43 +11,43 @@ import { } from './imageBuilderApi'; export const isGcpUploadRequestOptions = ( - options: UploadRequest['options'] + options: UploadRequest['options'], ): options is GcpUploadRequestOptions => { return true; }; export const isAwsUploadRequestOptions = ( - options: UploadRequest['options'] + options: UploadRequest['options'], ): options is AwsUploadRequestOptions => { return true; }; export const isAzureUploadRequestOptions = ( - options: UploadRequest['options'] + options: UploadRequest['options'], ): options is AzureUploadRequestOptions => { return (options as AzureUploadRequestOptions).resource_group !== undefined; }; export const isGcpUploadStatus = ( - status: UploadStatus['options'] + status: UploadStatus['options'], ): status is GcpUploadStatus => { return (status as GcpUploadStatus).project_id !== undefined; }; export const isOciUploadStatus = ( - status: UploadStatus['options'] + status: UploadStatus['options'], ): status is OciUploadStatus => { return (status as OciUploadStatus).url !== undefined; }; export const isAwss3UploadStatus = ( - status: UploadStatus['options'] + status: UploadStatus['options'], ): status is Awss3UploadStatus => { return (status as Awss3UploadStatus).url !== undefined; }; export const isAzureUploadStatus = ( - status: UploadStatus['options'] + status: UploadStatus['options'], ): status is AzureUploadStatus => { return (status as AzureUploadStatus).image_name !== undefined; }; diff --git a/src/store/wizardSlice.ts b/src/store/wizardSlice.ts index 36d9af71..2fde3b5a 100644 --- a/src/store/wizardSlice.ts +++ b/src/store/wizardSlice.ts @@ -519,7 +519,7 @@ export const wizardSlice = createSlice({ }, changeArchitecture: ( state, - action: PayloadAction<ImageRequest['architecture']> + action: PayloadAction<ImageRequest['architecture']>, ) => { state.architecture = action.payload; }, @@ -529,13 +529,13 @@ export const wizardSlice = createSlice({ addImageType: (state, action: PayloadAction<ImageTypes>) => { // Remove (if present) before adding to avoid duplicates state.imageTypes = state.imageTypes.filter( - (imageType) => imageType !== action.payload + (imageType) => imageType !== action.payload, ); state.imageTypes.push(action.payload); }, removeImageType: (state, action: PayloadAction<ImageTypes>) => { state.imageTypes = state.imageTypes.filter( - (imageType) => imageType !== action.payload + (imageType) => imageType !== action.payload, ); }, changeImageTypes: (state, action: PayloadAction<ImageTypes[]>) => { @@ -564,7 +564,7 @@ export const wizardSlice = createSlice({ }, changeAzureShareMethod: ( state, - action: PayloadAction<AzureShareMethod> + action: PayloadAction<AzureShareMethod>, ) => { state.azure.shareMethod = action.payload; }, @@ -579,7 +579,7 @@ export const wizardSlice = createSlice({ }, changeAzureHyperVGeneration: ( state, - action: PayloadAction<'V1' | 'V2'> + action: PayloadAction<'V1' | 'V2'>, ) => { state.azure.hyperVGeneration = action.payload; }, @@ -614,13 +614,13 @@ export const wizardSlice = createSlice({ }, changeRegistrationType: ( state, - action: PayloadAction<RegistrationType> + action: PayloadAction<RegistrationType>, ) => { state.registration.registrationType = action.payload; }, changeSatelliteRegistrationCommand: ( state, - action: PayloadAction<string> + action: PayloadAction<string>, ) => { state.registration.satelliteRegistration.command = action.payload; }, @@ -629,7 +629,7 @@ export const wizardSlice = createSlice({ }, changeActivationKey: ( state, - action: PayloadAction<ActivationKeys['name']> + action: PayloadAction<ActivationKeys['name']>, ) => { state.registration.activationKey = action.payload; }, @@ -642,7 +642,7 @@ export const wizardSlice = createSlice({ policyID: string | undefined; profileID: string | undefined; policyTitle: string | undefined; - }> + }>, ) => { state.compliance.policyID = action.payload.policyID; state.compliance.profileID = action.payload.profileID; @@ -651,13 +651,13 @@ export const wizardSlice = createSlice({ changeFileSystemConfiguration: ( state, - action: PayloadAction<Partition[]> + action: PayloadAction<Partition[]>, ) => { state.fileSystem.partitions = action.payload; }, changeFileSystemConfigurationType: ( state, - action: PayloadAction<FileSystemConfigurationType> + action: PayloadAction<FileSystemConfigurationType>, ) => { const currentMode = state.fileSystem.mode; @@ -700,7 +700,7 @@ export const wizardSlice = createSlice({ }, removePartition: (state, action: PayloadAction<Partition['id']>) => { const index = state.fileSystem.partitions.findIndex( - (partition) => partition.id === action.payload + (partition) => partition.id === action.payload, ); if (index !== -1) { state.fileSystem.partitions.splice(index, 1); @@ -708,10 +708,10 @@ export const wizardSlice = createSlice({ }, removePartitionByMountpoint: ( state, - action: PayloadAction<Partition['mountpoint']> + action: PayloadAction<Partition['mountpoint']>, ) => { const index = state.fileSystem.partitions.findIndex( - (partition) => partition.mountpoint === action.payload + (partition) => partition.mountpoint === action.payload, ); if (index !== -1) { state.fileSystem.partitions.splice(index, 1); @@ -719,16 +719,16 @@ export const wizardSlice = createSlice({ }, changePartitionOrder: (state, action: PayloadAction<string[]>) => { state.fileSystem.partitions = state.fileSystem.partitions.sort( - (a, b) => action.payload.indexOf(a.id) - action.payload.indexOf(b.id) + (a, b) => action.payload.indexOf(a.id) - action.payload.indexOf(b.id), ); }, changePartitionMountpoint: ( state, - action: PayloadAction<{ id: string; mountpoint: string }> + action: PayloadAction<{ id: string; mountpoint: string }>, ) => { const { id, mountpoint } = action.payload; const partitionIndex = state.fileSystem.partitions.findIndex( - (partition) => partition.id === id + (partition) => partition.id === id, ); if (partitionIndex !== -1) { state.fileSystem.partitions[partitionIndex].mountpoint = mountpoint; @@ -736,11 +736,11 @@ export const wizardSlice = createSlice({ }, changePartitionUnit: ( state, - action: PayloadAction<{ id: string; unit: Units }> + action: PayloadAction<{ id: string; unit: Units }>, ) => { const { id, unit } = action.payload; const partitionIndex = state.fileSystem.partitions.findIndex( - (partition) => partition.id === id + (partition) => partition.id === id, ); if (partitionIndex !== -1) { state.fileSystem.partitions[partitionIndex].unit = unit; @@ -748,11 +748,11 @@ export const wizardSlice = createSlice({ }, changePartitionMinSize: ( state, - action: PayloadAction<{ id: string; min_size: string }> + action: PayloadAction<{ id: string; min_size: string }>, ) => { const { id, min_size } = action.payload; const partitionIndex = state.fileSystem.partitions.findIndex( - (partition) => partition.id === id + (partition) => partition.id === id, ); if (partitionIndex !== -1) { state.fileSystem.partitions[partitionIndex].min_size = min_size; @@ -782,7 +782,7 @@ export const wizardSlice = createSlice({ }, importCustomRepositories: ( state, - action: PayloadAction<CustomRepository[]> + action: PayloadAction<CustomRepository[]>, ) => { state.repositories.customRepositories = [ ...state.repositories.customRepositories, @@ -791,7 +791,7 @@ export const wizardSlice = createSlice({ }, changeCustomRepositories: ( state, - action: PayloadAction<CustomRepository[]> + action: PayloadAction<CustomRepository[]>, ) => { state.repositories.customRepositories = action.payload; }, @@ -803,11 +803,11 @@ export const wizardSlice = createSlice({ }, addRecommendedRepository: ( state, - action: PayloadAction<ApiRepositoryResponseRead> + action: PayloadAction<ApiRepositoryResponseRead>, ) => { if ( !state.repositories.recommendedRepositories.some( - (repo) => repo.url === action.payload.url + (repo) => repo.url === action.payload.url, ) ) { state.repositories.recommendedRepositories.push(action.payload); @@ -815,16 +815,16 @@ export const wizardSlice = createSlice({ }, removeRecommendedRepository: ( state, - action: PayloadAction<ApiRepositoryResponseRead> + action: PayloadAction<ApiRepositoryResponseRead>, ) => { state.repositories.recommendedRepositories = state.repositories.recommendedRepositories.filter( - (repo) => repo.url !== action.payload.url + (repo) => repo.url !== action.payload.url, ); }, addPackage: (state, action: PayloadAction<IBPackageWithRepositoryInfo>) => { const existingPackageIndex = state.packages.findIndex( - (pkg) => pkg.name === action.payload.name + (pkg) => pkg.name === action.payload.name, ); if (existingPackageIndex !== -1) { @@ -835,10 +835,10 @@ export const wizardSlice = createSlice({ }, removePackage: ( state, - action: PayloadAction<IBPackageWithRepositoryInfo['name']> + action: PayloadAction<IBPackageWithRepositoryInfo['name']>, ) => { const index = state.packages.findIndex( - (pkg) => pkg.name === action.payload + (pkg) => pkg.name === action.payload, ); if (index !== -1) { state.packages.splice(index, 1); @@ -846,7 +846,7 @@ export const wizardSlice = createSlice({ }, addModule: (state, action: PayloadAction<Module>) => { const existingModuleIndex = state.enabled_modules.findIndex( - (module) => module.name === action.payload.name + (module) => module.name === action.payload.name, ); if (existingModuleIndex !== -1) { @@ -857,11 +857,11 @@ export const wizardSlice = createSlice({ }, removeModule: (state, action: PayloadAction<Module['name']>) => { const index = state.enabled_modules.findIndex( - (module) => module.name === action.payload + (module) => module.name === action.payload, ); // count other packages from the same module const pkgCount = state.packages.filter( - (pkg) => pkg.module_name === action.payload + (pkg) => pkg.module_name === action.payload, ); // if the module exists and it's not connected to any packages, remove it if (index !== -1 && pkgCount.length < 1) { @@ -870,7 +870,7 @@ export const wizardSlice = createSlice({ }, addGroup: (state, action: PayloadAction<GroupWithRepositoryInfo>) => { const existingGrpIndex = state.groups.findIndex( - (grp) => grp.name === action.payload.name + (grp) => grp.name === action.payload.name, ); if (existingGrpIndex !== -1) { @@ -881,10 +881,10 @@ export const wizardSlice = createSlice({ }, removeGroup: ( state, - action: PayloadAction<GroupWithRepositoryInfo['name']> + action: PayloadAction<GroupWithRepositoryInfo['name']>, ) => { const index = state.groups.findIndex( - (grp) => grp.name === action.payload + (grp) => grp.name === action.payload, ); if (index !== -1) { state.groups.splice(index, 1); @@ -901,7 +901,7 @@ export const wizardSlice = createSlice({ removeLanguage: (state, action: PayloadAction<string>) => { if (state.locale.languages) { const index = state.locale.languages.findIndex( - (lang) => lang === action.payload + (lang) => lang === action.payload, ); if (index !== -1) { state.locale.languages.splice(index, 1); @@ -938,7 +938,7 @@ export const wizardSlice = createSlice({ }, removeEnabledService: (state, action: PayloadAction<string>) => { const index = state.services.enabled.findIndex( - (service) => service === action.payload + (service) => service === action.payload, ); if (index !== -1) { state.services.enabled.splice(index, 1); @@ -956,7 +956,7 @@ export const wizardSlice = createSlice({ }, removeMaskedService: (state, action: PayloadAction<string>) => { const index = state.services.masked.findIndex( - (service) => service === action.payload + (service) => service === action.payload, ); if (index !== -1) { state.services.masked.splice(index, 1); @@ -974,7 +974,7 @@ export const wizardSlice = createSlice({ }, removeDisabledService: (state, action: PayloadAction<string>) => { const index = state.services.disabled.findIndex( - (service) => service === action.payload + (service) => service === action.payload, ); if (index !== -1) { state.services.disabled.splice(index, 1); @@ -985,7 +985,7 @@ export const wizardSlice = createSlice({ }, addKernelArg: (state, action: PayloadAction<string>) => { const existingArgIndex = state.kernel.append.findIndex( - (arg) => arg === action.payload + (arg) => arg === action.payload, ); if (existingArgIndex !== -1) { @@ -997,7 +997,7 @@ export const wizardSlice = createSlice({ removeKernelArg: (state, action: PayloadAction<string>) => { if (state.kernel.append.length > 0) { const index = state.kernel.append.findIndex( - (arg) => arg === action.payload + (arg) => arg === action.payload, ); if (index !== -1) { state.kernel.append.splice(index, 1); @@ -1010,7 +1010,7 @@ export const wizardSlice = createSlice({ addEnabledFirewallService: (state, action: PayloadAction<string>) => { if ( !state.firewall.services.enabled.some( - (service) => service === action.payload + (service) => service === action.payload, ) ) { state.firewall.services.enabled.push(action.payload); @@ -1018,7 +1018,7 @@ export const wizardSlice = createSlice({ }, removeEnabledFirewallService: (state, action: PayloadAction<string>) => { const index = state.firewall.services.enabled.findIndex( - (service) => service === action.payload + (service) => service === action.payload, ); if (index !== -1) { state.firewall.services.enabled.splice(index, 1); @@ -1027,7 +1027,7 @@ export const wizardSlice = createSlice({ addDisabledFirewallService: (state, action: PayloadAction<string>) => { if ( !state.firewall.services.disabled.some( - (service) => service === action.payload + (service) => service === action.payload, ) ) { state.firewall.services.disabled.push(action.payload); @@ -1035,7 +1035,7 @@ export const wizardSlice = createSlice({ }, removeDisabledFirewallService: (state, action: PayloadAction<string>) => { const index = state.firewall.services.disabled.findIndex( - (service) => service === action.payload + (service) => service === action.payload, ); if (index !== -1) { state.firewall.services.disabled.splice(index, 1); @@ -1054,7 +1054,7 @@ export const wizardSlice = createSlice({ removeNtpServer: (state, action: PayloadAction<string>) => { if (state.timezone.ntpservers) { const index = state.timezone.ntpservers.findIndex( - (server) => server === action.payload + (server) => server === action.payload, ); if (index !== -1) { state.timezone.ntpservers.splice(index, 1); @@ -1084,7 +1084,7 @@ export const wizardSlice = createSlice({ }, setUserPasswordByIndex: ( state, - action: PayloadAction<UserPasswordPayload> + action: PayloadAction<UserPasswordPayload>, ) => { state.users[action.payload.index].password = action.payload.password; }, @@ -1098,7 +1098,7 @@ export const wizardSlice = createSlice({ }, removePort: (state, action: PayloadAction<string>) => { const index = state.firewall.ports.findIndex( - (port) => port === action.payload + (port) => port === action.payload, ); if (index !== -1) { state.firewall.ports.splice(index, 1); @@ -1106,7 +1106,7 @@ export const wizardSlice = createSlice({ }, setUserAdministratorByIndex: ( state, - action: PayloadAction<UserAdministratorPayload> + action: PayloadAction<UserAdministratorPayload>, ) => { const { index, isAdministrator } = action.payload; const user = state.users[index]; @@ -1121,7 +1121,7 @@ export const wizardSlice = createSlice({ addUserGroupByIndex: (state, action: PayloadAction<UserGroupPayload>) => { if ( !state.users[action.payload.index].groups.some( - (group) => group === action.payload.group + (group) => group === action.payload.group, ) ) { state.users[action.payload.index].groups.push(action.payload.group); @@ -1129,10 +1129,10 @@ export const wizardSlice = createSlice({ }, removeUserGroupByIndex: ( state, - action: PayloadAction<UserGroupPayload> + action: PayloadAction<UserGroupPayload>, ) => { const groupIndex = state.users[action.payload.index].groups.findIndex( - (group) => group === action.payload.group + (group) => group === action.payload.group, ); if (groupIndex !== -1) { if (action.payload.group === 'wheel') { diff --git a/src/test/Components/Blueprints/Blueprints.test.tsx b/src/test/Components/Blueprints/Blueprints.test.tsx index 969f09da..70fbe481 100644 --- a/src/test/Components/Blueprints/Blueprints.test.tsx +++ b/src/test/Components/Blueprints/Blueprints.test.tsx @@ -30,7 +30,7 @@ const selectBlueprintByNameAndId = async (name: string, bpId: string) => { await waitFor(() => user.clear(search)); await waitFor(() => user.type(search, name)); expect(screen.getByRole('textbox', { name: /search input/i })).toHaveValue( - name + name, ); await screen.findByText('compliance'); @@ -62,7 +62,7 @@ describe('Blueprints', () => { server.use( http.get(`${IMAGE_BUILDER_API}/blueprints`, () => { return HttpResponse.json(emptyGetBlueprints); - }) + }), ); const view = renderCustomRoutesWithReduxRouter(); @@ -77,8 +77,8 @@ describe('Blueprints', () => { const { router } = await view; await waitFor(() => expect(router.state.location.pathname).toBe( - '/insights/image-builder/imagewizard' - ) + '/insights/image-builder/imagewizard', + ), ); }); test('renders blueprint composes', async () => { @@ -163,14 +163,14 @@ describe('Blueprints', () => { await selectBlueprintById(blueprintIdOutOfSync); await screen.findByText( - 'The selected blueprint is at version 2, the latest images are at version 1. Build images to synchronize with the latest version.' + 'The selected blueprint is at version 2, the latest images are at version 1. Build images to synchronize with the latest version.', ); await selectBlueprintById(blueprintIdWithComposes); expect( screen.queryByText( - 'The selected blueprint is at version 2, the latest images are at version 1. Build images to synchronize with the latest version.' - ) + 'The selected blueprint is at version 2, the latest images are at version 1. Build images to synchronize with the latest version.', + ), ).not.toBeInTheDocument(); }); @@ -179,14 +179,14 @@ describe('Blueprints', () => { await selectBlueprintById(blueprintIdCentos8); await screen.findByText( - /CentOS Stream 8 is no longer supported, building images from this blueprint will fail./ + /CentOS Stream 8 is no longer supported, building images from this blueprint will fail./, ); await selectBlueprintById(blueprintIdWithComposes); expect( screen.queryByText( - /CentOS Stream 8 is no longer supported, building images from this blueprint will fail./ - ) + /CentOS Stream 8 is no longer supported, building images from this blueprint will fail./, + ), ).not.toBeInTheDocument(); }); @@ -204,7 +204,7 @@ describe('Blueprints', () => { user.click(button); await waitFor(() => { expect( - screen.queryByText('The selected blueprint has errors.') + screen.queryByText('The selected blueprint has errors.'), ).not.toBeInTheDocument(); }); }); @@ -230,10 +230,10 @@ describe('Blueprints', () => { await renderCustomRoutesWithReduxRouter( 'imagewizard/677b010b-e95e-4694-9813-d11d847f1bfc', {}, - routes + routes, ); const blueprintDetails = await screen.findByTestId( - 'image-details-expandable' + 'image-details-expandable', ); user.click(blueprintDetails); await screen.findByText(editedBlueprintName); @@ -242,12 +242,12 @@ describe('Blueprints', () => { server.use( http.get(`${IMAGE_BUILDER_API}/blueprints/invalid-compose-id`, () => { return new HttpResponse(null, { status: 404 }); - }) + }), ); await renderCustomRoutesWithReduxRouter( 'imagewizard/invalid-compose-id', {}, - routes + routes, ); await screen.findByRole('heading', { name: /Images/i, level: 1 }); }); @@ -262,7 +262,7 @@ describe('Blueprints', () => { renderCustomRoutesWithReduxRouter(); const searchInput = await screen.findByPlaceholderText( - 'Search by name or description' + 'Search by name or description', ); searchInput.focus(); user.keyboard('Milk'); @@ -271,12 +271,12 @@ describe('Blueprints', () => { await waitFor( () => { expect( - screen.getByTestId(blueprintIdEmptyComposes) + screen.getByTestId(blueprintIdEmptyComposes), ).toBeInTheDocument(); }, { timeout: 1500, - } + }, ); }); }); @@ -334,7 +334,7 @@ describe('Blueprints', () => { }); expect( - within(screen.getByTestId('images-table')).getAllByRole('row') + within(screen.getByTestId('images-table')).getAllByRole('row'), ).toHaveLength(4); user.click(composesVersionFilter); @@ -342,8 +342,8 @@ describe('Blueprints', () => { user.click(option); await waitFor(() => expect( - within(screen.getByTestId('images-table')).getAllByRole('row') - ).toHaveLength(2) + within(screen.getByTestId('images-table')).getAllByRole('row'), + ).toHaveLength(2), ); }); }); diff --git a/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx b/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx index 5bad2736..c2d58300 100644 --- a/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx +++ b/src/test/Components/Blueprints/ImportBlueprintModal.test.tsx @@ -317,7 +317,7 @@ describe('Import modal', () => { }); expect(reviewButton).toBeDisabled(); const helperText = await screen.findByText( - /not compatible with the blueprints format\./i + /not compatible with the blueprints format\./i, ); await waitFor(() => expect(helperText).toBeInTheDocument()); }); @@ -330,7 +330,7 @@ describe('Import modal', () => { }); expect(reviewButton).toBeDisabled(); const helperText = await screen.findByText( - /not compatible with the blueprints format\./i + /not compatible with the blueprints format\./i, ); await waitFor(() => expect(helperText).toBeInTheDocument()); }); @@ -346,8 +346,8 @@ describe('Import modal', () => { await waitFor(async () => expect( - await screen.findByText('Image output', { selector: 'h1' }) - ).toBeInTheDocument() + await screen.findByText('Image output', { selector: 'h1' }), + ).toBeInTheDocument(), ); }); @@ -362,8 +362,8 @@ describe('Import modal', () => { await waitFor(async () => expect( - await screen.findByText('Image output', { selector: 'h1' }) - ).toBeInTheDocument() + await screen.findByText('Image output', { selector: 'h1' }), + ).toBeInTheDocument(), ); }); @@ -385,16 +385,16 @@ describe('Import modal', () => { await waitFor(async () => expect( - await screen.findByText('Image output', { selector: 'h1' }) - ).toBeInTheDocument() + await screen.findByText('Image output', { selector: 'h1' }), + ).toBeInTheDocument(), ); // Image output await waitFor( async () => await user.click( - await screen.findByRole('button', { name: /Amazon Web Services/i }) - ) + await screen.findByRole('button', { name: /Amazon Web Services/i }), + ), ); await clickNext(); @@ -415,7 +415,7 @@ describe('Import modal', () => { // Registration await screen.findByText( - 'Automatically register and enable advanced capabilities' + 'Automatically register and enable advanced capabilities', ); //const registrationCheckbox = await screen.findByRole('radio', { // name: /Automatically register and enable advanced capabilities/i, @@ -492,7 +492,7 @@ describe('Import modal', () => { // Kernel await clickNext(); const kernelNameInput = await screen.findByPlaceholderText( - /Select kernel package/i + /Select kernel package/i, ); expect(kernelNameInput).toHaveValue('kernel-debug'); await screen.findByText('nosmt=force'); @@ -523,7 +523,7 @@ describe('Import modal', () => { await setUp(); await uploadFile( `blueprints.toml`, - ONPREM_BLUEPRINT_TOML_WITH_INVALID_VALUES + ONPREM_BLUEPRINT_TOML_WITH_INVALID_VALUES, ); const reviewButton = screen.getByRole('button', { name: /Review and finish/i, @@ -543,7 +543,7 @@ describe('Import modal', () => { // File system configuration await clickNext(); expect( - await screen.findByText(/The Wizard only supports KiB, MiB, or GiB/) + await screen.findByText(/The Wizard only supports KiB, MiB, or GiB/), ).toBeInTheDocument(); await clickNext(); // Repository snapshot @@ -554,34 +554,34 @@ describe('Import modal', () => { await clickNext(); expect(await screen.findByText('Invalid user name')).toBeInTheDocument(); await waitFor(async () => - user.type(await screen.findByPlaceholderText('Enter username'), 'est') + user.type(await screen.findByPlaceholderText('Enter username'), 'est'), ); expect( - await screen.findByText('Password must be at least 6 characters long') + await screen.findByText('Password must be at least 6 characters long'), ).toBeInTheDocument(); await waitFor(async () => - user.clear(await screen.findByPlaceholderText('Enter password')) + user.clear(await screen.findByPlaceholderText('Enter password')), ); expect(await screen.findByText('Invalid SSH key')).toBeInTheDocument(); await waitFor(async () => user.clear( - await screen.findByPlaceholderText('Paste your public SSH key') - ) + await screen.findByPlaceholderText('Paste your public SSH key'), + ), ); expect( - await screen.findByText(/Invalid user groups: 0000/) + await screen.findByText(/Invalid user groups: 0000/), ).toBeInTheDocument(); await waitFor(() => - user.click(screen.getByRole('button', { name: /close 0000/i })) + user.click(screen.getByRole('button', { name: /close 0000/i })), ); // Timezone await clickNext(); expect(await screen.findByText('Unknown timezone')).toBeInTheDocument(); expect( - await screen.findByText('Invalid NTP servers: invalid-ntp-server') + await screen.findByText('Invalid NTP servers: invalid-ntp-server'), ).toBeInTheDocument(); const clearButtons = await screen.findAllByRole('button', { name: /clear input/i, @@ -591,29 +591,29 @@ describe('Import modal', () => { user.click( await screen.findByRole('button', { name: /close invalid-ntp-server/i, - }) - ) + }), + ), ); // Locale await clickNext(); expect( - await screen.findByText('Unknown languages: invalid-language') + await screen.findByText('Unknown languages: invalid-language'), ).toBeInTheDocument(); expect(await screen.findByText('Unknown keyboard')).toBeInTheDocument(); await waitFor(async () => user.click( await screen.findByRole('button', { name: /close invalid-language/i, - }) - ) + }), + ), ); await waitFor(async () => user.click( await screen.findByRole('button', { name: /clear input/i, - }) - ) + }), + ), ); // Hostname @@ -623,97 +623,101 @@ describe('Import modal', () => { user.clear( screen.getByRole('textbox', { name: /hostname input/i, - }) - ) + }), + ), ); // Kernel await clickNext(); expect(await screen.findByText(/Invalid format/)).toBeInTheDocument(); expect( - await screen.findByText(/Invalid kernel arguments/) + await screen.findByText(/Invalid kernel arguments/), ).toBeInTheDocument(); await waitFor(() => - user.click(screen.getAllByRole('button', { name: /clear input/i })[0]) + user.click(screen.getAllByRole('button', { name: /clear input/i })[0]), ); await waitFor(() => user.click( screen.getByRole('button', { name: /close invalid\$kernel\$argument/i, - }) - ) + }), + ), ); // Firewall await clickNext(); expect( - await screen.findByText(/Invalid ports: invalid-port/) + await screen.findByText(/Invalid ports: invalid-port/), ).toBeInTheDocument(); expect( await screen.findByText( - /Invalid disabled services: --invalid-disabled-service/ - ) + /Invalid disabled services: --invalid-disabled-service/, + ), ).toBeInTheDocument(); expect( await screen.findByText( - /Invalid enabled services: --invalid-enabled-service/ - ) + /Invalid enabled services: --invalid-enabled-service/, + ), ).toBeInTheDocument(); await waitFor(() => - user.click(screen.getByRole('button', { name: /close invalid-port/i })) + user.click(screen.getByRole('button', { name: /close invalid-port/i })), ); await waitFor(() => user.click( screen.getByRole('button', { name: /close --invalid-disabled-service/i, - }) - ) + }), + ), ); await waitFor(() => user.click( - screen.getByRole('button', { name: /close --invalid-enabled-service/i }) - ) + screen.getByRole('button', { + name: /close --invalid-enabled-service/i, + }), + ), ); // Services await clickNext(); expect( await screen.findByText( - /Invalid enabled services: --invalid-enabled-service/ - ) + /Invalid enabled services: --invalid-enabled-service/, + ), ).toBeInTheDocument(); expect( await screen.findByText( - /Invalid disabled services: --invalid-disabled-service/ - ) + /Invalid disabled services: --invalid-disabled-service/, + ), ).toBeInTheDocument(); expect( await screen.findByText( - /Invalid masked services: --invalid-masked-service/ - ) + /Invalid masked services: --invalid-masked-service/, + ), ).toBeInTheDocument(); await waitFor(() => user.click( - screen.getByRole('button', { name: /close --invalid-enabled-service/i }) - ) + screen.getByRole('button', { + name: /close --invalid-enabled-service/i, + }), + ), ); await waitFor(() => user.click( screen.getByRole('button', { name: /close --invalid-disabled-service/i, - }) - ) + }), + ), ); await waitFor(() => user.click( - screen.getByRole('button', { name: /close --invalid-masked-service/i }) - ) + screen.getByRole('button', { name: /close --invalid-masked-service/i }), + ), ); // Firstboot await clickNext(); expect( - await screen.findByRole('heading', { name: /First boot configuration/i }) + await screen.findByRole('heading', { name: /First boot configuration/i }), ).toBeInTheDocument(); }, 20000); }); diff --git a/src/test/Components/CreateImageWizard/CreateImageWizard.test.tsx b/src/test/Components/CreateImageWizard/CreateImageWizard.test.tsx index 31df6a4b..6229b3c5 100644 --- a/src/test/Components/CreateImageWizard/CreateImageWizard.test.tsx +++ b/src/test/Components/CreateImageWizard/CreateImageWizard.test.tsx @@ -14,18 +14,18 @@ const selectAllEnvironments = async () => { const user = userEvent.setup(); await waitFor(() => - user.click(screen.getByRole('button', { name: /Amazon Web Services/i })) + user.click(screen.getByRole('button', { name: /Amazon Web Services/i })), ); await waitFor(() => - user.click(screen.getByRole('button', { name: /Google Cloud Platform/i })) + user.click(screen.getByRole('button', { name: /Google Cloud Platform/i })), ); await waitFor(() => - user.click(screen.getByRole('button', { name: /Microsoft Azure/i })) + user.click(screen.getByRole('button', { name: /Microsoft Azure/i })), ); await waitFor(() => user.click( - screen.getByRole('checkbox', { name: /Virtualization guest image/i }) - ) + screen.getByRole('checkbox', { name: /Virtualization guest image/i }), + ), ); }; @@ -112,8 +112,8 @@ describe('Keyboard accessibility', () => { await waitFor(async () => user.type( await screen.findByRole('textbox', { name: /google principal/i }), - 'test@test.com' - ) + 'test@test.com', + ), ); await clickNext(); @@ -131,19 +131,19 @@ describe('Keyboard accessibility', () => { await waitFor(() => user.click(azureSource)); const resourceGroupDropdown = await screen.findByPlaceholderText( - /select resource group/i + /select resource group/i, ); await waitFor(() => user.click(resourceGroupDropdown)); await waitFor(async () => user.click( - await screen.findByLabelText('Resource group myResourceGroup1') - ) + await screen.findByLabelText('Resource group myResourceGroup1'), + ), ); await clickNext(); // Registration await screen.findByText( - 'Automatically register and enable advanced capabilities' + 'Automatically register and enable advanced capabilities', ); //const registrationCheckbox = await screen.findByRole('radio', { // name: /Automatically register and enable advanced capabilities/i, @@ -171,7 +171,7 @@ describe('Keyboard accessibility', () => { test('pressing Enter does not advance the wizard', async () => { await renderCreateMode(); user.click( - await screen.findByRole('button', { name: /Amazon Web Services/i }) + await screen.findByRole('button', { name: /Amazon Web Services/i }), ); user.keyboard('{enter}'); await screen.findByRole('heading', { @@ -183,13 +183,13 @@ describe('Keyboard accessibility', () => { await renderCreateMode(); await testTile( - await screen.findByRole('button', { name: /Amazon Web Services/i }) + await screen.findByRole('button', { name: /Amazon Web Services/i }), ); await testTile( - await screen.findByRole('button', { name: /Google Cloud Platform/i }) + await screen.findByRole('button', { name: /Google Cloud Platform/i }), ); await testTile( - await screen.findByRole('button', { name: /Microsoft Azure/i }) + await screen.findByRole('button', { name: /Microsoft Azure/i }), ); }); }); diff --git a/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx b/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx index 48dbb379..1a247e1f 100644 --- a/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Details/Details.test.tsx @@ -36,7 +36,7 @@ export const goToDetailsStep = async () => { }; const enterBlueprintDescription = async ( - description: string = 'Now with extra carmine!' + description: string = 'Now with extra carmine!', ) => { const user = userEvent.setup({ delay: null }); const blueprintDescription = await screen.findByRole('textbox', { @@ -193,7 +193,7 @@ describe('Details edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = detailsCreateBlueprintRequest; await waitFor(() => expect(receivedRequest).toEqual(expectedRequest)); diff --git a/src/test/Components/CreateImageWizard/steps/FileSystemConfiguration/FileSystemConfiguration.test.tsx b/src/test/Components/CreateImageWizard/steps/FileSystemConfiguration/FileSystemConfiguration.test.tsx index 097c1ddb..be59954a 100644 --- a/src/test/Components/CreateImageWizard/steps/FileSystemConfiguration/FileSystemConfiguration.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/FileSystemConfiguration/FileSystemConfiguration.test.tsx @@ -120,10 +120,10 @@ const goToReviewStep = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId( - 'file-system-configuration-expandable' + 'file-system-configuration-expandable', ); const revisitButton = await within(expandable).findByTestId( - 'revisit-file-system' + 'revisit-file-system', ); await waitFor(() => user.click(revisitButton)); }; @@ -157,7 +157,7 @@ describe('Step File system configuration', () => { await clickReviewAndFinish(); expect( - await screen.findByRole('button', { name: /Review and finish/ }) + await screen.findByRole('button', { name: /Review and finish/ }), ).toBeDisabled(); }); @@ -198,7 +198,7 @@ describe('Step File system configuration', () => { await selectImageInstaller(); await goToFileSystemConfigurationStep(); expect( - screen.queryByText(/manually configure partitions/i) + screen.queryByText(/manually configure partitions/i), ).not.toBeInTheDocument(); }); @@ -396,7 +396,7 @@ describe('File system configuration edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = fscCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx b/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx index 1013dbdd..0b0c52f9 100644 --- a/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Firewall/Firewall.test.tsx @@ -120,12 +120,12 @@ describe('Step Firewall', () => { await goToFirewallStep(); expect( screen.queryByText( - 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp' - ) + 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp', + ), ).not.toBeInTheDocument(); await addPort('00:wrongFormat'); await screen.findByText( - 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp' + 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp', ); }); @@ -133,11 +133,11 @@ describe('Step Firewall', () => { await renderCreateMode(); await goToFirewallStep(); expect( - screen.queryByText('Expected format: <service-name>. Example: sshd') + screen.queryByText('Expected format: <service-name>. Example: sshd'), ).not.toBeInTheDocument(); await addPort('wrong--service'); await screen.findByText( - 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp' + 'Expected format: <port/port-name>:<protocol>. Example: 8080:tcp, ssh:tcp', ); }); @@ -246,7 +246,7 @@ describe('Firewall edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = firewallCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx b/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx index 4c04f797..c587d32d 100644 --- a/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/FirstBoot/Firstboot.test.tsx @@ -258,7 +258,7 @@ describe('First Boot edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = firstBootCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); @@ -280,7 +280,7 @@ describe('First Boot edit mode', () => { await goToReviewStep(); const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); // both the enabled service and files should be removed // leaving the base blueprint request diff --git a/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx b/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx index 85f2ac5f..8fe42fe5 100644 --- a/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Hostname/Hostname.test.tsx @@ -191,7 +191,7 @@ describe('Hostname edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = hostnameCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx b/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx index ee026638..a9555aa9 100644 --- a/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/ImageOutput/ImageOutput.test.tsx @@ -137,7 +137,7 @@ const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('image-output-expandable'); const revisitButton = await within(expandable).findByTestId( - 'revisit-image-output' + 'revisit-image-output', ); await waitFor(() => user.click(revisitButton)); }; @@ -259,8 +259,8 @@ describe('Step Image output', () => { expect( screen.queryByRole('region', { name: /hide information about release lifecycle/i, - }) - ).not.toBeInTheDocument() + }), + ).not.toBeInTheDocument(), ); }); @@ -268,7 +268,7 @@ describe('Step Image output', () => { await renderCreateMode(); await selectCentos9(); await screen.findByText( - 'CentOS Stream builds are intended for the development of future versions of RHEL and are not supported for production workloads or other use cases.' + 'CentOS Stream builds are intended for the development of future versions of RHEL and are not supported for production workloads or other use cases.', ); }); @@ -318,7 +318,7 @@ describe('Step Image output', () => { server.use( http.get(`${IMAGE_BUILDER_API}/architectures/${RHEL_10}`, () => { return new HttpResponse(null, { status: 404 }); - }) + }), ); await renderCreateMode(); @@ -404,11 +404,11 @@ describe('Check that the target filtering is in accordance to mock content', () name: /Bare metal installer/i, }); await screen.findByText( - /VMware vSphere - Open virtualization format \(\.ova\)/ + /VMware vSphere - Open virtualization format \(\.ova\)/, ); await screen.findByText(/VMware vSphere - Virtual disk \(\.vmdk\)/); expect( - screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i) + screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i), ).not.toBeInTheDocument(); }); @@ -449,7 +449,7 @@ describe('Check that the target filtering is in accordance to mock content', () name: /Bare metal installer/i, }); await screen.findByText( - /VMware vSphere - Open virtualization format \(\.ova\)/ + /VMware vSphere - Open virtualization format \(\.ova\)/, ); await screen.findByText(/VMware vSphere - Virtual disk \(\.vmdk\)/); await screen.findByText(/wsl - windows subsystem for linux \(\.wsl\)/i); @@ -481,14 +481,14 @@ describe('Check that the target filtering is in accordance to mock content', () await screen.findByRole('button', { name: /Amazon Web Services/i }); await waitFor(() => expect( - screen.queryByRole('button', { name: /Google Cloud Platform/i }) - ).not.toBeInTheDocument() + screen.queryByRole('button', { name: /Google Cloud Platform/i }), + ).not.toBeInTheDocument(), ); expect( - screen.queryByRole('button', { name: /Microsoft Azure/i }) + screen.queryByRole('button', { name: /Microsoft Azure/i }), ).not.toBeInTheDocument(); expect( - screen.queryByRole('button', { name: /Oracle Cloud Infrastructure/i }) + screen.queryByRole('button', { name: /Oracle Cloud Infrastructure/i }), ).not.toBeInTheDocument(); await screen.findByRole('checkbox', { name: /Virtualization guest image/i, @@ -498,14 +498,14 @@ describe('Check that the target filtering is in accordance to mock content', () }); expect( screen.queryByText( - /VMware vSphere - Open virtualization format \(\.ova\)/ - ) + /VMware vSphere - Open virtualization format \(\.ova\)/, + ), ).not.toBeInTheDocument(); expect( - screen.queryByText(/VMware vSphere - Virtual disk \(\.vmdk\)/) + screen.queryByText(/VMware vSphere - Virtual disk \(\.vmdk\)/), ).not.toBeInTheDocument(); expect( - screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i) + screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i), ).not.toBeInTheDocument(); }); @@ -536,14 +536,14 @@ describe('Check that the target filtering is in accordance to mock content', () await screen.findByRole('button', { name: /Amazon Web Services/i }); await waitFor(() => expect( - screen.queryByRole('button', { name: /Google Cloud Platform/i }) - ).not.toBeInTheDocument() + screen.queryByRole('button', { name: /Google Cloud Platform/i }), + ).not.toBeInTheDocument(), ); expect( - screen.queryByRole('button', { name: /Microsoft Azure/i }) + screen.queryByRole('button', { name: /Microsoft Azure/i }), ).not.toBeInTheDocument(); expect( - screen.queryByRole('button', { name: /Oracle Cloud Infrastructure/i }) + screen.queryByRole('button', { name: /Oracle Cloud Infrastructure/i }), ).not.toBeInTheDocument(); await screen.findByRole('checkbox', { name: /Virtualization guest image/i, @@ -553,14 +553,14 @@ describe('Check that the target filtering is in accordance to mock content', () }); expect( screen.queryByText( - /VMware vSphere - Open virtualization format \(\.ova\)/ - ) + /VMware vSphere - Open virtualization format \(\.ova\)/, + ), ).not.toBeInTheDocument(); expect( - screen.queryByText(/VMware vSphere - Virtual disk \(\.vmdk\)/) + screen.queryByText(/VMware vSphere - Virtual disk \(\.vmdk\)/), ).not.toBeInTheDocument(); expect( - screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i) + screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i), ).not.toBeInTheDocument(); }); @@ -590,13 +590,13 @@ describe('Check that the target filtering is in accordance to mock content', () // make sure the UX conforms to the mocks await screen.findByRole('button', { name: /Amazon Web Services/i }); expect( - screen.queryByRole('button', { name: /Google Cloud Platform/i }) + screen.queryByRole('button', { name: /Google Cloud Platform/i }), ).not.toBeInTheDocument(); expect( - screen.queryByRole('button', { name: /Microsoft Azure/i }) + screen.queryByRole('button', { name: /Microsoft Azure/i }), ).not.toBeInTheDocument(); expect( - screen.queryByRole('button', { name: /Oracle Cloud Infrastructure/i }) + screen.queryByRole('button', { name: /Oracle Cloud Infrastructure/i }), ).not.toBeInTheDocument(); await screen.findByRole('checkbox', { name: /Virtualization guest image/i, @@ -606,14 +606,14 @@ describe('Check that the target filtering is in accordance to mock content', () }); expect( screen.queryByText( - /VMware vSphere - Open virtualization format \(\.ova\)/ - ) + /VMware vSphere - Open virtualization format \(\.ova\)/, + ), ).not.toBeInTheDocument(); expect( - screen.queryByText(/VMware vSphere - Virtual disk \(\.vmdk\)/) + screen.queryByText(/VMware vSphere - Virtual disk \(\.vmdk\)/), ).not.toBeInTheDocument(); expect( - screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i) + screen.queryByText(/wsl - windows subsystem for linux \(\.wsl\)/i), ).not.toBeInTheDocument(); }); }); @@ -729,13 +729,13 @@ describe('Set target using query parameter', () => { expect( await screen.findByRole('checkbox', { name: /Bare metal installer/i, - }) + }), ).toBeChecked(); await handleRegistration(); await goToDetailsStep(); await enterNameAndGoToReviewStep(); const targetExpandable = await screen.findByTestId( - 'target-environments-expandable' + 'target-environments-expandable', ); user.click(targetExpandable); await screen.findByText('Bare metal - Installer (.iso)'); @@ -746,13 +746,13 @@ describe('Set target using query parameter', () => { expect( await screen.findByRole('checkbox', { name: /Virtualization guest image/i, - }) + }), ).toBeChecked(); await handleRegistration(); await goToDetailsStep(); await enterNameAndGoToReviewStep(); const targetExpandable = await screen.findByTestId( - 'target-environments-expandable' + 'target-environments-expandable', ); user.click(targetExpandable); await screen.findByText('Virtualization - Guest image (.qcow2)'); @@ -874,7 +874,7 @@ describe('Image output edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = rhel9CreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); @@ -886,7 +886,7 @@ describe('Image output edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = rhel8CreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); @@ -898,7 +898,7 @@ describe('Image output edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = centos9CreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); @@ -910,7 +910,7 @@ describe('Image output edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = x86_64CreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); @@ -922,7 +922,7 @@ describe('Image output edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = aarch64CreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Kernel/Kernel.test.tsx b/src/test/Components/CreateImageWizard/steps/Kernel/Kernel.test.tsx index fef4990a..9de68c60 100644 --- a/src/test/Components/CreateImageWizard/steps/Kernel/Kernel.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Kernel/Kernel.test.tsx @@ -118,7 +118,7 @@ const clearKernelName = async () => { const addKernelAppend = async (kernelArg: string) => { const user = userEvent.setup(); const kernelAppendInput = await screen.findByPlaceholderText( - 'Add kernel argument' + 'Add kernel argument', ); await waitFor(() => user.click(kernelAppendInput)); await waitFor(() => user.type(kernelAppendInput, kernelArg)); @@ -229,10 +229,10 @@ describe('Step Kernel', () => { await screen.findByText('audit_backlog_limit=8192'); await screen.findByText('audit=1'); expect( - screen.queryByRole('button', { name: /close audit_backlog_limit=8192/i }) + screen.queryByRole('button', { name: /close audit_backlog_limit=8192/i }), ).not.toBeInTheDocument(); expect( - screen.queryByRole('button', { name: /close audit=1/i }) + screen.queryByRole('button', { name: /close audit=1/i }), ).not.toBeInTheDocument(); }); @@ -370,7 +370,7 @@ describe('Kernel edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = kernelCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx b/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx index 41a312c3..f56462d8 100644 --- a/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Locale/Locale.test.tsx @@ -141,10 +141,10 @@ describe('Step Locale', () => { const gbOptions = await screen.findAllByRole('option'); expect(gbOptions[0]).toHaveTextContent('gbm - India (gbm_IN.UTF-8)'); expect(gbOptions[1]).toHaveTextContent( - 'Cornish - United Kingdom (kw_GB.UTF-8)' + 'Cornish - United Kingdom (kw_GB.UTF-8)', ); expect(gbOptions[2]).toHaveTextContent( - 'English - United Kingdom (en_GB.UTF-8)' + 'English - United Kingdom (en_GB.UTF-8)', ); }); @@ -165,14 +165,14 @@ describe('Step Locale', () => { await searchForLanguage('foo'); await screen.findByText(/no results found/i); expect( - await screen.findByRole('option', { name: /no results found/i }) + await screen.findByRole('option', { name: /no results found/i }), ).toBeDisabled(); await clearLanguageSearch(); await searchForKeyboard('foo'); await screen.findByText(/no results found/i); expect( - await screen.findByRole('option', { name: /no results found/i }) + await screen.findByRole('option', { name: /no results found/i }), ).toBeDisabled(); }); @@ -270,7 +270,7 @@ describe('Locale edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = localeCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx b/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx index 73341a1d..88aa1b4c 100644 --- a/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Oscap/Compliance.test.tsx @@ -136,7 +136,7 @@ describe('Compliance edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = complianceCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx b/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx index ad8273c2..adaa4e68 100644 --- a/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Oscap/Oscap.test.tsx @@ -58,7 +58,7 @@ const selectProfile = async () => { await waitFor(() => user.click(selectProfileDropdown)); const cis1Profile = await screen.findByText( - /cis red hat enterprise linux 8 benchmark for level 1 - workstation/i + /cis red hat enterprise linux 8 benchmark for level 1 - workstation/i, ); await waitFor(() => user.click(cis1Profile)); }; @@ -69,7 +69,7 @@ const selectDifferentProfile = async () => { await waitFor(() => user.click(selectProfileDropdown)); const cis2Profile = await screen.findByText( - /cis red hat enterprise linux 8 benchmark for level 2 - workstation/i + /cis red hat enterprise linux 8 benchmark for level 2 - workstation/i, ); await waitFor(() => user.click(cis2Profile)); }; @@ -128,7 +128,7 @@ describe('Step OpenSCAP', () => { expect( screen.queryByRole('cell', { name: /tmp/i, - }) + }), ).not.toBeInTheDocument(); await clickNext(); // skip Snapshots @@ -140,7 +140,7 @@ describe('Step OpenSCAP', () => { name: /Additional packages/i, }); await screen.findByText( - /Search above to add additionalpackages to your image/ + /Search above to add additionalpackages to your image/, ); }); @@ -159,7 +159,7 @@ describe('Step OpenSCAP', () => { await screen.findByText(/crond/i); await screen.findByText(/Disabled services/); await screen.findByText( - /rpcbind autofs nftables nfs-server emacs-service/i + /rpcbind autofs nftables nfs-server emacs-service/i, ); // check that the FSC contains a /tmp partition @@ -187,10 +187,10 @@ describe('Step OpenSCAP', () => { await selectWslTarget(); await goToOscapStep(); await screen.findByText( - /OpenSCAP profiles are not compatible with WSL images/i + /OpenSCAP profiles are not compatible with WSL images/i, ); expect(await screen.findByTestId('profileSelect')).toHaveClass( - 'pf-m-disabled' + 'pf-m-disabled', ); }); @@ -201,7 +201,7 @@ describe('Step OpenSCAP', () => { await selectWslTarget(); await goToOscapStep(); await screen.findByText( - /OpenSCAP profiles are not compatible with WSL images/i + /OpenSCAP profiles are not compatible with WSL images/i, ); await waitFor(() => { expect(screen.getByPlaceholderText(/none/i)).toBeEnabled(); @@ -319,7 +319,7 @@ describe('OpenSCAP edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = oscapCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Packages/Packages.test.tsx b/src/test/Components/CreateImageWizard/steps/Packages/Packages.test.tsx index 906769c7..9d4df218 100644 --- a/src/test/Components/CreateImageWizard/steps/Packages/Packages.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Packages/Packages.test.tsx @@ -180,13 +180,13 @@ const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('content-expandable'); const revisitButton = await within(expandable).findByTestId( - 'revisit-custom-repositories' + 'revisit-custom-repositories', ); await waitFor(() => user.click(revisitButton)); await waitFor(() => expect( - screen.queryByRole('button', { name: /Create blueprint/ }) - ).not.toBeInTheDocument() + screen.queryByRole('button', { name: /Create blueprint/ }), + ).not.toBeInTheDocument(), ); }; @@ -246,7 +246,7 @@ describe('Step Packages', () => { await renderCreateMode(); await goToPackagesStep(); await screen.findByText( - 'Search above to add additionalpackages to your image.' + 'Search above to add additionalpackages to your image.', ); }); @@ -731,7 +731,7 @@ describe('Packages edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = packagesCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx b/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx index cb55d4e7..2ea71b77 100644 --- a/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Registration/Registration.test.tsx @@ -82,7 +82,7 @@ const deselectPredictiveAnalytics = async () => { const openActivationKeyDropdown = async () => { const user = userEvent.setup(); const activationKeyDropdown = await screen.findByPlaceholderText( - 'Select activation key' + 'Select activation key', ); user.click(activationKeyDropdown); }; @@ -143,7 +143,7 @@ const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('registration-expandable'); const revisitButton = await within(expandable).findByTestId( - 'revisit-registration' + 'revisit-registration', ); await waitFor(() => user.click(revisitButton)); }; @@ -191,13 +191,13 @@ describe('Step Registration', () => { server.use( http.get(`${RHSM_API}/activation_keys`, () => { return new HttpResponse(null, { status: 404 }); - }) + }), ); await renderCreateMode(); await goToRegistrationStep(); expect( - await screen.findByRole('button', { name: /Review and finish/ }) + await screen.findByRole('button', { name: /Review and finish/ }), ).toBeDisabled(); }); @@ -210,11 +210,11 @@ describe('Step Registration', () => { const review = await screen.findByTestId('review-registration'); expect(review).toHaveTextContent( - 'Register with Red Hat Subscription Manager (RHSM)' + 'Register with Red Hat Subscription Manager (RHSM)', ); expect(review).toHaveTextContent('Connect to Red Hat Insights'); expect(review).toHaveTextContent( - 'Use remote host configuration (rhc) utility' + 'Use remote host configuration (rhc) utility', ); }); @@ -225,13 +225,13 @@ describe('Step Registration', () => { await waitFor(() => expect( - screen.queryByTestId('selected-activation-key') - ).not.toBeInTheDocument() + screen.queryByTestId('selected-activation-key'), + ).not.toBeInTheDocument(), ); await waitFor(async () => expect(await screen.findByTestId('activation-key-select')).toHaveClass( - 'pf-m-disabled' - ) + 'pf-m-disabled', + ), ); await goToReviewStep(); await screen.findByText('Register the system later'); @@ -433,18 +433,18 @@ describe('Registration request generated correctly', () => { await uploadFile(CERTIFICATE); await waitFor(() => expect(nextButton).toBeDisabled()); await addSatelliteRegistrationCommandViaKeyDown( - SATELLITE_COMMAND_EXPIRED_TOKEN + SATELLITE_COMMAND_EXPIRED_TOKEN, ); const expiredTokenHelper = await screen.findByText( - /The token is already expired or will expire by next day./i + /The token is already expired or will expire by next day./i, ); await waitFor(() => expect(expiredTokenHelper).toBeInTheDocument()); await addSatelliteRegistrationCommandViaKeyDown(SATELLITE_COMMAND); await waitFor(() => expect(nextButton).toBeEnabled()); await addSatelliteRegistrationCommandViaKeyDown( - SATELLITE_COMMAND_NO_EXPIRATION + SATELLITE_COMMAND_NO_EXPIRATION, ); await waitFor(() => expect(nextButton).toBeEnabled()); }); @@ -461,7 +461,7 @@ describe('Registration edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = registrationCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Repositories/Repositories.test.tsx b/src/test/Components/CreateImageWizard/steps/Repositories/Repositories.test.tsx index e39551dc..120581dd 100644 --- a/src/test/Components/CreateImageWizard/steps/Repositories/Repositories.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Repositories/Repositories.test.tsx @@ -60,7 +60,7 @@ const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('content-expandable'); const revisitButton = await within(expandable).findByTestId( - 'revisit-custom-repositories' + 'revisit-custom-repositories', ); await waitFor(() => user.click(revisitButton)); }; @@ -271,7 +271,7 @@ describe('Repositories request generated correctly', () => { const search = await screen.findByLabelText('Filter repositories'); await waitFor(() => user.type(search, 'nginx stable repo')); await waitFor( - () => expect(screen.getByText('nginx stable repo')).toBeInTheDocument + () => expect(screen.getByText('nginx stable repo')).toBeInTheDocument, ); await selectFirstRepository(); }; @@ -338,7 +338,7 @@ describe('Repositories request generated correctly', () => { await clickBulkSelect(); await goToReviewStep(); const receivedRequest = (await interceptBlueprintRequest( - CREATE_BLUEPRINT + CREATE_BLUEPRINT, )) as CreateBlueprintRequest; expect(receivedRequest.customizations.custom_repositories).toHaveLength(6); expect(receivedRequest.customizations.payload_repositories).toHaveLength(6); @@ -358,7 +358,7 @@ describe('Repositories edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = repositoriesCreateBlueprintRequest; await waitFor(() => expect(receivedRequest).toEqual(expectedRequest)); @@ -375,7 +375,7 @@ describe('Repositories edit mode', () => { user.click(customRepositories); await screen.findByText( - /Removing previously added repositories may lead to issues with selected packages/i + /Removing previously added repositories may lead to issues with selected packages/i, ); await toggleSelected(); @@ -391,7 +391,7 @@ describe('Repositories edit mode', () => { user.click(removeAnywayBtn); await waitFor(() => - expect(screen.queryByText(/Are you sure?/)).not.toBeInTheDocument() + expect(screen.queryByText(/Are you sure?/)).not.toBeInTheDocument(), ); await waitFor(() => expect(repoCheckbox).not.toBeChecked()); diff --git a/src/test/Components/CreateImageWizard/steps/Review/Review.test.tsx b/src/test/Components/CreateImageWizard/steps/Review/Review.test.tsx index cbcedf14..08ff0583 100644 --- a/src/test/Components/CreateImageWizard/steps/Review/Review.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Review/Review.test.tsx @@ -105,11 +105,11 @@ describe('Step Review', () => { await screen.findByRole('heading', { name: /Review/ }); const registrationExpandable = await screen.findByTestId( - 'registration-expandable' + 'registration-expandable', ); await within(registrationExpandable).findByText('Registration type'); await within(registrationExpandable).findByText( - 'Register the system later' + 'Register the system later', ); }); @@ -119,11 +119,11 @@ describe('Step Review', () => { await screen.findByRole('heading', { name: /Review/ }); expect( - screen.queryByTestId('registration-expandable') + screen.queryByTestId('registration-expandable'), ).not.toBeInTheDocument(); expect(screen.queryByText('Registration type')).not.toBeInTheDocument(); expect( - screen.queryByText('Register the system later') + screen.queryByText('Register the system later'), ).not.toBeInTheDocument(); }); }); diff --git a/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx b/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx index 004db028..4ecbf8bd 100644 --- a/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Services/Services.test.tsx @@ -83,7 +83,7 @@ const goToReviewStep = async () => { const addDisabledService = async (service: string) => { const user = userEvent.setup(); const disabledServiceInput = await screen.findByPlaceholderText( - 'Add disabled service' + 'Add disabled service', ); await waitFor(() => user.type(disabledServiceInput, service.concat(' '))); }; @@ -98,7 +98,7 @@ const addMaskedService = async (service: string) => { const addEnabledService = async (service: string) => { const user = userEvent.setup(); const enabledServiceInput = await screen.findByPlaceholderText( - 'Add enabled service' + 'Add enabled service', ); await waitFor(() => user.type(enabledServiceInput, service.concat(' '))); }; @@ -117,7 +117,7 @@ const selectProfile = async () => { await waitFor(() => user.click(selectProfileDropdown)); const cis1Profile = await screen.findByText( - /CIS Red Hat Enterprise Linux 8 Benchmark for Level 1 - Workstation/i + /CIS Red Hat Enterprise Linux 8 Benchmark for Level 1 - Workstation/i, ); await waitFor(() => user.click(cis1Profile)); }; @@ -179,7 +179,7 @@ describe('Step Services', () => { expect(screen.queryByText('Invalid format.')).not.toBeInTheDocument(); await addEnabledService('-------'); expect( - await screen.findByText('Expected format: <service-name>. Example: sshd') + await screen.findByText('Expected format: <service-name>. Example: sshd'), ).toBeInTheDocument(); await waitFor(() => user.click(clearInputButtons[0])); @@ -187,7 +187,7 @@ describe('Step Services', () => { expect(screen.queryByText('Invalid format.')).not.toBeInTheDocument(); await addDisabledService('-------'); expect( - await screen.findByText('Expected format: <service-name>. Example: sshd') + await screen.findByText('Expected format: <service-name>. Example: sshd'), ).toBeInTheDocument(); await waitFor(() => user.click(clearInputButtons[1])); @@ -195,7 +195,7 @@ describe('Step Services', () => { expect(screen.queryByText('Invalid format.')).not.toBeInTheDocument(); await addMaskedService('-------'); expect( - await screen.findByText('Expected format: <service-name>. Example: sshd') + await screen.findByText('Expected format: <service-name>. Example: sshd'), ).toBeInTheDocument(); await waitFor(() => user.click(clearInputButtons[2])); @@ -203,7 +203,7 @@ describe('Step Services', () => { expect(screen.queryByText('Invalid format.')).not.toBeInTheDocument(); await addEnabledService('-------'); expect( - await screen.findByText('Expected format: <service-name>. Example: sshd') + await screen.findByText('Expected format: <service-name>. Example: sshd'), ).toBeInTheDocument(); await waitFor(() => user.click(clearInputButtons[0])); }); @@ -219,19 +219,19 @@ describe('Step Services', () => { await screen.findByText('nfs-server'); await screen.findByText('emacs-service'); expect( - screen.queryByRole('button', { name: /close nfs-server/i }) + screen.queryByRole('button', { name: /close nfs-server/i }), ).not.toBeInTheDocument(); expect( - screen.queryByRole('button', { name: /close emacs-service/i }) + screen.queryByRole('button', { name: /close emacs-service/i }), ).not.toBeInTheDocument(); // enabled services await screen.findByText('crond'); await screen.findByText('neovim-service'); expect( - screen.queryByRole('button', { name: /close crond/i }) + screen.queryByRole('button', { name: /close crond/i }), ).not.toBeInTheDocument(); expect( - screen.queryByRole('button', { name: /close neovim-service/i }) + screen.queryByRole('button', { name: /close neovim-service/i }), ).not.toBeInTheDocument(); }); @@ -352,7 +352,7 @@ describe('Services edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = servicesCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Snapshot/Snapshot.test.tsx b/src/test/Components/CreateImageWizard/steps/Snapshot/Snapshot.test.tsx index 81e717d3..d1f5169b 100644 --- a/src/test/Components/CreateImageWizard/steps/Snapshot/Snapshot.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Snapshot/Snapshot.test.tsx @@ -56,7 +56,7 @@ const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId('content-expandable'); const revisitButton = await within(expandable).findByTestId( - 'revisit-custom-repositories' + 'revisit-custom-repositories', ); await waitFor(() => user.click(revisitButton)); }; @@ -161,7 +161,7 @@ describe('repository snapshot tab - ', () => { await selectUseSnapshot(); await updateDatePickerWithValue('2024-00-00'); expect( - await screen.findByRole('button', { name: /Review and finish/ }) + await screen.findByRole('button', { name: /Review and finish/ }), ).toBeDisabled(); }); @@ -340,7 +340,7 @@ describe('Snapshot edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = snapshotCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AwsTarget.test.tsx b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AwsTarget.test.tsx index 806e51a6..fddd9cbb 100644 --- a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AwsTarget.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AwsTarget.test.tsx @@ -58,10 +58,10 @@ const goToReview = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId( - 'target-environments-expandable' + 'target-environments-expandable', ); const revisitButton = await within(expandable).findByTestId( - 'revisit-target-environments' + 'revisit-target-environments', ); await waitFor(() => user.click(revisitButton)); }; @@ -90,7 +90,7 @@ const deselectAwsAndSelectGuestImage = async () => { const chooseManualOption = async () => { const user = userEvent.setup(); const manualOption = await screen.findByText( - /manually enter an account id\./i + /manually enter an account id\./i, ); await waitFor(async () => user.click(manualOption)); }; @@ -170,13 +170,13 @@ describe('Step Upload to AWS', () => { server.use( http.get(`${PROVISIONING_API}/sources`, () => { return new HttpResponse(null, { status: 500 }); - }) + }), ); await renderCreateMode(); await selectAwsTarget(); await goToAwsStep(); await screen.findByText( - /sources cannot be reached, try again later or enter an aws account id manually\./i + /sources cannot be reached, try again later or enter an aws account id manually\./i, ); }); @@ -318,7 +318,7 @@ describe('AWS edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = awsCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx index bc57ea5c..f371900d 100644 --- a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/AzureTarget.test.tsx @@ -61,10 +61,10 @@ const goToReview = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId( - 'target-environments-expandable' + 'target-environments-expandable', ); const revisitButton = await within(expandable).findByTestId( - 'revisit-target-environments' + 'revisit-target-environments', ); await waitFor(() => user.click(revisitButton)); }; @@ -104,7 +104,7 @@ const selectSource = async (sourceName: string) => { const selectResourceGroup = async () => { const user = userEvent.setup(); const resourceGrpTextbox = await screen.findByPlaceholderText( - /select resource group/i + /select resource group/i, ); await waitFor(async () => user.click(resourceGrpTextbox)); @@ -117,7 +117,7 @@ const selectResourceGroup = async () => { const selectManuallyEnterInformation = async () => { const user = userEvent.setup(); const manualOption = await screen.findByText( - /manually enter the account information\./i + /manually enter the account information\./i, ); await waitFor(async () => user.click(manualOption)); }; @@ -141,7 +141,7 @@ const enterTenantGuid = async () => { const user = userEvent.setup(); const tenantGuid = await getTenantGuidInput(); await waitFor(() => - user.type(tenantGuid, 'b8f86d22-4371-46ce-95e7-65c415f3b1e2') + user.type(tenantGuid, 'b8f86d22-4371-46ce-95e7-65c415f3b1e2'), ); }; @@ -156,7 +156,7 @@ const enterSubscriptionId = async () => { const user = userEvent.setup(); const subscriptionId = await getSubscriptionIdInput(); await waitFor(() => - user.type(subscriptionId, '60631143-a7dc-4d15-988b-ba83f3c99711') + user.type(subscriptionId, '60631143-a7dc-4d15-988b-ba83f3c99711'), ); }; @@ -180,7 +180,7 @@ const getResourceGroupTextInput = async () => { const getResourceGroupSelect = async () => { const resourceGroupInput = await screen.findByPlaceholderText( - /select resource group/i + /select resource group/i, ); return resourceGroupInput; }; @@ -282,14 +282,14 @@ describe('Step Upload to Azure', () => { await selectSource('azureSource1'); await waitFor(async () => { expect(await getTenantGuidInput()).toHaveValue( - '2fd7c95c-0d63-4e81-b914-3fbd5288daf7' + '2fd7c95c-0d63-4e81-b914-3fbd5288daf7', ); }); await selectSource('azureSource2'); await waitFor(async () => { expect(await getTenantGuidInput()).toHaveValue( - '73d5694c-7a28-417e-9fca-55840084f508' + '73d5694c-7a28-417e-9fca-55840084f508', ); }); @@ -297,7 +297,7 @@ describe('Step Upload to Azure', () => { const groups = await screen.findByLabelText(/Resource group/); expect(groups).toBeInTheDocument(); expect( - await screen.findByLabelText('Resource group theirGroup2') + await screen.findByLabelText('Resource group theirGroup2'), ).toBeVisible(); }); @@ -305,13 +305,13 @@ describe('Step Upload to Azure', () => { server.use( http.get(`${PROVISIONING_API}/sources`, () => { return new HttpResponse(null, { status: 500 }); - }) + }), ); await renderCreateMode(); await selectAzureTarget(); await goToAzureStep(); await screen.findByText( - /Sources cannot be reached, try again later or enter an account info for upload manually\./i + /Sources cannot be reached, try again later or enter an account info for upload manually\./i, ); }); @@ -460,7 +460,7 @@ describe('Azure edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = azureCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/GCPTarget.test.tsx b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/GCPTarget.test.tsx index 5337897f..c5175247 100644 --- a/src/test/Components/CreateImageWizard/steps/TargetEnvironment/GCPTarget.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/TargetEnvironment/GCPTarget.test.tsx @@ -53,17 +53,17 @@ const goToReview = async () => { const clickRevisitButton = async () => { const user = userEvent.setup(); const expandable = await screen.findByTestId( - 'target-environments-expandable' + 'target-environments-expandable', ); const revisitButton = await within(expandable).findByTestId( - 'revisit-target-environments' + 'revisit-target-environments', ); await waitFor(() => user.click(revisitButton)); }; const createGCPCloudImage = ( image_type: ImageTypes, - options: GcpUploadRequestOptions + options: GcpUploadRequestOptions, ): ImageRequest => { return { ...imageRequest, @@ -152,12 +152,12 @@ describe('Step Upload to Google', () => { await clickGCPTarget(); await waitFor(async () => - user.type(await screen.findByTestId('principal'), 'a') + user.type(await screen.findByTestId('principal'), 'a'), ); expect(await getNextButton()).toBeDisabled(); await waitFor(async () => - user.type(await screen.findByTestId('principal'), 'test@test.com') + user.type(await screen.findByTestId('principal'), 'test@test.com'), ); expect(await getNextButton()).toBeEnabled(); }); @@ -233,7 +233,7 @@ describe('GCP image type request generated correctly', () => { await renderCreateMode(); await clickGCPTarget(); await selectGoogleAccount( - 'Google Workspace domain or Cloud Identity domain' + 'Google Workspace domain or Cloud Identity domain', ); await goToReview(); const receivedRequest = await interceptBlueprintRequest(CREATE_BLUEPRINT); @@ -270,7 +270,7 @@ describe('GCP image type request generated correctly', () => { await renderCreateMode(); await clickGCPTarget(); await selectGoogleAccount( - 'Google Workspace domain or Cloud Identity domain' + 'Google Workspace domain or Cloud Identity domain', ); await clickBack(); await deselectGcpAndSelectGuestImage(); @@ -294,7 +294,7 @@ describe('GCP edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = gcpCreateBlueprintRequest; await waitFor(() => expect(receivedRequest).toEqual(expectedRequest)); diff --git a/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx b/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx index 6209ffa9..f80fd08b 100644 --- a/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Timezone/Timezone.test.tsx @@ -134,7 +134,7 @@ describe('Step Timezone', () => { await searchForUnknownTimezone(); await screen.findByText(/no results found/i); expect( - await screen.findByRole('option', { name: /no results found/i }) + await screen.findByRole('option', { name: /no results found/i }), ).toBeDisabled(); }); @@ -142,14 +142,14 @@ describe('Step Timezone', () => { await renderCreateMode(); await goToTimezoneStep(); expect( - screen.queryByText('NTP server already exists.') + screen.queryByText('NTP server already exists.'), ).not.toBeInTheDocument(); await addNtpServerViaKeyDown('0.nl.pool.ntp.org'); await addNtpServerViaKeyDown('0.nl.pool.ntp.org'); await screen.findByText('NTP server already exists.'); await clearInput(); expect( - screen.queryByText('NTP server already exists.') + screen.queryByText('NTP server already exists.'), ).not.toBeInTheDocument(); await addNtpServerViaAddButton('0.nl.pool.ntp.org'); await screen.findByText('NTP server already exists.'); @@ -160,12 +160,12 @@ describe('Step Timezone', () => { await goToTimezoneStep(); expect( screen.queryByText( - 'Expected format: <ntp-server>. Example: time.redhat.com' - ) + 'Expected format: <ntp-server>. Example: time.redhat.com', + ), ).not.toBeInTheDocument(); await addNtpServerViaKeyDown('this is not NTP server'); await screen.findByText( - 'Expected format: <ntp-server>. Example: time.redhat.com' + 'Expected format: <ntp-server>. Example: time.redhat.com', ); }); @@ -262,7 +262,7 @@ describe('Timezone edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = timezoneCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); diff --git a/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx b/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx index 9b84dd2b..95cabcb6 100644 --- a/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx +++ b/src/test/Components/CreateImageWizard/steps/Users/Users.test.tsx @@ -57,7 +57,7 @@ const goToReviewStep = async () => { const addAzureTarget = async () => { const user = userEvent.setup(); await waitFor(() => - user.click(screen.getByRole('button', { name: /Microsoft Azure/i })) + user.click(screen.getByRole('button', { name: /Microsoft Azure/i })), ); await clickNext(); @@ -70,11 +70,11 @@ const addAzureTarget = async () => { await waitFor(() => user.click(azureSource)); const resourceGroupDropdown = await screen.findByPlaceholderText( - /select resource group/i + /select resource group/i, ); await waitFor(() => user.click(resourceGroupDropdown)); await waitFor(async () => - user.click(await screen.findByLabelText('Resource group myResourceGroup1')) + user.click(await screen.findByLabelText('Resource group myResourceGroup1')), ); }; @@ -260,10 +260,10 @@ describe('Step Users', () => { await addPasswordByUserIndex(invalidPassword, 0); const invalidUserMessage = screen.getByText( - /Password must be at least 6 characters long/i + /Password must be at least 6 characters long/i, ); const warningUserMessage = screen.getByText( - /Must include at least 3 of the following: lowercase letters, uppercase letters, numbers, symbols/i + /Must include at least 3 of the following: lowercase letters, uppercase letters, numbers, symbols/i, ); await waitFor(() => expect(invalidUserMessage)); await waitFor(() => expect(warningUserMessage)); @@ -281,7 +281,7 @@ describe('Step Users', () => { await addPasswordByUserIndex(invalidPassword, 0); const invalidUserMessage = screen.getByText( - /Password must be at least 6 characters long/i + /Password must be at least 6 characters long/i, ); await waitFor(() => expect(invalidUserMessage)); @@ -499,7 +499,7 @@ describe('Users edit mode', () => { // starts on review step const receivedRequest = await interceptEditBlueprintRequest( - `${EDIT_BLUEPRINT}/${id}` + `${EDIT_BLUEPRINT}/${id}`, ); const expectedRequest = usersCreateBlueprintRequest; expect(receivedRequest).toEqual(expectedRequest); @@ -524,7 +524,7 @@ describe('Users edit mode', () => { await waitFor(() => user.hover(passwordToggleButton)); const tooltip = await screen.findByText( - 'Passwords cannot be viewed when editing a blueprint for security reasons' + 'Passwords cannot be viewed when editing a blueprint for security reasons', ); expect(tooltip).toBeInTheDocument(); @@ -533,8 +533,8 @@ describe('Users edit mode', () => { await waitFor(() => { expect( screen.queryByText( - 'Passwords cannot be viewed when editing a blueprint for security reasons' - ) + 'Passwords cannot be viewed when editing a blueprint for security reasons', + ), ).not.toBeInTheDocument(); }); }); diff --git a/src/test/Components/CreateImageWizard/wizardTestUtils.tsx b/src/test/Components/CreateImageWizard/wizardTestUtils.tsx index c295544f..18c9cf8b 100644 --- a/src/test/Components/CreateImageWizard/wizardTestUtils.tsx +++ b/src/test/Components/CreateImageWizard/wizardTestUtils.tsx @@ -80,7 +80,7 @@ export const blueprintRequest: CreateBlueprintRequest = { function preparePathname(searchParams: { [key: string]: string } = {}): string { let pathName = process.env.IS_ON_PREMISE ? '/imageWizard' : 'imageWizard'; const params = Object.entries(searchParams).map( - ([param, value]) => `${param}=${value}` + ([param, value]) => `${param}=${value}`, ); if (params.length > 0) { pathName += `?${params.join('&')}`; @@ -185,7 +185,7 @@ export const openAndDismissSaveAndBuildModal = async () => { }); await waitFor(async () => user.click(createBlueprintBtn)); const saveAndBuildModal = await screen.findByTestId( - 'close-button-saveandbuild-modal' + 'close-button-saveandbuild-modal', ); await waitFor(() => user.click(saveAndBuildModal)); }; @@ -207,7 +207,7 @@ export const interceptBlueprintRequest = async (requestPathname: string) => { }; export const interceptEditBlueprintRequest = async ( - requestPathname: string + requestPathname: string, ) => { const user = userEvent.setup(); const receivedRequestPromise = spyOnRequest(requestPathname, 'PUT'); diff --git a/src/test/Components/ImagesTable/ImagesTable.test.tsx b/src/test/Components/ImagesTable/ImagesTable.test.tsx index 23db3cd6..8dff700b 100644 --- a/src/test/Components/ImagesTable/ImagesTable.test.tsx +++ b/src/test/Components/ImagesTable/ImagesTable.test.tsx @@ -21,7 +21,7 @@ describe('Images Table', () => { // make sure the empty state message isn't present const emptyState = screen.queryByText( - /Image builder is a tool for creating deployment-ready customized system images/i + /Image builder is a tool for creating deployment-ready customized system images/i, ); expect(emptyState).not.toBeInTheDocument(); @@ -41,7 +41,7 @@ describe('Images Table', () => { expect(headerCells[7]).toHaveTextContent('Instance'); const imageNameValues = mockComposes.map((compose) => - compose.image_name ? compose.image_name : compose.id + compose.image_name ? compose.image_name : compose.id, ); // 10 rows for 10 images @@ -86,7 +86,7 @@ describe('Images Table', () => { const downloadLink: HTMLAnchorElement = await within(downloadButton).findByRole('link'); expect(downloadLink.download).toBe( - 'request-1579d95b-8f1d-4982-8c53-8c2afa4ab04c.json' + 'request-1579d95b-8f1d-4982-8c53-8c2afa4ab04c.json', ); const hrefParts = downloadLink.href.split(','); @@ -96,8 +96,8 @@ describe('Images Table', () => { await waitFor(() => expect(encodedRequest).toBe( - encodeURIComponent(JSON.stringify(expectedRequest, null, ' ')) - ) + encodeURIComponent(JSON.stringify(expectedRequest, null, ' ')), + ), ); }); @@ -127,39 +127,39 @@ describe('Images Table', () => { // GCP image const errorPopoverR2 = await within(rows[2]).findByText( - /image build failed/i + /image build failed/i, ); // AWS image const errorPopoverR7 = await within(rows[7]).findByText( - /image build failed/i + /image build failed/i, ); expect( - screen.getAllByText(/c1cfa347-4c37-49b5-8e73-6aa1d1746cfa/i)[1] + screen.getAllByText(/c1cfa347-4c37-49b5-8e73-6aa1d1746cfa/i)[1], ).not.toBeVisible(); await user.click(errorPopoverR2); await screen.findByTestId('errorstatus-popover'); await waitFor(() => - expect(screen.getAllByText(/Error in depsolve job/i)[0]).toBeVisible() + expect(screen.getAllByText(/Error in depsolve job/i)[0]).toBeVisible(), ); await user.click(errorPopoverR2); await waitFor(() => expect( - screen.queryByTestId('errorstatus-popover') - ).not.toBeInTheDocument() + screen.queryByTestId('errorstatus-popover'), + ).not.toBeInTheDocument(), ); await user.click(errorPopoverR7); await screen.findByTestId('errorstatus-popover'); await waitFor(() => - expect(screen.getAllByText(/Error in depsolve job/i)[0]).toBeVisible() + expect(screen.getAllByText(/Error in depsolve job/i)[0]).toBeVisible(), ); await user.click(errorPopoverR7); await waitFor(() => expect( - screen.queryByTestId('errorstatus-popover') - ).not.toBeInTheDocument() + screen.queryByTestId('errorstatus-popover'), + ).not.toBeInTheDocument(), ); // Go to next page on the table @@ -173,10 +173,10 @@ describe('Images Table', () => { rows = await within(table).findAllByRole('row'); const errorPopoverP2R5 = await within(rows[5]).findByText( - /image build failed/i + /image build failed/i, ); const errorPopoverP2R6 = await within(rows[6]).findByText( - /image build failed/i + /image build failed/i, ); await user.click(errorPopoverP2R5); @@ -186,19 +186,19 @@ describe('Images Table', () => { await user.click(errorPopoverP2R5); await waitFor(() => expect( - screen.queryByTestId('errorstatus-popover') - ).not.toBeInTheDocument() + screen.queryByTestId('errorstatus-popover'), + ).not.toBeInTheDocument(), ); await user.click(errorPopoverP2R6); await screen.findByTestId('errorstatus-popover'); await waitFor(() => expect( - screen.getAllByText(/Something went very wrong for Azure/i)[0] - ).toBeVisible() + screen.getAllByText(/Something went very wrong for Azure/i)[0], + ).toBeVisible(), ); await waitFor(() => - expect(screen.getAllByText(/There was an error/i)[0]).toBeVisible() + expect(screen.getAllByText(/There was an error/i)[0]).toBeVisible(), ); }); }); @@ -231,7 +231,7 @@ describe('Clones table', () => { // make sure the empty state message isn't present const emptyState = screen.queryByText( - /Image builder is a tool for creating deployment-ready customized system images/i + /Image builder is a tool for creating deployment-ready customized system images/i, ); expect(emptyState).not.toBeInTheDocument(); @@ -268,13 +268,13 @@ describe('Clones table', () => { const clonesTableData = { ami: [ ...mockClones(composeId).data.map( - (clone) => mockCloneStatus[clone.id].options.ami + (clone) => mockCloneStatus[clone.id].options.ami, ), ], created: [...mockClones(composeId).data.map((clone) => clone.created_at)], region: [ ...mockClones(composeId).data.map( - (clone) => mockCloneStatus[clone.id].options.region + (clone) => mockCloneStatus[clone.id].options.region, ), ], }; diff --git a/src/test/Components/LandingPage/LandingPage.test.tsx b/src/test/Components/LandingPage/LandingPage.test.tsx index 570719e3..a1481727 100644 --- a/src/test/Components/LandingPage/LandingPage.test.tsx +++ b/src/test/Components/LandingPage/LandingPage.test.tsx @@ -23,13 +23,13 @@ describe('Landing Page', () => { server.use( http.get(`${IMAGE_BUILDER_API}/composes`, () => { return HttpResponse.json(mockComposesEmpty); - }) + }), ); renderCustomRoutesWithReduxRouter(); // check table loads await screen.findByText( - /Image builder is a tool for creating deployment-ready customized system images/i + /Image builder is a tool for creating deployment-ready customized system images/i, ); }); }); diff --git a/src/test/Components/ShareImageModal/ShareImageModal.test.tsx b/src/test/Components/ShareImageModal/ShareImageModal.test.tsx index 7b95b5d9..d787e531 100644 --- a/src/test/Components/ShareImageModal/ShareImageModal.test.tsx +++ b/src/test/Components/ShareImageModal/ShareImageModal.test.tsx @@ -54,7 +54,7 @@ describe('Create Share To Regions Modal', () => { await waitFor(() => expect(shareButton).toBeDisabled()); const invalidAlert = await screen.findByText( - /select at least one region to share to\./i + /select at least one region to share to\./i, ); expect(invalidAlert).toBeInTheDocument(); }); @@ -63,7 +63,7 @@ describe('Create Share To Regions Modal', () => { const { router } = await renderCustomRoutesWithReduxRouter( `share/${composeId}`, {}, - routes + routes, ); const cancelButton = await screen.findByRole('button', { name: /cancel/i }); @@ -71,7 +71,7 @@ describe('Create Share To Regions Modal', () => { // returns back to the landing page await waitFor(() => - expect(router.state.location.pathname).toBe('/insights/image-builder') + expect(router.state.location.pathname).toBe('/insights/image-builder'), ); }); @@ -79,7 +79,7 @@ describe('Create Share To Regions Modal', () => { const { router } = await renderCustomRoutesWithReduxRouter( `share/${composeId}`, {}, - routes + routes, ); const closeButton = await screen.findByRole('button', { name: /close/i }); @@ -87,7 +87,7 @@ describe('Create Share To Regions Modal', () => { // returns back to the landing page await waitFor(() => - expect(router.state.location.pathname).toBe('/insights/image-builder') + expect(router.state.location.pathname).toBe('/insights/image-builder'), ); }); diff --git a/src/test/fixtures/activationKeys.ts b/src/test/fixtures/activationKeys.ts index c973be3a..e17faaf3 100644 --- a/src/test/fixtures/activationKeys.ts +++ b/src/test/fixtures/activationKeys.ts @@ -19,7 +19,7 @@ export const mockActivationKeysResults = (): ListActivationKeysApiResponse => { }; export const mockActivationKeyInformation = ( - key: string + key: string, ): ShowActivationKeyApiResponse => { const mockKeys: { [key: string]: ShowActivationKeyApiResponse } = { name0: { diff --git a/src/test/fixtures/architectures.ts b/src/test/fixtures/architectures.ts index bbf65700..536c1e3e 100644 --- a/src/test/fixtures/architectures.ts +++ b/src/test/fixtures/architectures.ts @@ -1,7 +1,7 @@ import { Architectures, Distributions } from '../../store/imageBuilderApi'; export const mockArchitecturesByDistro = ( - distro: Distributions + distro: Distributions, ): Architectures => { const mockDistros: { [key: string]: Architectures } = { 'rhel-10': [ diff --git a/src/test/fixtures/oscap.ts b/src/test/fixtures/oscap.ts index 60ff8fad..bcd645eb 100644 --- a/src/test/fixtures/oscap.ts +++ b/src/test/fixtures/oscap.ts @@ -16,7 +16,7 @@ export const distributionOscapProfiles = (): GetOscapProfilesApiResponse => { }; export const oscapCustomizations = ( - profile: string + profile: string, ): GetOscapCustomizationsApiResponse => { if (profile === 'xccdf_org.ssgproject.content_profile_cis_workstation_l1') { return { @@ -117,13 +117,13 @@ export const oscapCustomizations = ( }; export const oscapCustomizationsPolicy = ( - policy: string + policy: string, ): GetOscapCustomizationsApiResponse => { const policyData = mockPolicies.data.find((p) => p.id === policy); const customizations = oscapCustomizations(policyData!.ref_id); // filter out a single package to simulate the customizations being tailored customizations.packages = customizations.packages!.filter( - (p) => p !== 'aide' + (p) => p !== 'aide', ); return customizations; }; diff --git a/src/test/fixtures/packages.ts b/src/test/fixtures/packages.ts index 88afa97a..0f494415 100644 --- a/src/test/fixtures/packages.ts +++ b/src/test/fixtures/packages.ts @@ -7,7 +7,7 @@ import { RecommendPackageApiResponse } from '../../store/imageBuilderApi'; export const mockSourcesPackagesResults = ( search: string, - urls: string[] + urls: string[], ): ApiSearchRpmResponse[] => { const isDistroPkgSearch = urls.filter((u) => u.includes('cdn.redhat.com')).length > 0; @@ -96,7 +96,7 @@ export const mockSourcesPackagesResults = ( export const mockSourcesGroupsResults = ( search: string, - urls: string[] + urls: string[], ): ApiSearchPackageGroupResponse[] => { const isDistroPkgSearch = urls.filter((u) => u.includes('cdn.redhat.com')).length > 0; diff --git a/src/test/fixtures/repositories.ts b/src/test/fixtures/repositories.ts index 6008ec4e..aa3c9655 100644 --- a/src/test/fixtures/repositories.ts +++ b/src/test/fixtures/repositories.ts @@ -37,7 +37,7 @@ const filterRepos = (args: repoArgs): ApiRepositoryResponse[] => { repos = repos.filter( (repo) => repo.distribution_arch === 'any' || - repo.distribution_arch === args.available_for_arch + repo.distribution_arch === args.available_for_arch, ); } @@ -59,7 +59,7 @@ const filterRepos = (args: repoArgs): ApiRepositoryResponse[] => { if (args.search) { repos = repos.filter( (repo) => - repo.name?.includes(args.search!) || repo.url?.includes(args.search!) + repo.name?.includes(args.search!) || repo.url?.includes(args.search!), ); } @@ -591,7 +591,7 @@ const testingRepos: ApiRepositoryResponseRead[] = [ const generateMeta = ( limit: ApiResponseMetadata['limit'], offset: ApiResponseMetadata['offset'], - count: ApiResponseMetadata['count'] + count: ApiResponseMetadata['count'], ): ApiResponseMetadata => { return { limit: limit, @@ -602,7 +602,7 @@ const generateMeta = ( const generateLinks = ( limit: ApiResponseMetadata['limit'], - offset: ApiResponseMetadata['offset'] + offset: ApiResponseMetadata['offset'], ): ApiLinks => { return { first: `/api/content-sources/v1/repositories/?limit=${limit}&offset=${offset}`, diff --git a/src/test/fixtures/sources.ts b/src/test/fixtures/sources.ts index 3e06f1ac..3f31e566 100644 --- a/src/test/fixtures/sources.ts +++ b/src/test/fixtures/sources.ts @@ -4,7 +4,7 @@ import { } from '../../store/provisioningApi'; export const mockSourcesByProvider = ( - provider: string + provider: string, ): GetSourceListApiResponse => { const mockSources: { [key: string]: GetSourceListApiResponse } = { aws: { @@ -38,7 +38,7 @@ export const mockSourcesByProvider = ( }; export const mockUploadInfo = ( - sourceId: string + sourceId: string, ): GetSourceUploadInfoApiResponse => { const mockInfo: { [key: string]: GetSourceUploadInfoApiResponse } = { '666': { diff --git a/src/test/fixtures/templates.ts b/src/test/fixtures/templates.ts index b48fa0a1..1977a874 100644 --- a/src/test/fixtures/templates.ts +++ b/src/test/fixtures/templates.ts @@ -36,7 +36,7 @@ const filterTemplates = (args: templateArgs): ApiTemplateResponse[] => { if (args.version) { templates = templates.filter( - (template) => template.version === args.version + (template) => template.version === args.version, ); } @@ -175,7 +175,7 @@ export const testingTemplates: ApiTemplateResponseRead[] = [ const generateMeta = ( limit: ApiResponseMetadata['limit'], offset: ApiResponseMetadata['offset'], - count: ApiResponseMetadata['count'] + count: ApiResponseMetadata['count'], ): ApiResponseMetadata => { return { limit: limit, @@ -186,7 +186,7 @@ const generateMeta = ( const generateLinks = ( limit: ApiResponseMetadata['limit'], - offset: ApiResponseMetadata['offset'] + offset: ApiResponseMetadata['offset'], ): ApiLinks => { return { first: `/api/content-sources/v1/templates/?limit=${limit}&offset=${offset}`, diff --git a/src/test/mocks/cockpit/fsinfo.ts b/src/test/mocks/cockpit/fsinfo.ts index 75a870b8..60d084e7 100644 --- a/src/test/mocks/cockpit/fsinfo.ts +++ b/src/test/mocks/cockpit/fsinfo.ts @@ -55,7 +55,7 @@ export const listComposes = (): Promise<fileinfo> => { export const fsinfo = ( filepath: string, attributes: (keyof fileinfo)[], - options: object + options: object, ): Promise<fileinfo> => { if (filepath === bpDir) { return listBlueprints(); diff --git a/src/test/mocks/handlers.js b/src/test/mocks/handlers.js index b02807f6..6f5f078d 100644 --- a/src/test/mocks/handlers.js +++ b/src/test/mocks/handlers.js @@ -62,7 +62,7 @@ export const handlers = [ } else { return new HttpResponse(null, { status: 404 }); } - } + }, ), http.post(`${CONTENT_SOURCES_API}/rpms/names`, async ({ request }) => { const { search, urls } = await request.json(); @@ -73,7 +73,7 @@ export const handlers = [ async ({ request }) => { const { search, urls } = await request.json(); return HttpResponse.json(mockSourcesGroupsResults(search, urls)); - } + }, ), http.get(`${CONTENT_SOURCES_API}/features/`, async () => { return HttpResponse.json(mockedFeatureResponse); @@ -162,21 +162,21 @@ export const handlers = [ `${IMAGE_BUILDER_API}/oscap/:distribution/profiles`, ({ request }) => { return HttpResponse.json(distributionOscapProfiles(request)); - } + }, ), http.get( `${IMAGE_BUILDER_API}/oscap/:distribution/:profile/customizations`, ({ params }) => { const { profile } = params; return HttpResponse.json(oscapCustomizations(profile)); - } + }, ), http.get( `${IMAGE_BUILDER_API}/oscap/:policy/:distribution/policy_customizations`, ({ params }) => { const { policy } = params; return HttpResponse.json(oscapCustomizationsPolicy(policy)); - } + }, ), http.get(`${IMAGE_BUILDER_API}/blueprints`, ({ request }) => { const url = new URL(request.url); @@ -205,7 +205,7 @@ export const handlers = [ resp.meta.count = resp.data.length; resp.data = resp.data.slice( parseInt(offset), - parseInt(offset) + parseInt(limit) + parseInt(offset) + parseInt(limit), ); return HttpResponse.json(resp); @@ -250,7 +250,7 @@ export const handlers = [ const id = params['id']; getMockBlueprintResponse(id).lint.errors = []; return HttpResponse(null, { status: 200 }); - } + }, ), http.post(`${IMAGE_BUILDER_API}/experimental/recommendations`, () => { return HttpResponse.json(mockPkgRecommendations); diff --git a/src/test/testUtils.js b/src/test/testUtils.js index fc6f3e02..1076d3cc 100644 --- a/src/test/testUtils.js +++ b/src/test/testUtils.js @@ -41,7 +41,7 @@ const cockpitRoutes = [ export const renderCustomRoutesWithReduxRouter = async ( route = '/', preloadedState = {}, - routes = process.env.IS_ON_PREMISE ? cockpitRoutes : defaultRoutes + routes = process.env.IS_ON_PREMISE ? cockpitRoutes : defaultRoutes, ) => { const mw = process.env.IS_ON_PREMISE ? onPremMiddleware : middleware; const red = process.env.IS_ON_PREMISE ? onPremReducer : reducer; @@ -58,7 +58,7 @@ export const renderCustomRoutesWithReduxRouter = async ( render( <Provider store={store}> <RouterProvider router={router} /> - </Provider> + </Provider>, ); return { router, store }; From bb345c0e4f3bf319053d362774b6982eccb92666 Mon Sep 17 00:00:00 2001 From: regexowl <ksimicko@redhat.com> Date: Tue, 5 Aug 2025 13:52:45 +0200 Subject: [PATCH 068/123] ESLint: All the single quotes --- eslint.config.js | 2 +- src/AppCockpit.tsx | 2 +- .../Blueprints/BlueprintActionsMenu.tsx | 6 +- src/Components/Blueprints/BlueprintCard.tsx | 2 +- .../Blueprints/BlueprintDiffModal.tsx | 12 +- .../Blueprints/BlueprintVersionFilter.tsx | 4 +- .../Blueprints/BlueprintsPagination.tsx | 4 +- .../Blueprints/BlueprintsSideBar.tsx | 18 +- .../Blueprints/BuildImagesButton.tsx | 12 +- .../Blueprints/DeleteBlueprintModal.tsx | 6 +- .../Blueprints/EditBlueprintButton.tsx | 2 +- .../Blueprints/ImportBlueprintModal.tsx | 30 +-- .../CloudProviderConfig/AWSConfig.tsx | 34 +-- .../CloudProviderConfig.tsx | 10 +- src/Components/Cockpit/NotReady.tsx | 6 +- src/Components/Cockpit/RequireAdmin.tsx | 4 +- .../CreateImageWizard/CreateImageWizard.tsx | 128 +++++------ .../CreateImageWizard/LabelInput.tsx | 12 +- .../UsrSubDirectoriesDisabled.tsx | 4 +- .../CreateImageWizard/ValidatedInput.tsx | 8 +- .../CreateImageWizard/steps/Details/index.tsx | 24 +- ...ileSystemAutomaticPartitionInformation.tsx | 10 +- .../components/FileSystemConfiguration.tsx | 16 +- .../components/FileSystemPartition.tsx | 16 +- .../FileSystem/components/FileSystemTable.tsx | 38 ++-- .../steps/FileSystem/index.tsx | 2 +- .../steps/Firewall/components/PortsInput.tsx | 10 +- .../steps/Firewall/components/Services.tsx | 20 +- .../steps/Firewall/index.tsx | 2 +- .../steps/FirstBoot/index.tsx | 14 +- .../Hostname/components/HostnameInput.tsx | 8 +- .../steps/Hostname/index.tsx | 2 +- .../ImageOutput/components/ArchSelect.tsx | 4 +- .../components/CentOSAcknowledgement.tsx | 10 +- .../components/ReleaseLifecycle.tsx | 12 +- .../ImageOutput/components/ReleaseSelect.tsx | 6 +- .../components/TargetEnvironment.tsx | 108 ++++----- .../steps/ImageOutput/index.tsx | 2 +- .../Kernel/components/KernelArguments.tsx | 12 +- .../steps/Kernel/components/KernelName.tsx | 16 +- .../CreateImageWizard/steps/Kernel/index.tsx | 6 +- .../Locale/components/KeyboardDropDown.tsx | 12 +- .../Locale/components/LanguagesDropDown.tsx | 14 +- .../CreateImageWizard/steps/Locale/index.tsx | 2 +- .../CreateImageWizard/steps/Oscap/Oscap.tsx | 6 +- .../steps/Oscap/components/OnPremSpinner.tsx | 4 +- .../steps/Oscap/components/OnPremWarning.tsx | 12 +- .../components/OscapProfileInformation.tsx | 28 +-- .../steps/Oscap/components/PolicySelector.tsx | 6 +- .../Oscap/components/ProfileSelector.tsx | 24 +- .../CreateImageWizard/steps/Oscap/index.tsx | 16 +- .../steps/Packages/PackageRecommendations.tsx | 20 +- .../steps/Packages/Packages.tsx | 124 +++++----- .../PackageInfoNotAvailablePopover.tsx | 8 +- .../Packages/components/RepoPopovers.tsx | 16 +- .../steps/Packages/index.tsx | 6 +- .../components/ActivationKeyInformation.tsx | 28 +-- .../components/ActivationKeysList.tsx | 20 +- .../components/ManageKeysButton.tsx | 8 +- .../Registration/components/Registration.tsx | 74 +++--- .../components/SatelliteRegistration.tsx | 8 +- .../SatelliteRegistrationCommand.tsx | 10 +- .../steps/Registration/index.tsx | 12 +- .../steps/Repositories/Repositories.tsx | 64 +++--- .../steps/Repositories/RepositoriesStatus.tsx | 32 +-- .../Repositories/RepositoryUnavailable.tsx | 12 +- .../Repositories/components/BulkSelect.tsx | 14 +- .../steps/Repositories/components/Empty.tsx | 12 +- .../steps/Repositories/components/Error.tsx | 2 +- .../steps/Repositories/components/Loading.tsx | 4 +- .../components/ManageRepositoriesButton.tsx | 8 +- .../components/UploadRepositoryLabel.tsx | 2 +- .../steps/Repositories/index.tsx | 4 +- .../steps/Review/Footer/CreateDropdown.tsx | 14 +- .../steps/Review/Footer/EditDropdown.tsx | 4 +- .../steps/Review/Footer/Footer.tsx | 10 +- .../steps/Review/ReviewStep.tsx | 42 ++-- .../steps/Review/ReviewStepTables.tsx | 40 ++-- .../steps/Review/ReviewStepTextLists.tsx | 214 +++++++++--------- .../CreateImageWizard/steps/Review/index.tsx | 2 +- .../Services/components/ServicesInputs.tsx | 36 +-- .../steps/Services/index.tsx | 2 +- .../steps/Snapshot/components/Snapshot.tsx | 42 ++-- .../steps/Snapshot/components/Templates.tsx | 6 +- .../Snapshot/components/TemplatesEmpty.tsx | 10 +- .../steps/Snapshot/index.tsx | 2 +- .../TargetEnvironment/Aws/AwsAccountId.tsx | 10 +- .../Aws/AwsSourcesSelect.tsx | 18 +- .../steps/TargetEnvironment/Aws/index.tsx | 50 ++-- .../Azure/AzureAuthButton.tsx | 6 +- .../Azure/AzureHyperVSelect.tsx | 18 +- .../Azure/AzureResourceGroups.tsx | 14 +- .../Azure/AzureSourcesSelect.tsx | 14 +- .../steps/TargetEnvironment/Azure/index.tsx | 70 +++--- .../steps/TargetEnvironment/Gcp/index.tsx | 48 ++-- .../Timezone/components/NtpServersInput.tsx | 10 +- .../Timezone/components/TimezoneDropDown.tsx | 12 +- .../steps/Timezone/index.tsx | 2 +- .../steps/Users/components/EmptyUserState.tsx | 4 +- .../Users/components/RemoveUserModal.tsx | 6 +- .../steps/Users/components/UserInfo.tsx | 54 ++--- .../CreateImageWizard/steps/Users/index.tsx | 2 +- .../utilities/PasswordValidatedInput.tsx | 12 +- src/Components/ImagesTable/ClonesTable.tsx | 24 +- src/Components/ImagesTable/EmptyState.tsx | 26 +-- src/Components/ImagesTable/ImageDetails.tsx | 120 +++++----- src/Components/ImagesTable/ImagesTable.tsx | 38 ++-- .../ImagesTable/ImagesTableToolbar.tsx | 18 +- src/Components/ImagesTable/Instance.tsx | 64 +++--- src/Components/ImagesTable/Status.tsx | 62 ++--- src/Components/LandingPage/LandingPage.tsx | 8 +- src/Components/LandingPage/NewAlert.tsx | 18 +- src/Components/LandingPage/Quickstarts.tsx | 46 ++-- .../ShareImageModal/RegionsSelect.tsx | 26 +-- .../ShareImageModal/ShareImageModal.tsx | 10 +- .../sharedComponents/DocumentationButton.tsx | 8 +- .../sharedComponents/ImageBuilderHeader.tsx | 32 +-- src/Router.tsx | 8 +- 118 files changed, 1269 insertions(+), 1269 deletions(-) diff --git a/eslint.config.js b/eslint.config.js index 4c61721d..6299dbc5 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -124,7 +124,7 @@ module.exports = defineConfig([ semi: true, tabWidth: 2, singleQuote: true, - jsxSingleQuote: false, + jsxSingleQuote: true, bracketSpacing: true, tsxSingleQuote: true, tsSingleQuote: true, diff --git a/src/AppCockpit.tsx b/src/AppCockpit.tsx index c56b18fb..4c825be2 100644 --- a/src/AppCockpit.tsx +++ b/src/AppCockpit.tsx @@ -41,7 +41,7 @@ const Application = () => { }; const ImageBuilder = () => ( <Provider store={store}> - <Page className="no-masthead-sidebar" isContentFilled> + <Page className='no-masthead-sidebar' isContentFilled> <PageSection> <Application /> </PageSection> diff --git a/src/Components/Blueprints/BlueprintActionsMenu.tsx b/src/Components/Blueprints/BlueprintActionsMenu.tsx index dec3ff84..cee7447e 100644 --- a/src/Components/Blueprints/BlueprintActionsMenu.tsx +++ b/src/Components/Blueprints/BlueprintActionsMenu.tsx @@ -58,10 +58,10 @@ export const BlueprintActionsMenu: React.FunctionComponent< ref={toggleRef} isExpanded={showBlueprintActionsMenu} onClick={() => setShowBlueprintActionsMenu(!showBlueprintActionsMenu)} - variant="plain" - aria-label="blueprint menu toggle" + variant='plain' + aria-label='blueprint menu toggle' > - <EllipsisVIcon aria-hidden="true" /> + <EllipsisVIcon aria-hidden='true' /> </MenuToggle> )} > diff --git a/src/Components/Blueprints/BlueprintCard.tsx b/src/Components/Blueprints/BlueprintCard.tsx index e77cb953..7a2ddb95 100644 --- a/src/Components/Blueprints/BlueprintCard.tsx +++ b/src/Components/Blueprints/BlueprintCard.tsx @@ -52,7 +52,7 @@ const BlueprintCard = ({ blueprint }: blueprintProps) => { > <CardTitle> {isLoading && blueprint.id === selectedBlueprintId && ( - <Spinner size="md" /> + <Spinner size='md' /> )} {blueprint.name} </CardTitle> diff --git a/src/Components/Blueprints/BlueprintDiffModal.tsx b/src/Components/Blueprints/BlueprintDiffModal.tsx index 96effe58..1efbaac4 100644 --- a/src/Components/Blueprints/BlueprintDiffModal.tsx +++ b/src/Components/Blueprints/BlueprintDiffModal.tsx @@ -53,20 +53,20 @@ const BlueprintDiffModal = ({ /> <ModalBody> <DiffEditor - height="90vh" - language="json" + height='90vh' + language='json' original={JSON.stringify(baseBlueprint, undefined, 2)} modified={JSON.stringify(blueprint, undefined, 2)} /> </ModalBody> <ModalFooter> - <BuildImagesButton key="build-button"> + <BuildImagesButton key='build-button'> Synchronize images </BuildImagesButton> <Button - key="cancel-button" - variant="link" - type="button" + key='cancel-button' + variant='link' + type='button' onClick={onClose} > Cancel diff --git a/src/Components/Blueprints/BlueprintVersionFilter.tsx b/src/Components/Blueprints/BlueprintVersionFilter.tsx index 2ba17a9e..f3750f19 100644 --- a/src/Components/Blueprints/BlueprintVersionFilter.tsx +++ b/src/Components/Blueprints/BlueprintVersionFilter.tsx @@ -58,10 +58,10 @@ const BlueprintVersionFilter: React.FC<blueprintVersionFilterProps> = ({ shouldFocusToggleOnSelect > <DropdownList> - <DropdownItem value={'all'} key="all"> + <DropdownItem value={'all'} key='all'> All versions </DropdownItem> - <DropdownItem value={'latest'} key="newest"> + <DropdownItem value={'latest'} key='newest'> Newest </DropdownItem> </DropdownList> diff --git a/src/Components/Blueprints/BlueprintsPagination.tsx b/src/Components/Blueprints/BlueprintsPagination.tsx index ef2b5e5e..678a5298 100644 --- a/src/Components/Blueprints/BlueprintsPagination.tsx +++ b/src/Components/Blueprints/BlueprintsPagination.tsx @@ -50,8 +50,8 @@ const BlueprintsPagination = () => { page={currPage} onSetPage={onSetPage} onPerPageSelect={onPerPageSelect} - widgetId="blueprints-pagination-bottom" - data-testid="blueprints-pagination-bottom" + widgetId='blueprints-pagination-bottom' + data-testid='blueprints-pagination-bottom' isCompact /> ); diff --git a/src/Components/Blueprints/BlueprintsSideBar.tsx b/src/Components/Blueprints/BlueprintsSideBar.tsx index e2197693..6b5f4179 100644 --- a/src/Components/Blueprints/BlueprintsSideBar.tsx +++ b/src/Components/Blueprints/BlueprintsSideBar.tsx @@ -100,7 +100,7 @@ const BlueprintsSidebar = () => { if (isLoading) { return ( <Bullseye> - <Spinner size="xl" /> + <Spinner size='xl' /> </Bullseye> ); } @@ -114,8 +114,8 @@ const BlueprintsSidebar = () => { <EmptyBlueprintState icon={PlusCircleIcon} action={<Link to={resolveRelPath('imagewizard')}>Add blueprint</Link>} - titleText="No blueprints yet" - bodyText="Add a blueprint and optionally build related images." + titleText='No blueprints yet' + bodyText='Add a blueprint and optionally build related images.' /> ); } @@ -147,7 +147,7 @@ const BlueprintsSidebar = () => { <Flex justifyContent={{ default: 'justifyContentCenter' }}> <FlexItem> <Button - variant="link" + variant='link' isDisabled={!selectedBlueprintId} onClick={handleClickViewAll} > @@ -163,14 +163,14 @@ const BlueprintsSidebar = () => { icon={SearchIcon} action={ <Button - variant="link" + variant='link' onClick={() => dispatch(setBlueprintSearchInput(undefined))} > Clear all filters </Button> } - titleText="No blueprints found" - bodyText="No blueprints match your search criteria. Try a different search." + titleText='No blueprints found' + bodyText='No blueprints match your search criteria. Try a different search.' /> )} {blueprintsTotal > 0 && @@ -212,7 +212,7 @@ const BlueprintSearch = ({ blueprintsTotal }: blueprintSearchProps) => { return ( <SearchInput value={blueprintSearchInput || ''} - placeholder="Search by name or description" + placeholder='Search by name or description' onChange={(_event, value) => onChange(value)} onClear={() => onChange('')} resultsCount={`${blueprintsTotal} blueprints`} @@ -226,7 +226,7 @@ const EmptyBlueprintState = ({ icon, action, }: emptyBlueprintStateProps) => ( - <EmptyState headingLevel="h4" icon={icon} titleText={titleText} variant="sm"> + <EmptyState headingLevel='h4' icon={icon} titleText={titleText} variant='sm'> <EmptyStateBody>{bodyText}</EmptyStateBody> <EmptyStateFooter> <EmptyStateActions>{action}</EmptyStateActions> diff --git a/src/Components/Blueprints/BuildImagesButton.tsx b/src/Components/Blueprints/BuildImagesButton.tsx index 10abfbd2..6304d98a 100644 --- a/src/Components/Blueprints/BuildImagesButton.tsx +++ b/src/Components/Blueprints/BuildImagesButton.tsx @@ -101,17 +101,17 @@ export const BuildImagesButton = ({ children }: BuildImagesButtonPropTypes) => { onOpenChange={(isOpen: boolean) => setIsOpen(isOpen)} toggle={(toggleRef: React.Ref<MenuToggleElement>) => ( <MenuToggle - variant="primary" - data-testid="blueprint-build-image-menu" + variant='primary' + data-testid='blueprint-build-image-menu' ref={toggleRef} onClick={onToggleClick} isExpanded={isOpen} splitButtonItems={[ <MenuToggleAction - data-testid="blueprint-build-image-menu-option" - key="split-action" + data-testid='blueprint-build-image-menu-option' + key='split-action' onClick={onBuildHandler} - id="wizard-build-image-btn" + id='wizard-build-image-btn' isDisabled={ !selectedBlueprintId || deselectedTargets.length === blueprintImageType?.length @@ -127,7 +127,7 @@ export const BuildImagesButton = ({ children }: BuildImagesButtonPropTypes) => { } as React.CSSProperties } isInline - size="md" + size='md' /> </FlexItem> )} diff --git a/src/Components/Blueprints/DeleteBlueprintModal.tsx b/src/Components/Blueprints/DeleteBlueprintModal.tsx index 14a27d98..afd209d5 100644 --- a/src/Components/Blueprints/DeleteBlueprintModal.tsx +++ b/src/Components/Blueprints/DeleteBlueprintModal.tsx @@ -93,16 +93,16 @@ export const DeleteBlueprintModal: React.FunctionComponent< }; return ( <Modal variant={ModalVariant.small} isOpen={isOpen} onClose={onDeleteClose}> - <ModalHeader title={'Delete blueprint?'} titleIconVariant="warning" /> + <ModalHeader title={'Delete blueprint?'} titleIconVariant='warning' /> <ModalBody> All versions of {blueprintName} and its associated images will be deleted. </ModalBody> <ModalFooter> - <Button variant="danger" type="button" onClick={handleDelete}> + <Button variant='danger' type='button' onClick={handleDelete}> Delete </Button> - <Button variant="link" type="button" onClick={onDeleteClose}> + <Button variant='link' type='button' onClick={onDeleteClose}> Cancel </Button> </ModalFooter> diff --git a/src/Components/Blueprints/EditBlueprintButton.tsx b/src/Components/Blueprints/EditBlueprintButton.tsx index 4331df00..d227d973 100644 --- a/src/Components/Blueprints/EditBlueprintButton.tsx +++ b/src/Components/Blueprints/EditBlueprintButton.tsx @@ -16,7 +16,7 @@ export const EditBlueprintButton = () => { onClick={() => navigate(resolveRelPath(`imagewizard/${selectedBlueprintId}`)) } - variant="secondary" + variant='secondary' > Edit blueprint </Button> diff --git a/src/Components/Blueprints/ImportBlueprintModal.tsx b/src/Components/Blueprints/ImportBlueprintModal.tsx index 52b82820..e25908f4 100644 --- a/src/Components/Blueprints/ImportBlueprintModal.tsx +++ b/src/Components/Blueprints/ImportBlueprintModal.tsx @@ -258,9 +258,9 @@ export const ImportBlueprintModal: React.FunctionComponent< > <Button icon={<HelpIcon />} - variant="plain" - aria-label="About import" - className="pf-v6-u-pl-sm" + variant='plain' + aria-label='About import' + className='pf-v6-u-pl-sm' isInline /> </Popover> @@ -269,23 +269,23 @@ export const ImportBlueprintModal: React.FunctionComponent< /> <ModalBody> <Form> - <FormGroup fieldId="checkbox-import-custom-repositories"> + <FormGroup fieldId='checkbox-import-custom-repositories'> <Checkbox - label="Import missing custom repositories after file upload." + label='Import missing custom repositories after file upload.' isChecked={isCheckedImportRepos} onChange={() => setIsCheckedImportRepos((prev) => !prev)} - aria-label="Import Custom Repositories checkbox" - id="checkbox-import-custom-repositories" - name="Import Repositories" + aria-label='Import Custom Repositories checkbox' + id='checkbox-import-custom-repositories' + name='Import Repositories' /> </FormGroup> - <FormGroup fieldId="import-blueprint-file-upload"> + <FormGroup fieldId='import-blueprint-file-upload'> <FileUpload - id="import-blueprint-file-upload" - type="text" + id='import-blueprint-file-upload' + type='text' value={fileContent} filename={filename} - filenamePlaceholder="Drag and drop a file or upload one" + filenamePlaceholder='Drag and drop a file or upload one' onFileInputChange={handleFileInputChange} onDataChange={handleDataChange} onReadStarted={handleFileReadStarted} @@ -293,7 +293,7 @@ export const ImportBlueprintModal: React.FunctionComponent< onClearClick={handleClear} isLoading={isLoading} isReadOnly={true} - browseButtonText="Upload" + browseButtonText='Upload' dropzoneProps={{ accept: { 'text/json': ['.json'], 'text/plain': ['.toml'] }, maxSize: 512000, @@ -319,7 +319,7 @@ export const ImportBlueprintModal: React.FunctionComponent< </ModalBody> <ModalFooter> <Button - type="button" + type='button' isDisabled={isRejected || isInvalidFormat || !fileContent} onClick={() => navigate(resolveRelPath(`imagewizard/import`), { @@ -329,7 +329,7 @@ export const ImportBlueprintModal: React.FunctionComponent< > Review and finish </Button> - <Button variant="link" type="button" onClick={onImportClose}> + <Button variant='link' type='button' onClick={onImportClose}> Cancel </Button> </ModalFooter> diff --git a/src/Components/CloudProviderConfig/AWSConfig.tsx b/src/Components/CloudProviderConfig/AWSConfig.tsx index 4bd2404d..460e73d8 100644 --- a/src/Components/CloudProviderConfig/AWSConfig.tsx +++ b/src/Components/CloudProviderConfig/AWSConfig.tsx @@ -44,13 +44,13 @@ const AWSConfigToggle = ({ value, onChange }: ToggleGroupProps) => { }; return ( - <FormGroup label="Configure AWS Uploads"> + <FormGroup label='Configure AWS Uploads'> <Switch - id="aws-config-switch" - ouiaId="aws-config-switch" - aria-label="aws-config-switch" + id='aws-config-switch' + ouiaId='aws-config-switch' + aria-label='aws-config-switch' // empty label so there is no icon - label="" + label='' isChecked={value} onChange={handleChange} /> @@ -79,19 +79,19 @@ const AWSBucket = ({ value, onChange, isDisabled }: FormGroupProps<string>) => { if (isDisabled) { return ( - <DisabledInputGroup label={label} value={value} ariaLabel="aws-bucket" /> + <DisabledInputGroup label={label} value={value} ariaLabel='aws-bucket' /> ); } return ( <FormGroup label={label}> <ValidatedInput - placeholder="AWS bucket" - ariaLabel="aws-bucket" + placeholder='AWS bucket' + ariaLabel='aws-bucket' value={value || ''} validator={isAwsBucketValid} onChange={(_event, value) => onChange(value)} - helperText="Invalid AWS bucket name" + helperText='Invalid AWS bucket name' /> </FormGroup> ); @@ -100,7 +100,7 @@ const AWSBucket = ({ value, onChange, isDisabled }: FormGroupProps<string>) => { const CredsPathPopover = () => { return ( <Popover - minWidth="35rem" + minWidth='35rem' headerContent={'What is the AWS Credentials Path?'} bodyContent={ <Content> @@ -115,9 +115,9 @@ const CredsPathPopover = () => { > <Button icon={<HelpIcon />} - variant="plain" - aria-label="Credentials Path Info" - className="pf-v6-u-pl-sm header-button" + variant='plain' + aria-label='Credentials Path Info' + className='pf-v6-u-pl-sm header-button' /> </Popover> ); @@ -139,7 +139,7 @@ const AWSCredsPath = ({ <DisabledInputGroup value={value} label={label} - ariaLabel="aws-creds-path" + ariaLabel='aws-creds-path' /> ); } @@ -147,12 +147,12 @@ const AWSCredsPath = ({ return ( <FormGroup label={label}> <ValidatedInput - placeholder="Path to AWS credentials" - ariaLabel="aws-creds-path" + placeholder='Path to AWS credentials' + ariaLabel='aws-creds-path' value={value || ''} validator={isAwsCredsPathValid} onChange={(_event, value) => onChange(value)} - helperText="Invalid filepath for AWS credentials" + helperText='Invalid filepath for AWS credentials' /> </FormGroup> ); diff --git a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx index ed5523a4..2f5c96be 100644 --- a/src/Components/CloudProviderConfig/CloudProviderConfig.tsx +++ b/src/Components/CloudProviderConfig/CloudProviderConfig.tsx @@ -48,9 +48,9 @@ const ConfigError = ({ <EmptyState variant={EmptyStateVariant.xl} icon={ExclamationIcon} - color="#C9190B" + color='#C9190B' > - <Title headingLevel="h4" size="lg"> + <Title headingLevel='h4' size='lg'> Error @@ -59,7 +59,7 @@ const ConfigError = ({ - @@ -118,8 +118,8 @@ export const CloudProviderConfig = () => { { return ( { {optional && ( )} diff --git a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx index e042bb81..2a24d291 100644 --- a/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx +++ b/src/Components/CreateImageWizard/steps/FileSystem/components/FileSystemConfiguration.tsx @@ -72,13 +72,13 @@ const FileSystemConfiguration = () => { order to conform to best practices and ensure functionality.

@@ -87,7 +87,7 @@ const FileSystemConfiguration = () => { {(environments.includes('image-installer') || environments.includes('wsl')) && ( {