Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[INF-76] New Local Deployment Setup with docker-compose #2988

Merged
merged 81 commits into from
Jul 14, 2022
Merged
Show file tree
Hide file tree
Changes from 71 commits
Commits
Show all changes
81 commits
Select commit Hold shift + click to select a range
2cbd49b
Deploy contracts via docker
cheran-senthil Apr 28, 2022
a814506
Add identity
cheran-senthil May 5, 2022
543e5c7
Merge branch 'master' into vss-new-local-deploy
cheran-senthil May 9, 2022
167f2ca
Reduce solana-programs build size
cheran-senthil May 9, 2022
9cadb12
Fix user replica set migration for audius dev
cheran-senthil May 9, 2022
87e822f
Speedup identity build
cheran-senthil May 9, 2022
4c05fc8
Add docker-compose
cheran-senthil May 9, 2022
44cb721
Merge branch 'master' into vss-new-local-deploy
cheran-senthil May 10, 2022
25f97d0
Add blockscout for POA
cheran-senthil May 11, 2022
e227252
Create Dockerfile.dev for predeployed ganache
cheran-senthil May 11, 2022
c9ea09e
Similar predeployed ganache for eth contracts
cheran-senthil May 11, 2022
bd15f75
Use predeployed docker images
cheran-senthil May 11, 2022
d9363b9
Merge branch 'master' into vss-new-local-deploy
cheran-senthil May 11, 2022
d624320
Fix incorrect addresses
cheran-senthil May 11, 2022
d6e49e1
Add exec permissions
cheran-senthil May 11, 2022
32757e1
Remove unneeded patch fix
cheran-senthil May 11, 2022
ec842f0
Remove potential M1 support
cheran-senthil May 11, 2022
0d9589c
Pin blockscout version
cheran-senthil May 11, 2022
76283b6
Pin anchor-cli version
cheran-senthil May 11, 2022
5f9671d
Add service type and set their versions
cheran-senthil May 12, 2022
a4a9dc0
Update eth-contracts ABI in identity
cheran-senthil May 12, 2022
2bafd50
Merge branch 'master' into vss-new-local-deploy
cheran-senthil May 12, 2022
a5bb23a
Merge branch 'master' into vss-new-local-deploy
cheran-senthil May 17, 2022
d69e3c0
Change write target
cheran-senthil May 19, 2022
a7496a2
Use predeployed solana image
cheran-senthil May 20, 2022
6a07293
Merge branch 'master' into vss-new-local-deploy
cheran-senthil May 20, 2022
11a790b
Install ganache as dev dependency
cheran-senthil May 26, 2022
18301e3
Similar change for poa contracts
cheran-senthil May 26, 2022
e76048b
Merge branch 'master' into vss-new-local-deploy
cheran-senthil May 26, 2022
ae9c39e
Add exec permissions
cheran-senthil May 26, 2022
2347dcf
Support creator node and discovery provider
cheran-senthil May 31, 2022
76b696e
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jun 1, 2022
607dd77
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jun 1, 2022
d5977eb
Bug fixes and register creator-node
cheran-senthil Jun 6, 2022
24c7cd2
Reload on changes
cheran-senthil Jun 8, 2022
0bc8ce6
Add exec and logs
cheran-senthil Jun 10, 2022
bf57fa5
Change to python3
cheran-senthil Jun 10, 2022
9a0c08d
Bugfix
cheran-senthil Jun 10, 2022
156024c
Add setup and some fixes
cheran-senthil Jun 17, 2022
eb8da3a
Make libs similar to old setup
cheran-senthil Jun 17, 2022
fb5506c
Add exec permissions
cheran-senthil Jun 17, 2022
3cdecb2
Add requirements.txt
cheran-senthil Jun 17, 2022
b7a8b55
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jun 17, 2022
668a650
Collect into function
cheran-senthil Jun 17, 2022
b9d6954
Fix formatting from #3217 and #3218
cheran-senthil Jun 17, 2022
027c7b9
Fix linting
cheran-senthil Jun 17, 2022
fb73af3
Better formatting
cheran-senthil Jun 17, 2022
ce8d9eb
Some improvements
cheran-senthil Jun 17, 2022
2be9022
Bootstrap creator-node in URSM
cheran-senthil Jun 22, 2022
78c1e86
Update requirements.txt
cheran-senthil Jun 22, 2022
1db8ac1
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jun 27, 2022
d735571
Make solana compatible with service commands
cheran-senthil Jun 28, 2022
2741ef4
Move health check to individual Dockerfiles
cheran-senthil Jun 29, 2022
ac0b759
Mount idl in discovery-provider
cheran-senthil Jul 1, 2022
4cdfafc
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jul 1, 2022
d63ebad
Make compatible with Ubuntu 20.04 LTS
cheran-senthil Jul 1, 2022
b8f3a6c
Add proxy
cheran-senthil Jul 5, 2022
12227a4
Wrap in loop
cheran-senthil Jul 6, 2022
bcea737
Expose Port
cheran-senthil Jul 6, 2022
d67edff
Fix mount path
cheran-senthil Jul 6, 2022
b3b8ad0
Add ps command
cheran-senthil Jul 7, 2022
0277c42
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jul 7, 2022
03d470a
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jul 9, 2022
ba5f72f
Add dockerignore for libs
cheran-senthil Jul 9, 2022
e27fac4
Don't watch files in libs
cheran-senthil Jul 10, 2022
2f5c6f4
Add sleep
cheran-senthil Jul 11, 2022
0d273e2
Move sleep to after migrations
cheran-senthil Jul 11, 2022
1010880
Move log rotation to docker compose file
cheran-senthil Jul 12, 2022
861e7e0
Adjust postgres instead of sleep
cheran-senthil Jul 12, 2022
e91fcc1
Add quotes
cheran-senthil Jul 12, 2022
f7e5d2d
Some more fixes
cheran-senthil Jul 12, 2022
da4842c
Fix typo (#3427)
raymondjacobson Jul 12, 2022
d8c2d08
Add comments
cheran-senthil Jul 12, 2022
b4d79d0
Add exec permissions globally
cheran-senthil Jul 12, 2022
fd9fabe
Rename dev to dev-tools
cheran-senthil Jul 12, 2022
3d97361
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jul 12, 2022
b4228c1
Revert changes to build
cheran-senthil Jul 12, 2022
c5c9d26
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jul 12, 2022
5c23246
Merge branch 'master' into vss-new-local-deploy
cheran-senthil Jul 13, 2022
46781f0
Fix broken config
cheran-senthil Jul 14, 2022
0d729c7
Update resource class
cheran-senthil Jul 14, 2022
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
21 changes: 21 additions & 0 deletions contracts/Dockerfile.dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
FROM node:16 as builder
COPY package*.json ./
RUN npm install --loglevel verbose

FROM node:16-slim

WORKDIR /usr/src/app

COPY --from=builder /node_modules ./node_modules
COPY . .

ARG bootstrapSPIds
ARG bootstrapSPDelegateWallets
ARG bootstrapSPOwnerWallets

RUN ./scripts/setup-predeployed-ganache.sh /usr/db

HEALTHCHECK --interval=5s --timeout=5s --retries=10 \
CMD node -e "require('http').request('http://localhost:8545').end()" || exit 1

CMD ["npx", "ganache", "--server.host", "0.0.0.0", "--database.dbPath", "/usr/db", "--wallet.deterministic", "--wallet.totalAccounts", "50"]
10 changes: 9 additions & 1 deletion contracts/contract-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,14 @@ module.exports = {
userReplicaSetBootstrapAddress: null,
registryAddress: '0xCfEB869F69431e42cdB54A4F4f105C19C080A601'
},
predeploy: {
verifierAddress: '0xbbbb93A6B3A1D6fDd27909729b95CCB0cc9002C0',
blacklisterAddress: null,
bootstrapSPIds: process.env.bootstrapSPIds ? process.env.bootstrapSPIds.split(",") : [],
bootstrapSPDelegateWallets: process.env.bootstrapSPDelegateWallets ? process.env.bootstrapSPDelegateWallets.split(",") : [],
bootstrapSPOwnerWallets: process.env.bootstrapSPOwnerWallets ? process.env.bootstrapSPOwnerWallets.split(",") : [],
userReplicaSetBootstrapAddress: null
cheran-senthil marked this conversation as resolved.
Show resolved Hide resolved
},
test_local: {
verifierAddress: null,
blacklisterAddress: null,
Expand Down Expand Up @@ -101,4 +109,4 @@ module.exports = {
userReplicaSetBootstrapAddress: '0x3d2563ACCD9E6D189bA2a61F116905D520054286',
registryAddress: '0x793373aBF96583d5eb71a15d86fFE732CD04D452'
}
}
}
cheran-senthil marked this conversation as resolved.
Show resolved Hide resolved
4 changes: 2 additions & 2 deletions contracts/migrations/4_user_replica_set_migration.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ module.exports = (deployer, network, accounts) => {
const config = contractConfig[network]
let registry
let registryAddress
if (network === 'test_local' || network === 'development') {
if (network === 'test_local' || network === 'development' || network === 'predeploy') {
registryAddress = process.env.dataContractsRegistryAddress
registry = await Registry.at(registryAddress)
} else {
Expand All @@ -43,7 +43,7 @@ module.exports = (deployer, network, accounts) => {
const bootstrapSPOwnerWallets = config.bootstrapSPOwnerWallets
const invalidBootstrapConfiguration = (bootstrapSPIds.length === 0 || bootstrapNodeDelegateWallets.length === 0 || bootstrapSPOwnerWallets.length === 0)
if (
(network !== 'test_local' && network !== 'development') &&
(network !== 'test_local' && network !== 'development' && network !== 'predeploy') &&
(invalidBootstrapConfiguration)
) {
throw new Error(
Expand Down
Loading