mirror of
https://github.com/lorsanstand/HomeOps-Hub.git
synced 2026-09-18 15:08:21 +03:00
refactor: refactor app
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
package docker_service
|
||||
|
||||
import "github.com/lorsanstand/HomeOps-Hub/internal/agent/domain"
|
||||
|
||||
type BadDocker struct {
|
||||
reason string
|
||||
}
|
||||
|
||||
func (d *BadDocker) Capability() domain.Capability {
|
||||
return domain.Capability{
|
||||
Name: "docker",
|
||||
Available: false,
|
||||
Version: "",
|
||||
Reason: d.reason,
|
||||
}
|
||||
}
|
||||
|
||||
func NewBadDocker(reason string) *BadDocker {
|
||||
return &BadDocker{reason: reason}
|
||||
}
|
||||
@@ -3,9 +3,10 @@ package docker_service
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/docker/docker/api/types"
|
||||
"github.com/docker/docker/api/types/container"
|
||||
"github.com/lorsanstand/HomeOps-Hub/internal/agent/domain"
|
||||
"github.com/moby/moby/api/types"
|
||||
"github.com/moby/moby/api/types/container"
|
||||
|
||||
"github.com/rs/zerolog"
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user