refactor: adopt worker module path
Некоторые проверки не удались
CI / test (push) Successful in 2m5s
Docker / Build and publish worker image (push) Failing after 31s
Некоторые проверки не удались
CI / test (push) Successful in 2m5s
Docker / Build and publish worker image (push) Failing after 31s
Этот коммит содержится в:
@@ -1,7 +1,7 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Access represents membership of a User (or ApiKey) within a tenant
|
// Access represents membership of a User (or ApiKey) within a tenant
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import (
|
|||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Account represents a tenant — an isolated billing/permissions boundary
|
// Account represents a tenant — an isolated billing/permissions boundary
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestCreateAccountForUserStartsTeamTrial(t *testing.T) {
|
func TestCreateAccountForUserStartsTeamTrial(t *testing.T) {
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ package models
|
|||||||
import (
|
import (
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// ApiKey represents an API authentication key. //nolint:revive // accepted lint exception
|
// ApiKey represents an API authentication key. //nolint:revive // accepted lint exception
|
||||||
|
|||||||
@@ -10,8 +10,8 @@ import (
|
|||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/wire"
|
"rocketgit.ru/rsmon/worker/internal/wire"
|
||||||
)
|
)
|
||||||
|
|
||||||
// seedAggregatorWorld creates the minimum fixture the aggregator tests
|
// seedAggregatorWorld creates the minimum fixture the aggregator tests
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ package models
|
|||||||
import (
|
import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/internal/influx"
|
"rocketgit.ru/rsmon/worker/internal/influx"
|
||||||
)
|
)
|
||||||
|
|
||||||
// CheckData provides functionality.
|
// CheckData provides functionality.
|
||||||
|
|||||||
@@ -11,8 +11,8 @@ import (
|
|||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
"gorm.io/gorm/clause"
|
"gorm.io/gorm/clause"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/internal/influx"
|
"rocketgit.ru/rsmon/worker/internal/influx"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/wire"
|
"rocketgit.ru/rsmon/worker/internal/wire"
|
||||||
)
|
)
|
||||||
|
|
||||||
// defaultRegionCode is the historical default region seeded by Migrate()
|
// defaultRegionCode is the historical default region seeded by Migrate()
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ import (
|
|||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/config/database"
|
"rocketgit.ru/rsmon/worker/config/database"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ package models
|
|||||||
import (
|
import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// CheckRegionResult stores check results from distributed workers by region
|
// CheckRegionResult stores check results from distributed workers by region
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// makeStaleUser inserts a user whose LastActiveAt is older than the
|
// makeStaleUser inserts a user whose LastActiveAt is older than the
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ package models
|
|||||||
import (
|
import (
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Contact represents a notification contact.
|
// Contact represents a notification contact.
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TestSystemContacts verifies that SystemContacts returns only contacts with
|
// TestSystemContacts verifies that SystemContacts returns only contacts with
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import (
|
|||||||
"os"
|
"os"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/config/secrets"
|
"rocketgit.ru/rsmon/worker/config/secrets"
|
||||||
)
|
)
|
||||||
|
|
||||||
const credentialKeyEnv = "RSMON_CRED_KEY"
|
const credentialKeyEnv = "RSMON_CRED_KEY"
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import (
|
|||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TestReapDeadWorkers_SkipsHealthyAndKillsSilent mirrors the
|
// TestReapDeadWorkers_SkipsHealthyAndKillsSilent mirrors the
|
||||||
|
|||||||
@@ -11,8 +11,8 @@ import (
|
|||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/config/database"
|
"rocketgit.ru/rsmon/worker/config/database"
|
||||||
)
|
)
|
||||||
|
|
||||||
var gormErrRecordNotFound = gorm.ErrRecordNotFound
|
var gormErrRecordNotFound = gorm.ErrRecordNotFound
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import (
|
|||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// DeploymentKind is the rstuff-mirrored lifecycle label for a
|
// DeploymentKind is the rstuff-mirrored lifecycle label for a
|
||||||
|
|||||||
@@ -3,9 +3,9 @@ package models
|
|||||||
import (
|
import (
|
||||||
"log"
|
"log"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/internal/netaddr"
|
"rocketgit.ru/rsmon/worker/internal/netaddr"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// DNSRecord provides functionality.
|
// DNSRecord provides functionality.
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Domain represents a customer-facing DNS name. The shape mirrors
|
// Domain represents a customer-facing DNS name. The shape mirrors
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/authidentity"
|
"rocketgit.ru/rsmon/worker/app/models/authidentity"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Drop removes all test data from the database.
|
// Drop removes all test data from the database.
|
||||||
|
|||||||
@@ -7,8 +7,8 @@ import (
|
|||||||
"github.com/lib/pq"
|
"github.com/lib/pq"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/util"
|
"rocketgit.ru/rsmon/worker/internal/util"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Event provides functionality.
|
// Event provides functionality.
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import "rsgit.ru/rsmon/rsmon/app/models/concerns"
|
import "rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
|
|
||||||
// Group represents a monitor group.
|
// Group represents a monitor group.
|
||||||
type Group struct {
|
type Group struct {
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TestSystemGroups verifies that SystemGroups returns only groups with
|
// TestSystemGroups verifies that SystemGroups returns only groups with
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestServer_RotateToken(t *testing.T) {
|
func TestServer_RotateToken(t *testing.T) {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Invite provides functionality.
|
// Invite provides functionality.
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import "rsgit.ru/rsmon/rsmon/app/models/concerns"
|
import "rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
|
|
||||||
// LLM stores an OpenAI-compatible LLM endpoint available to checks.
|
// LLM stores an OpenAI-compatible LLM endpoint available to checks.
|
||||||
type LLM struct {
|
type LLM struct {
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import (
|
|||||||
"github.com/robfig/cron/v3"
|
"github.com/robfig/cron/v3"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestMaintenanceValidateGeneratesRecurringCron(t *testing.T) {
|
func TestMaintenanceValidateGeneratesRecurringCron(t *testing.T) {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Message info about performed notification
|
// Message info about performed notification
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/authidentity"
|
"rocketgit.ru/rsmon/worker/app/models/authidentity"
|
||||||
)
|
)
|
||||||
|
|
||||||
// isTypeExistsError returns true if the error is a Postgres "type already exists" error.
|
// isTypeExistsError returns true if the error is a Postgres "type already exists" error.
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import (
|
|||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
"gorm.io/gorm/clause"
|
"gorm.io/gorm/clause"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// monitorStateTestWorld bundles the account/group/monitor fixture the
|
// monitorStateTestWorld bundles the account/group/monitor fixture the
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TestMonitorTransferGroupSwap verifies that swapping a monitor's
|
// TestMonitorTransferGroupSwap verifies that swapping a monitor's
|
||||||
|
|||||||
@@ -11,9 +11,9 @@ import (
|
|||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
"gorm.io/gorm/clause"
|
"gorm.io/gorm/clause"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/influx"
|
"rocketgit.ru/rsmon/worker/internal/influx"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/wire"
|
"rocketgit.ru/rsmon/worker/internal/wire"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ import (
|
|||||||
"log"
|
"log"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/workdays"
|
"rocketgit.ru/rsmon/worker/internal/workdays"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Notification provides functionality.
|
// Notification provides functionality.
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// NotificationCredential kinds stored in the database.
|
// NotificationCredential kinds stored in the database.
|
||||||
|
|||||||
@@ -7,8 +7,8 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/config/database"
|
"rocketgit.ru/rsmon/worker/config/database"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|||||||
@@ -7,8 +7,8 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/spec/factories"
|
"rocketgit.ru/rsmon/worker/spec/factories"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TestNotificationGetContactsIncludesSystemContact exercises the regression
|
// TestNotificationGetContactsIncludesSystemContact exercises the regression
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import "rsgit.ru/rsmon/rsmon/app/models/concerns"
|
import "rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
|
|
||||||
// Payment provides functionality.
|
// Payment provides functionality.
|
||||||
type Payment struct {
|
type Payment struct {
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/lib/pq"
|
"github.com/lib/pq"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
var canonicalPlanCodes = []string{"free", "solo", "team", "enterprise"}
|
var canonicalPlanCodes = []string{"free", "solo", "team", "enterprise"}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// DefaultRegionCode is the historical default region code seeded by
|
// DefaultRegionCode is the historical default region code seeded by
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ package models
|
|||||||
import (
|
import (
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Repo is a source repository shared by one or more account-scoped sites.
|
// Repo is a source repository shared by one or more account-scoped sites.
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ package models
|
|||||||
import (
|
import (
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// RknDomain is one row of the locally cached ru-blocked domains list. The
|
// RknDomain is one row of the locally cached ru-blocked domains list. The
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestReplaceRknDomains_BulkAndDedup(t *testing.T) {
|
func TestReplaceRknDomains_BulkAndDedup(t *testing.T) {
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ import (
|
|||||||
|
|
||||||
"github.com/davecgh/go-spew/spew"
|
"github.com/davecgh/go-spew/spew"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/netaddr"
|
"rocketgit.ru/rsmon/worker/internal/netaddr"
|
||||||
)
|
)
|
||||||
|
|
||||||
// RknIP stores a single CIDR from the ru-blocked IP list. The cidr column
|
// RknIP stores a single CIDR from the ru-blocked IP list. The cidr column
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
func mustIPNet(t *testing.T, cidr string) *net.IPNet {
|
func mustIPNet(t *testing.T, cidr string) *net.IPNet {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// SelfCheck provides functionality.
|
// SelfCheck provides functionality.
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ import (
|
|||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// AccountMCPToken stores a one-way verifier. MCP tokens are bearer credentials
|
// AccountMCPToken stores a one-way verifier. MCP tokens are bearer credentials
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// ServerIp is a single IP (v4 or v6) bound to a Server. The
|
// ServerIp is a single IP (v4 or v6) bound to a Server. The
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import (
|
|||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Site represents a customer-facing website or app. One Site can be
|
// Site represents a customer-facing website or app. One Site can be
|
||||||
|
|||||||
@@ -34,8 +34,8 @@ import (
|
|||||||
"golang.org/x/net/idna"
|
"golang.org/x/net/idna"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
"rsgit.ru/rsmon/rsmon/config/credis"
|
"rocketgit.ru/rsmon/worker/config/credis"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Status page color defaults. Matches the existing landing-page primary
|
// Status page color defaults. Matches the existing landing-page primary
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ import (
|
|||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
"gorm.io/gorm/clause"
|
"gorm.io/gorm/clause"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/internal/wire"
|
"rocketgit.ru/rsmon/worker/internal/wire"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// statusPageSeedAcc returns a fresh account for status-page tests.
|
// statusPageSeedAcc returns a fresh account for status-page tests.
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package models
|
package models
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Tag stores metadata for a single tag name within an account: the
|
// Tag stores metadata for a single tag name within an account: the
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// seedTagsMonitors creates one group with four monitors:
|
// seedTagsMonitors creates one group with four monitors:
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import (
|
|||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
"gorm.io/gorm/clause"
|
"gorm.io/gorm/clause"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Task kinds stored in the tasks.kind column. The plan (docs/plans/worker-notifier-mvp.md
|
// Task kinds stored in the tasks.kind column. The plan (docs/plans/worker-notifier-mvp.md
|
||||||
|
|||||||
@@ -12,8 +12,8 @@ import (
|
|||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/config/database"
|
"rocketgit.ru/rsmon/worker/config/database"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ package models
|
|||||||
import (
|
import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestTelegramBotCurrentStatusMarksStaleOffline(t *testing.T) {
|
func TestTelegramBotCurrentStatusMarksStaleOffline(t *testing.T) {
|
||||||
|
|||||||
@@ -10,8 +10,8 @@ import (
|
|||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/authidentity"
|
"rocketgit.ru/rsmon/worker/app/models/authidentity"
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// User represents a platform user.
|
// User represents a platform user.
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
|
|
||||||
"github.com/lib/pq"
|
"github.com/lib/pq"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Whois provides functionality.
|
// Whois provides functionality.
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// WorkerLogEvent stores critical log events sent by worker nodes. The same
|
// WorkerLogEvent stores critical log events sent by worker nodes. The same
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models/concerns"
|
"rocketgit.ru/rsmon/worker/app/models/concerns"
|
||||||
)
|
)
|
||||||
|
|
||||||
// WorkerNode represents a distributed monitoring worker
|
// WorkerNode represents a distributed monitoring worker
|
||||||
|
|||||||
@@ -22,9 +22,9 @@ import (
|
|||||||
"github.com/openai/openai-go/v3"
|
"github.com/openai/openai-go/v3"
|
||||||
"github.com/openai/openai-go/v3/option"
|
"github.com/openai/openai-go/v3/option"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
"rsgit.ru/rsmon/rsmon/storage"
|
"rocketgit.ru/rsmon/worker/storage"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ The check provides the following metrics:
|
|||||||
## Example Usage
|
## Example Usage
|
||||||
|
|
||||||
```go
|
```go
|
||||||
import "rsgit.ru/rsmon/rsmon/checks/cbssl"
|
import "rocketgit.ru/rsmon/worker/checks/cbssl"
|
||||||
|
|
||||||
// Perform the check
|
// Perform the check
|
||||||
result := cbssl.Perform(check)
|
result := cbssl.Perform(check)
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ import (
|
|||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const stateOK = "OK"
|
const stateOK = "OK"
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is a result of a browser-based SSL certificate check
|
// Result is a result of a browser-based SSL certificate check
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import (
|
|||||||
|
|
||||||
"github.com/miekg/dns"
|
"github.com/miekg/dns"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/internal/netaddr"
|
"rocketgit.ru/rsmon/worker/internal/netaddr"
|
||||||
)
|
)
|
||||||
|
|
||||||
// FetchARecords provides functionality.
|
// FetchARecords provides functionality.
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ import (
|
|||||||
"github.com/miekg/dns"
|
"github.com/miekg/dns"
|
||||||
"github.com/weppos/publicsuffix-go/publicsuffix"
|
"github.com/weppos/publicsuffix-go/publicsuffix"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -5,9 +5,9 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/netaddr"
|
"rocketgit.ru/rsmon/worker/internal/netaddr"
|
||||||
)
|
)
|
||||||
|
|
||||||
// NSIP holds the result of querying a single nameserver IP.
|
// NSIP holds the result of querying a single nameserver IP.
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const stateERR = "ERR"
|
const stateERR = "ERR"
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package cftp
|
package cftp
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is a result of a check
|
// Result is a result of a check
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ import (
|
|||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result provides functionality.
|
// Result provides functionality.
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ import (
|
|||||||
"golang.org/x/net/icmp"
|
"golang.org/x/net/icmp"
|
||||||
"golang.org/x/net/ipv4"
|
"golang.org/x/net/ipv4"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// settings mirrors models.CheckSettings so the test can build a
|
// settings mirrors models.CheckSettings so the test can build a
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is the outcome of a single ping check. It embeds
|
// Result is the outcome of a single ping check. It embeds
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
package crkn
|
package crkn
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is a result of a check
|
// Result is a result of a check
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import (
|
|||||||
"errors"
|
"errors"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Perform checks if a domain or IP is in the RKN registry
|
// Perform checks if a domain or IP is in the RKN registry
|
||||||
|
|||||||
@@ -7,10 +7,10 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/checks/crkn"
|
"rocketgit.ru/rsmon/worker/checks/crkn"
|
||||||
"rsgit.ru/rsmon/rsmon/config/database"
|
"rocketgit.ru/rsmon/worker/config/database"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/netaddr"
|
"rocketgit.ru/rsmon/worker/internal/netaddr"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const stateERR = "ERR"
|
const stateERR = "ERR"
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package cssh
|
package cssh
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is a result of a check
|
// Result is a result of a check
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import (
|
|||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
var client *http.Client
|
var client *http.Client
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
package cssl
|
package cssl
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is a result of a check
|
// Result is a result of a check
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is the outcome of a single TCP check. It embeds
|
// Result is the outcome of a single TCP check. It embeds
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ import (
|
|||||||
"net"
|
"net"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
type settings struct {
|
type settings struct {
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is the outcome of a single UDP check. It embeds
|
// Result is the outcome of a single UDP check. It embeds
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ import (
|
|||||||
"net"
|
"net"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import (
|
|||||||
|
|
||||||
"gorm.io/datatypes"
|
"gorm.io/datatypes"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
type settings struct {
|
type settings struct {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ package cwhois
|
|||||||
import (
|
import (
|
||||||
"github.com/glebtv/whois"
|
"github.com/glebtv/whois"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is a result of a check
|
// Result is a result of a check
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import (
|
|||||||
"github.com/glebtv/whois"
|
"github.com/glebtv/whois"
|
||||||
"github.com/weppos/publicsuffix-go/publicsuffix"
|
"github.com/weppos/publicsuffix-go/publicsuffix"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Perform provides functionality.
|
// Perform provides functionality.
|
||||||
|
|||||||
@@ -17,8 +17,8 @@ import (
|
|||||||
"github.com/openai/openai-go/v3"
|
"github.com/openai/openai-go/v3"
|
||||||
"github.com/openai/openai-go/v3/option"
|
"github.com/openai/openai-go/v3/option"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Result is a result of an LLM HTTP health check
|
// Result is a result of an LLM HTTP health check
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import (
|
|||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/checkresult"
|
"rocketgit.ru/rsmon/worker/internal/checkresult"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestInfluxTags(t *testing.T) {
|
func TestInfluxTags(t *testing.T) {
|
||||||
|
|||||||
@@ -18,9 +18,9 @@ import (
|
|||||||
"github.com/hashicorp/raft"
|
"github.com/hashicorp/raft"
|
||||||
"github.com/joho/godotenv"
|
"github.com/joho/godotenv"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/internal/distworker"
|
"rocketgit.ru/rsmon/worker/internal/distworker"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/webapp"
|
"rocketgit.ru/rsmon/worker/internal/webapp"
|
||||||
"rsgit.ru/rsmon/rsmon/internal/workercluster"
|
"rocketgit.ru/rsmon/worker/internal/workercluster"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ package application
|
|||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
_ "rsgit.ru/rsmon/rsmon/config/env" // Import to ensure .env is loaded before reading env vars
|
_ "rocketgit.ru/rsmon/worker/config/env" // Import to ensure .env is loaded before reading env vars
|
||||||
)
|
)
|
||||||
|
|
||||||
// Env provides functionality.
|
// Env provides functionality.
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import (
|
|||||||
"github.com/gorilla/sessions"
|
"github.com/gorilla/sessions"
|
||||||
"github.com/rbcervilla/redisstore/v8"
|
"github.com/rbcervilla/redisstore/v8"
|
||||||
|
|
||||||
_ "rsgit.ru/rsmon/rsmon/config/env" // Import to ensure .env is loaded before reading env vars
|
_ "rocketgit.ru/rsmon/worker/config/env" // Import to ensure .env is loaded before reading env vars
|
||||||
)
|
)
|
||||||
|
|
||||||
// Redis provides functionality.
|
// Redis provides functionality.
|
||||||
|
|||||||
@@ -11,8 +11,8 @@ import (
|
|||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
"gorm.io/gorm/logger"
|
"gorm.io/gorm/logger"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/app/models"
|
"rocketgit.ru/rsmon/worker/app/models"
|
||||||
_ "rsgit.ru/rsmon/rsmon/config/env" // Import to ensure .env is loaded before reading env vars
|
_ "rocketgit.ru/rsmon/worker/config/env" // Import to ensure .env is loaded before reading env vars
|
||||||
)
|
)
|
||||||
|
|
||||||
// db Gorm DB
|
// db Gorm DB
|
||||||
|
|||||||
@@ -8,8 +8,8 @@ import (
|
|||||||
|
|
||||||
"github.com/go-yaml/yaml"
|
"github.com/go-yaml/yaml"
|
||||||
|
|
||||||
"rsgit.ru/rsmon/rsmon/config/application"
|
"rocketgit.ru/rsmon/worker/config/application"
|
||||||
_ "rsgit.ru/rsmon/rsmon/config/env" // Import to ensure .env is loaded before reading env vars
|
_ "rocketgit.ru/rsmon/worker/config/env" // Import to ensure .env is loaded before reading env vars
|
||||||
)
|
)
|
||||||
|
|
||||||
const envTest = "test"
|
const envTest = "test"
|
||||||
|
|||||||
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Ссылка в новой задаче
Block a user