Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hack: allow using new collector with SNI overrides #1547

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions internal/engine/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,20 @@ func (s *Session) doClose() {
func (s *Session) GetTestHelpersByName(name string) ([]model.OOAPIService, bool) {
defer s.mu.Unlock()
s.mu.Lock()

// TODO(https://github.com/ooni/probe/issues/2703): this change is a quick hack to
// make sure we have a way of testing the new TH deployment.
//
// We definitely NOT MEAN to merge this set of changes.
if th := os.Getenv("OONI_WEB_CONNECTIVITY_TH_URL"); th != "" {
custom := []model.OOAPIService{{
Address: th,
Type: "https",
Front: "",
}}
return custom, true
}

services, ok := s.availableTestHelpers[name]
return services, ok
}
Expand Down
1 change: 1 addition & 0 deletions internal/enginenetx/bridgespolicy.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ var bridgesPolicyTestHelpersDomains = []string{
"2.th.ooni.org",
"3.th.ooni.org",
"d33d1gs9kpq1c5.cloudfront.net",
"oohelperd.th.prod.ooni.io",
}

// TODO(bassosimone): this would be slices.Contains when we'll use go1.21
Expand Down
Loading