mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-18 23:31:05 +00:00
6fc17ad37b
- Use TXT records in order to determine the latest available version. - This addresses a valid privacy issue, as with HTTP requests the server can keep track(estimated) of how many instances are using Forgejo, with DNS that's basically not possible as the server will never receive any data, as the only ones receiving data are DNS resolvers. (cherry picked from commit0baefb546a
) (cherry picked from commite8ee41880b
) (cherry picked from commit7eca4f3bf1
) (cherry picked from commit6dde3992dc
) (cherry picked from commitfb3a37fbfc
) (cherry picked from commit8304af1e9d
) (cherry picked from commit0543a7d12a
) (cherry picked from commitc3a22933b7
) (cherry picked from commite243707694
) (cherry picked from commit7eb6d1bcf7
) (cherry picked from commit1d7b9535cd
) (cherry picked from commit05920dce67
) (cherry picked from commitf173f27d7c
) (cherry picked from commit90e1c9340e
) (cherry picked from commitde68610ea7
) (cherry picked from commit8d5757ea04
) (cherry picked from commitc7a7fff316
) (cherry picked from commit39ac8b8fc1
) (cherry picked from commit9889203301
) [PRIVACY]: Adjust update checker description - Resolves #323 - Adjust the description of the update check function on the installation page to describe the privacy method instead of the HTTP method by checking gitea.io (cherry picked from commit61eae5b105
) (cherry picked from commit091def20a1
) (cherry picked from commitd5d11bf45a
) (cherry picked from commit71863d4707
) (cherry picked from commit11ece4aab1
) (cherry picked from commitafdd7e714f
) (cherry picked from commit39170e2f1d
) (cherry picked from commit4b3a52aab8
) (cherry picked from commit9d763c5fc8
) (cherry picked from commit638db15482
) (cherry picked from commita52bfdd8e7
) (cherry picked from commitdc93d00e85
) (cherry picked from commit0bc4b3508c
) (cherry picked from commit3f760d85a4
) (cherry picked from commitecc2716785
) (cherry picked from commit6334d5677e
) Conflicts: modules/updatechecker/update_checker.go UpdateRemoteVersion now has a context argument. However, in the updated code from Gitea the context comes from the HTTP request and does not actually provide any useful context. Replace that with context.Background() (cherry picked from commitca2200767e
) (cherry picked from commitf46feca224
) (cherry picked from commita800a66ca8
) (cherry picked from commit21f017454e
) (cherry picked from commit762d18e09a
) (cherry picked from commit6d28e120c1
) (cherry picked from commit4fcd7e7cbf
) (cherry picked from commit9516285112
) (cherry picked from commit0dd752a262
) (cherry picked from commitb1f1af7fe0
) (cherry picked from commit71937deaa5
) (cherry picked from commit93e41a7823
) (cherry picked from commitf497ed30cf
) (cherry picked from commitbff3346f7d
) (cherry picked from commit906ae19c0f
)
16 lines
322 B
Go
16 lines
322 B
Go
// Copyright 2023 The Forgejo Authors. All rights reserved.
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
package updatechecker
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
)
|
|
|
|
func TestDNSUpdate(t *testing.T) {
|
|
version, err := getVersionDNS("release.forgejo.org")
|
|
assert.NoError(t, err)
|
|
assert.NotEmpty(t, version)
|
|
}
|