chore: clean up backend code and build shared deps in CI
This commit is contained in:
1 parent
97c237be80
commit
94d52c7622
10 files changed
+17
-150
No files matched your search
@@ -82,7 +82,3 @@ func ignoreNotificationError(err error) {
|
||||
fmt.Printf("[notifications] enqueue failed: %v\n", err)
|
||||
}
|
||||
}
|
||||
|
||||
func isNoRows(err error) bool {
|
||||
return err == pgx.ErrNoRows
|
||||
}
|
||||
@@ -19,7 +19,6 @@ import (
|
||||
_ "github.com/joho/godotenv/autoload"
|
||||
|
||||
sharedauth "repos.gfranz.ch/Gabriel20xx/shared/backend/auth"
|
||||
"repos.gfranz.ch/Gabriel20xx/shared/backend/carriernodeclient"
|
||||
"repos.gfranz.ch/Gabriel20xx/shared/backend/coreconfig"
|
||||
sharedpostgres "repos.gfranz.ch/Gabriel20xx/shared/backend/postgres"
|
||||
)
|
||||
@@ -37,7 +36,6 @@ type Server struct {
|
||||
startTime time.Time
|
||||
internalServiceSecret string
|
||||
coreConfig *coreconfig.Store
|
||||
carrierNode *carriernodeclient.Client
|
||||
syncSlots chan struct{}
|
||||
// trustedProxies are the TRUSTED_PROXIES networks whose X-Forwarded-For and
|
||||
// X-Forwarded-Proto headers are believed. Nil trusts no proxy.
|
||||
@@ -119,17 +117,12 @@ func main() {
|
||||
auth.SetAuthGuardBaseURL(info.AuthGuardURL)
|
||||
}
|
||||
})
|
||||
carrierNode := carriernodeclient.New(internalServiceSecret, func(context.Context) string {
|
||||
return coreConfig.CarrierNodeURL()
|
||||
})
|
||||
|
||||
server := &Server{
|
||||
db: database,
|
||||
auth: auth,
|
||||
startTime: time.Now(),
|
||||
internalServiceSecret: internalServiceSecret,
|
||||
coreConfig: coreConfig,
|
||||
carrierNode: carrierNode,
|
||||
syncSlots: make(chan struct{}, maxConcurrentSyncs),
|
||||
trustedProxies: trustedProxies,
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user