Skip to content
This repository was archived by the owner on Aug 9, 2023. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.git
.github
8 changes: 8 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -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" ]
7 changes: 7 additions & 0 deletions app.js
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -206,6 +212,7 @@ app
amountError: '',
tokenName: nameOfYourToken,
tokenSymbol,
tokenDecimal,
colorTheme
});
} else {
Expand Down
18 changes: 18 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -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"
1 change: 1 addition & 0 deletions views/send.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -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 "
/>
Expand Down