diff --git a/cli/configure.js b/cli/configure.js index c50b81fa..9c573def 100644 --- a/cli/configure.js +++ b/cli/configure.js @@ -39,6 +39,7 @@ const { port, title, host, + channelClaimBidAmount: channelBid, }, publishing: { uploadDirectory, @@ -157,7 +158,7 @@ inquirer method: 'channel_new', params: { channel_name: thumbnailChannelDefault, - amount : '0.1', + amount : channelBid, }, }) .then(response => { diff --git a/cli/defaults/siteConfig.json b/cli/defaults/siteConfig.json index e84f5a45..4d79624d 100644 --- a/cli/defaults/siteConfig.json +++ b/cli/defaults/siteConfig.json @@ -31,7 +31,9 @@ "serveOnlyApproved": false, "publishOnlyApproved": false, "approvedChannels": [], - "publishingChannelWhitelist": [] + "publishingChannelWhitelist": [], + "channelClaimBidAmount": "0.1", + "fileClaimBidAmount": "0.01" }, "startup": { "performChecks": true, diff --git a/server/controllers/api/claim/publish/createPublishParams.js b/server/controllers/api/claim/publish/createPublishParams.js index a278bbee..242f4312 100644 --- a/server/controllers/api/claim/publish/createPublishParams.js +++ b/server/controllers/api/claim/publish/createPublishParams.js @@ -1,6 +1,5 @@ const logger = require('winston'); const { details, publishing } = require('@config/siteConfig'); - const createPublishParams = (filePath, name, title, description, license, nsfw, thumbnail, channelName, channelClaimId) => { // provide defaults for title if (title === null || title.trim() === '') { @@ -18,7 +17,7 @@ const createPublishParams = (filePath, name, title, description, license, nsfw, const publishParams = { name, file_path: filePath, - bid : '0.01', + bid : publishing.fileClaimBidAmount, metadata : { description, title, diff --git a/server/controllers/api/claim/publish/createThumbnailPublishParams.js b/server/controllers/api/claim/publish/createThumbnailPublishParams.js index 668bd07c..576ddc73 100644 --- a/server/controllers/api/claim/publish/createThumbnailPublishParams.js +++ b/server/controllers/api/claim/publish/createThumbnailPublishParams.js @@ -10,7 +10,7 @@ const createThumbnailPublishParams = (thumbnailFilePath, claimName, license, nsf return { name : `${claimName}-thumb`, file_path: thumbnailFilePath, - bid : '0.01', + bid : publishing.fileClaimBidAmount, metadata : { title : `${claimName} thumbnail`, description: `a thumbnail for ${claimName}`, diff --git a/server/lbrynet/index.js b/server/lbrynet/index.js index 655909fa..1b914682 100644 --- a/server/lbrynet/index.js +++ b/server/lbrynet/index.js @@ -4,6 +4,7 @@ const { apiHost, apiPort, getTimeout } = require('@config/lbryConfig'); const lbrynetUri = 'http://' + apiHost + ':' + apiPort; const { chooseGaLbrynetPublishLabel, sendGATimingEvent } = require('../utils/googleAnalytics.js'); const handleLbrynetResponse = require('./utils/handleLbrynetResponse.js'); +const { publishing } = require('@config/siteConfig'); module.exports = { publishClaim (publishParams) { @@ -116,7 +117,7 @@ module.exports = { method: 'channel_new', params: { channel_name: name, - amount : '0.1', + amount : publishing.channelClaimBidAmount, }, }) .then(response => {