Skip to content

Commit

Permalink
Run discovery with alizer addon only
Browse files Browse the repository at this point in the history
Signed-off-by: Sam Lucidi <[email protected]>
  • Loading branch information
mansam committed Jun 20, 2024
1 parent 2b97786 commit 778404e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
2 changes: 1 addition & 1 deletion api/application.go
Original file line number Diff line number Diff line change
Expand Up @@ -1350,7 +1350,7 @@ func (r *Stakeholders) contributors() (contributors []model.Stakeholder) {
func discover(ctx *gin.Context, application *model.Application) (err error) {
rtx := WithContext(ctx)
db := rtx.DB.Debug()
kinds := []string{Settings.Hub.Task.Kinds.Discovery.Language, Settings.Hub.Task.Kinds.Discovery.Technology}
kinds := []string{Settings.Hub.Task.Kinds.Discovery.Language}
for _, kind := range kinds {
t := model.Task{}
task := tasking.Task{Task: &t}
Expand Down
9 changes: 1 addition & 8 deletions settings/hub.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ const (
EnvAnalysisReportPath = "ANALYSIS_REPORT_PATH"
EnvAnalysisArchiverEnabled = "ANALYSIS_ARCHIVER_ENABLED"
EnvLanguageDiscoveryTask = "LANGUAGE_DISCOVERY_TASK"
EnvTechnologyDiscoveryTask = "TECHNOLOGY_DISCOVERY_TASK"
)

type Hub struct {
Expand Down Expand Up @@ -86,8 +85,7 @@ type Hub struct {
}
Kinds struct {
Discovery struct {
Language string
Technology string
Language string
}
}
}
Expand Down Expand Up @@ -266,15 +264,10 @@ func (r *Hub) Load() (err error) {
} else {
r.Analysis.ArchiverEnabled = true
}

r.Task.Kinds.Discovery.Language, found = os.LookupEnv(EnvLanguageDiscoveryTask)
if !found {
r.Task.Kinds.Discovery.Language = "language-discovery"
}
r.Task.Kinds.Discovery.Technology, found = os.LookupEnv(EnvTechnologyDiscoveryTask)
if !found {
r.Task.Kinds.Discovery.Technology = "tech-discovery"
}
return
}

Expand Down

0 comments on commit 778404e

Please sign in to comment.