diff --git a/Dockerfile b/Dockerfile index f3069ab..0c4f041 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,14 @@ FROM node:18.18-bullseye +ARG BUILDDATE +ENV BUILDDATE $BUILDDATE + RUN git clone https://git.pblr-nyk.pro/gsd/Facti13.SteamTradeBot.JS.v1 && \ mv Facti13.SteamTradeBot.JS.v1 /app && chown node:node -R /app && chmod 770 -R /app && \ echo "const VERSION = $(date +%s);module.exports = VERSION;" > /app/version.js USER node WORKDIR /app -RUN npm install +RUN npm install --reg https://nexus.pblr-nyk.pro/repository/npm/ CMD ["nodejs", "tradebot.js"] \ No newline at end of file diff --git a/backend_integration.js b/backend_integration.js index 0ce1b94..de026b2 100644 --- a/backend_integration.js +++ b/backend_integration.js @@ -31,7 +31,7 @@ class BackendIntegration { } vip(steam64, amount, extra, uniq) { - axios.post(`${this.url}/api/external/vip?steam=${steam64}&amount=${amount}&service=steam&extra=${extra}&unique=${uniq}`, {}, {headers:{Cookie:`secretkey=${this.secret_key};`}}).then( + axios.post(`${this.url}/api/external/vip?steam=${steam64}&amount=${Math.round(amount)}&service=steam&extra=${extra}&unique=${uniq}`, {}, {headers:{Cookie:`secretkey=${this.secret_key};`}}).then( response => { if (response.status === 200) { if (response.data === 0) { diff --git a/package.json b/package.json index d98f7e3..14d0d54 100644 --- a/package.json +++ b/package.json @@ -7,5 +7,8 @@ "steam-tradeoffer-manager": "^2.10.6", "steam-user": "^5.0.4", "steamcommunity": "^3.47.1" + }, + "publishConfig": { + "registry": "https://nexus.pblr-nyk.pro/repository/npm/" } }