diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..2885679 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,2 @@ +.git +.github \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..0c707da --- /dev/null +++ b/Dockerfile @@ -0,0 +1,8 @@ +FROM node:latest +RUN mkdir -p /usr/src/app +WORKDIR /usr/src/app +COPY package*.json /usr/src/app/ +RUN npm install +COPY . /usr/src/app +EXPOSE 3000 +CMD [ "node", "app.js" ] \ No newline at end of file diff --git a/app.js b/app.js index 2179230..3237456 100644 --- a/app.js +++ b/app.js @@ -36,6 +36,12 @@ const defaultTokens = 50; const nameOfYourToken = 'Tonken'; const tokenSymbol = 'TKN'; +/* Decimal Value of Token */ +/* Default any until proper logic is added. To be fair to HTML5 and older browsers */ +/* Other options could be .01, .001, .00000001 etc */ + +const tokenDecimal = 'any'; + /* Is your website open for public subscribers? */ /* true = Yes */ /* false = No, only admin can create accounts @@ -206,6 +212,7 @@ app amountError: '', tokenName: nameOfYourToken, tokenSymbol, + tokenDecimal, colorTheme }); } else { diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..f75f2f6 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,18 @@ +version: "2" +services: + Tonken: + container_name: Tonken + restart: always + build: . + ports: + - "3000:3000" + links: + - mongo + mongo: + container_name: mongo + restart: always + image: mongo + volumes: + - ./data:/data/db + ports: + - "27017:27017" \ No newline at end of file diff --git a/views/send.ejs b/views/send.ejs index c416039..5141ea8 100644 --- a/views/send.ejs +++ b/views/send.ejs @@ -47,6 +47,7 @@ type="number" name="amount" id="" + step="<%= tokenDecimal %>" placeholder="100" class="bg-white shadow-lg w-64 border rounded text-center mt-2 mb-2 h-10 " />