Skip to content

Commit

Permalink
add integration setup - TODO: remove p2p keys / don't copy from conta…
Browse files Browse the repository at this point in the history
…iners
  • Loading branch information
darrenvechain committed Dec 21, 2023
1 parent 352fbc6 commit 028a57c
Show file tree
Hide file tree
Showing 13 changed files with 497 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.github
*.md
thorest.png
coverage.out
integration_tests
258 changes: 258 additions & 0 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Build thor in a stock Go builder container
FROM golang:alpine as builder
FROM golang:alpine3.17 as builder

RUN apk add --no-cache make gcc musl-dev linux-headers git
WORKDIR /go/thor
COPY . /go/thor
RUN make all

# Pull thor into a second stage deploy alpine container
FROM alpine:latest
FROM alpine:3.17

RUN apk add --no-cache ca-certificates
COPY --from=builder /go/thor/bin/thor /usr/local/bin/
Expand All @@ -16,4 +16,4 @@ RUN adduser -D -s /bin/ash thor
USER thor

EXPOSE 8669 11235 11235/udp 55555/udp
ENTRYPOINT ["thor"]
ENTRYPOINT ["thor"]
67 changes: 67 additions & 0 deletions integration_tests/config/genesis.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
{
"launchTime": 1703180212,
"gasLimit": 10000000,
"extraData": "My custom VeChain",
"accounts": [
{
"address": "0x7567d83b7b8d80addcb281a71d54fc7b3364ffed",
"balance": 25000000000000000000000000,
"energy": 0,
"code": "0x6060604052600256",
"storage": {
"0x0000000000000000000000000000000000000000000000000000000000000001": "0x0000000000000000000000000000000000000000000000000000000000000002"
}
},
{
"address": "0x435933c8064b4ae76be665428e0307ef2ccfbd68",
"balance": 21046908616500000000000000000,
"energy": 0
},
{
"address": "0xf370940abdbd2583bc80bfc19d19bc216c88ccf0",
"balance": 21046908616500000000000000000,
"energy": 0
},
{
"address": "0x0f872421dc479f3c11edd89512731814d0598db5",
"balance": 21046908616500000000000000000,
"energy": 0
},
{
"address": "0x0bd7b06debd1522e75e4b91ff598f107fd826c8a",
"balance": 21046908616500000000000000000,
"energy": 0
}
],
"authority": [
{
"masterAddress": "0x435933c8064b4ae76be665428e0307ef2ccfbd68",
"endorsorAddress": "0x7567d83b7b8d80addcb281a71d54fc7b3364ffed",
"identity": "0x000000000000000068747470733a2f2f636f6e6e65782e76656368612e696e2f"
},
{
"masterAddress": "0xf370940abdbd2583bc80bfc19d19bc216c88ccf0",
"endorsorAddress": "0x7567d83b7b8d80addcb281a71d54fc7b3364ffed",
"identity": "0x000000000000000068747470733a2f2f656e762e7665636861696e2e6f72672f"
},
{
"masterAddress": "0x0f872421dc479f3c11edd89512731814d0598db5",
"endorsorAddress": "0x7567d83b7b8d80addcb281a71d54fc7b3364ffed",
"identity": "0x0000000000000068747470733a2f2f617070732e7665636861696e2e6f72672f"
}
],
"params": {
"rewardRatio": 300000000000000000,
"baseGasPrice": 1000000000000000,
"proposerEndorsement": 25000000000000000000000000,
"executorAddress": "0x0000000000000000000000004578656375746f72"
},
"executor": {
"approvers": [
{
"address": "0x199b836d8a57365baccd4f371c1fabb7be77d389",
"identity": "0x00000000000067656e6572616c20707572706f736520626c6f636b636861696e"
}
]
}
}
Loading

0 comments on commit 028a57c

Please sign in to comment.