mirror of
https://github.com/harness/drone.git
synced 2025-05-06 06:29:39 +08:00

* feat: [CDE-127]: Linting. * Merge branch 'refs/heads/main' into CDE-127 # Conflicts: # app/gitspace/orchestrator/container/embedded_docker.go # cmd/gitness/wire.go * feat: [CDE-127]: Addressing review comments. * feat: [CDE-127]: Removing streams map from StatefulLogger. Flushing the stream every time the invoking function is closed. * feat: [CDE-127]: Removing streams map from StatefulLogger. Flushing the stream every time the invoking function is closed. * feat: [CDE-127]: Removing streams map from StatefulLogger. Flushing the stream every time the invoking function is closed. * feat: [CDE-127]: Removing streams map from StatefulLogger. Flushing the stream every time the invoking function is closed. * feat: [CDE-127]: Adding flush stream logic to delete gitspace in orchestrator. Linting. * feat: [CDE-127]: Adding flush stream logic to delete gitspace in orchestrator. Linting. * feat: [CDE-127]: Addressing review comments. * feat: [CDE-127]: Adding changes to make logutil.StatefulLogger a wrapper on livelog.LogStream and adding initialisation and flush functions. * feat: [CDE-127]: Adding changes to make logutil.StatefulLogger a wrapper on livelog.LogStream and adding initialisation and flush functions. * feat: [CDE-127]: Adding changes to include logging in container orchestration's stop flow. * feat: [CDE-127]: Adding changes to include logging in container orchestration's start flow.
53 lines
1.4 KiB
Go
53 lines
1.4 KiB
Go
// Copyright 2023 Harness, Inc.
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
|
|
package container
|
|
|
|
import (
|
|
"github.com/harness/gitness/app/gitspace/logutil"
|
|
"github.com/harness/gitness/infraprovider"
|
|
|
|
"github.com/google/wire"
|
|
)
|
|
|
|
var WireSet = wire.NewSet(
|
|
ProvideEmbeddedDockerOrchestrator,
|
|
ProvideVSCodeWebService,
|
|
ProvideVSCodeService,
|
|
)
|
|
|
|
func ProvideEmbeddedDockerOrchestrator(
|
|
dockerClientFactory *infraprovider.DockerClientFactory,
|
|
vsCodeService *VSCode,
|
|
vsCodeWebService *VSCodeWeb,
|
|
config *Config,
|
|
statefulLogger *logutil.StatefulLogger,
|
|
) Orchestrator {
|
|
return NewEmbeddedDockerOrchestrator(
|
|
dockerClientFactory,
|
|
vsCodeService,
|
|
vsCodeWebService,
|
|
config,
|
|
statefulLogger,
|
|
)
|
|
}
|
|
|
|
func ProvideVSCodeWebService(config *VSCodeWebConfig) *VSCodeWeb {
|
|
return NewVsCodeWebService(config)
|
|
}
|
|
|
|
func ProvideVSCodeService() *VSCode {
|
|
return NewVsCodeService()
|
|
}
|