diff --git a/satellite/console/consoleweb/server.go b/satellite/console/consoleweb/server.go index 1e8769cdd..bc96e1ee0 100644 --- a/satellite/console/consoleweb/server.go +++ b/satellite/console/consoleweb/server.go @@ -89,6 +89,7 @@ type Config struct { CouponCodeUIEnabled bool `help:"indicates if user is allowed to add coupon codes to account" default:"false"` FileBrowserFlowDisabled bool `help:"indicates if file browser flow is disabled" default:"true"` CSPEnabled bool `help:"indicates if Content Security Policy is enabled" devDefault:"false" releaseDefault:"true"` + LinksharingURL string `help:"url link for linksharing requests" default:"https://link.tardigradeshare.io"` RateLimit web.IPRateLimiterConfig @@ -315,6 +316,7 @@ func (server *Server) appHandler(w http.ResponseWriter, r *http.Request) { DocumentationURL string CouponCodeUIEnabled bool FileBrowserFlowDisabled bool + LinksharingURL string } data.ExternalAddress = server.config.ExternalAddress @@ -334,6 +336,7 @@ func (server *Server) appHandler(w http.ResponseWriter, r *http.Request) { data.DocumentationURL = server.config.DocumentationURL data.CouponCodeUIEnabled = server.config.CouponCodeUIEnabled data.FileBrowserFlowDisabled = server.config.FileBrowserFlowDisabled + data.LinksharingURL = server.config.LinksharingURL if server.templates.index == nil { server.log.Error("index template is not set") diff --git a/scripts/testdata/satellite-config.yaml.lock b/scripts/testdata/satellite-config.yaml.lock index 4b282cd29..2ee0fe5fa 100755 --- a/scripts/testdata/satellite-config.yaml.lock +++ b/scripts/testdata/satellite-config.yaml.lock @@ -127,6 +127,9 @@ compensation.withheld-percents: 75,75,75,50,50,50,25,25,25,0,0,0,0,0,0 # url link to let us know page # console.let-us-know-url: https://storjlabs.atlassian.net/servicedesk/customer/portals +# url link for linksharing requests +# console.linksharing-url: https://link.tardigradeshare.io + # enable open registration # console.open-registration-enabled: false diff --git a/web/satellite/index.html b/web/satellite/index.html index 9424ead01..d20061b79 100644 --- a/web/satellite/index.html +++ b/web/satellite/index.html @@ -20,6 +20,7 @@ + {{ .SatelliteName }} diff --git a/web/satellite/src/components/objects/UploadFile.vue b/web/satellite/src/components/objects/UploadFile.vue index d11ce1b5f..7f987d53d 100644 --- a/web/satellite/src/components/objects/UploadFile.vue +++ b/web/satellite/src/components/objects/UploadFile.vue @@ -22,6 +22,7 @@ import { MetaUtils } from '@/utils/meta'; }, }) export default class UploadFile extends Vue { + private linksharingURL = ''; private worker: Worker; /** @@ -46,6 +47,8 @@ export default class UploadFile extends Vue { return; } + this.linksharingURL = MetaUtils.getMetaContent('linksharing-url'); + this.setWorker(); } @@ -80,7 +83,7 @@ export default class UploadFile extends Vue { try { const key: string = await this.accessKey(this.apiKey, inADay, path); - return `https://link.tardigradeshare.io/s/${key}/${path}?map=1`; + return `${this.linksharingURL}/s/${key}/${path}?map=1`; } catch (error) { await this.$notify.error(error.message); @@ -101,7 +104,7 @@ export default class UploadFile extends Vue { try { const key: string = await this.accessKey(cleanAPIKey.secret, notAfter, path); - return `https://link.tardigradeshare.io/${key}/${path}`; + return `${this.linksharingURL}/${key}/${path}`; } catch (error) { await this.$notify.error(error.message);