Skip to content

Commit f668069

Browse files
committed
smartstate poc using a container in the agent
the container exposes a service that recieves the cluster credentials, runs the smartstate and will return the results as a bulk when done. Signed-off-by: borod108 <[email protected]>
1 parent bbf9e82 commit f668069

15 files changed

+824
-66
lines changed

Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ GO_FILES := $(shell find ./ -name ".go" -not -path "./bin" -not -path "./packagi
66
GO_CACHE := -v $${HOME}/go/migration-planner-go-cache:/opt/app-root/src/go:Z -v $${HOME}/go/migration-planner-go-cache/.cache:/opt/app-root/src/.cache:Z
77
TIMEOUT ?= 30m
88
VERBOSE ?= false
9-
MIGRATION_PLANNER_AGENT_IMAGE ?= quay.io/kubev2v/migration-planner-agent
10-
MIGRATION_PLANNER_API_IMAGE ?= quay.io/kubev2v/migration-planner-api
9+
MIGRATION_PLANNER_AGENT_IMAGE ?= quay.io/bodnopoz/migration-planner-agent
10+
MIGRATION_PLANNER_API_IMAGE ?= quay.io/bodnopoz/migration-planner-api
1111
MIGRATION_PLANNER_API_IMAGE_PULL_POLICY ?= Always
1212
MIGRATION_PLANNER_UI_IMAGE ?= quay.io/kubev2v/migration-planner-ui
1313
MIGRATION_PLANNER_NAMESPACE ?= assisted-migration

api/v1alpha1/agent/spec.gen.go

+22-22
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/v1alpha1/openapi.yaml

+9-1
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,9 @@ components:
385385
infra:
386386
type: object
387387
$ref: '#/components/schemas/Infra'
388-
388+
smartState:
389+
type: object
390+
$ref: '#/components/schemas/SmartState'
389391
VCenter:
390392
type: object
391393
required:
@@ -440,6 +442,12 @@ components:
440442
type: object
441443
$ref: '#/components/schemas/MigrationIssues'
442444

445+
SmartState:
446+
type: array
447+
items:
448+
type: object
449+
additionalProperties: true
450+
443451
Infra:
444452
type: object
445453
required:

api/v1alpha1/spec.gen.go

+25-25
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/v1alpha1/types.gen.go

+7-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

data/ignition.template

+21
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,27 @@ storage:
100100
name: core
101101
group:
102102
name: core
103+
104+
- path: /home/core/.config/containers/systemd/manageiq-service.container
105+
mode: 0644
106+
contents:
107+
inline: |
108+
[Unit]
109+
Description=ManageIQ SmartState Service
110+
111+
[Container]
112+
ContainerName=manageiq-service
113+
Image=quay.io/bodnopoz/manageiq-service:latest
114+
PublishPort=3334:3334
115+
Network=host
116+
UserNS=keep-id:uid=1001
117+
118+
[Service]
119+
Restart=on-failure
120+
RestartSec=5
121+
122+
[Install]
123+
WantedBy=multi-user.target default.target
103124
- path: /home/core/.config/containers/systemd/planner-agent.container
104125
mode: 0644
105126
contents:

0 commit comments

Comments
 (0)