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

feat(devnet): add substrate docker images to dockerfile #2263

Merged
merged 38 commits into from
Mar 8, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
6139712
feat: include substrate docker image
EclesioMeloJunior Jan 31, 2022
8c3fb1d
chore: add substrate docker images
EclesioMeloJunior Feb 2, 2022
c0be6dc
chore: formatting and add depends on yaml key
EclesioMeloJunior Feb 2, 2022
eda4e4a
chore: add datadog stuff again
EclesioMeloJunior Feb 2, 2022
dae59e2
chore: use alice peer id
EclesioMeloJunior Feb 2, 2022
6ccf8fb
chore: split substrate docker compose services into another file
EclesioMeloJunior Feb 2, 2022
1407b3a
chore: enable prometheus external and add datadog
EclesioMeloJunior Feb 2, 2022
0d59fac
Merge branch 'development' into eclesio/substrate-docker-image
EclesioMeloJunior Feb 4, 2022
5108412
chore: keep substrate ports same as gossamer node ports
EclesioMeloJunior Feb 4, 2022
9fa7ffb
chore: expose rpc and ws calls in substrate docker file
EclesioMeloJunior Feb 4, 2022
71a8f5e
chore: use same dns name and p2p id
EclesioMeloJunior Feb 4, 2022
f1fea2d
chore: use same key for both alice gossamer and substrate nodes
EclesioMeloJunior Feb 4, 2022
9b485f6
chore: fix dd golang cmd
EclesioMeloJunior Feb 4, 2022
cff9c8c
Update devnet/README.md
EclesioMeloJunior Feb 7, 2022
262b329
Update devnet/README.md
EclesioMeloJunior Feb 7, 2022
012b4b9
chore: update `substrate_alice` readme info
EclesioMeloJunior Feb 7, 2022
1d158a3
Update devnet/README.md
EclesioMeloJunior Feb 7, 2022
f0689ee
chore: add `/tcp` to expose ports
EclesioMeloJunior Feb 7, 2022
604ce4b
Merge branch 'eclesio/substrate-docker-image' of github.com:ChainSafe…
EclesioMeloJunior Feb 7, 2022
237647a
chore: adjust args and envs
EclesioMeloJunior Feb 7, 2022
ae0429e
chore: pin prometheus version, add read only volume and add trailing …
EclesioMeloJunior Feb 7, 2022
843d361
chore: improve README.md
EclesioMeloJunior Feb 7, 2022
bcb134e
Merge branch 'development' into eclesio/substrate-docker-image
EclesioMeloJunior Feb 7, 2022
579136c
chore: add port 7001 explicitly
EclesioMeloJunior Feb 7, 2022
c49bcf0
chore: remove prometheus `--config.file` flag
EclesioMeloJunior Feb 8, 2022
f03093a
chore: use env to chain
EclesioMeloJunior Feb 8, 2022
25946ca
update substrate_bob.Dockerfile
EclesioMeloJunior Feb 8, 2022
e8c1e9d
Merge branch 'development' into eclesio/substrate-docker-image
EclesioMeloJunior Feb 9, 2022
15f1377
chore: add datadog-agent start to gssmr alice node
EclesioMeloJunior Feb 9, 2022
94c6a87
Merge branch 'eclesio/substrate-docker-image' of github.com:ChainSafe…
EclesioMeloJunior Feb 9, 2022
17fd1f2
chore: add comment about different but same node keys
EclesioMeloJunior Feb 16, 2022
aacb438
chore: update substrate docker images to version 0.9.17
EclesioMeloJunior Mar 2, 2022
a382561
chore: include license header
EclesioMeloJunior Mar 2, 2022
ca63faa
Merge branch 'development' into eclesio/substrate-docker-image
EclesioMeloJunior Mar 3, 2022
a4bd83c
chore: make image smaller, start dd agent at entrypoint
EclesioMeloJunior Mar 3, 2022
e476e23
chore: use only one genesis
EclesioMeloJunior Mar 3, 2022
e12686d
chore: be more descriptive at genesis.json folder
EclesioMeloJunior Mar 4, 2022
03c89c6
chore: update image to use arg polkadot version
EclesioMeloJunior Mar 4, 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
5 changes: 4 additions & 1 deletion devnet/alice.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@

FROM golang:1.17

ARG CHAIN=cross-client
ARG POLKADOT_VERSION=v0.9.10

# Using a genesis file with 3 authority nodes (alice, bob, charlie) generated using polkadot $POLKADOT_VERSION
ARG CHAIN=3-auth-node-${POLKADOT_VERSION}
ARG DD_API_KEY=somekey

ENV DD_API_KEY=${DD_API_KEY}
Expand Down
6 changes: 5 additions & 1 deletion devnet/bob.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
# Copyright 2021 ChainSafe Systems (ON)
# SPDX-License-Identifier: LGPL-3.0-only


FROM golang:1.17

ARG CHAIN=cross-client
ARG POLKADOT_VERSION=v0.9.10

# Using a genesis file with 3 authority nodes (alice, bob, charlie) generated using polkadot $POLKADOT_VERSION
ARG CHAIN=3-auth-node-${POLKADOT_VERSION}
ARG DD_API_KEY=somekey

ENV DD_API_KEY=${DD_API_KEY}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,4 +154,4 @@
"childrenDefault": {}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -194,4 +194,4 @@
}
}
}
}
}
10 changes: 8 additions & 2 deletions devnet/substrate_alice.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Copyright 2022 ChainSafe Systems (ON)
# SPDX-License-Identifier: LGPL-3.0-only

ARG POLKADOT_VERSION=v0.9.10

FROM golang:1.17 as openmetrics
ARG METRICS_NAMESPACE=substrate.local.devnet

Expand All @@ -12,15 +14,19 @@ RUN go mod download
COPY ./devnet .
RUN go run cmd/update-dd-agent-confd/main.go -n=${METRICS_NAMESPACE} -t=key:alice > conf.yaml

FROM parity/polkadot:v0.9.17
FROM parity/polkadot:${POLKADOT_VERSION}

ARG CHAIN=cross-client
ARG POLKADOT_VERSION
# Using a genesis file with 3 authority nodes (alice, bob, charlie) generated using polkadot $POLKADOT_VERSION
ARG CHAIN=3-auth-node-${POLKADOT_VERSION}
ARG DD_API_KEY=somekey

ENV DD_API_KEY=${DD_API_KEY}
ENV CHAIN=${CHAIN}

USER root
RUN gpg --recv-keys --keyserver hkps://keys.mailvelope.com 9D4B2B6EB8F97156D19669A9FF0812D491B96798
RUN gpg --export 9D4B2B6EB8F97156D19669A9FF0812D491B96798 > /usr/share/keyrings/parity.gpg
RUN apt update && apt install -y curl && rm -r /var/cache/* /var/lib/apt/lists/*

WORKDIR /cross-client
Expand Down
13 changes: 9 additions & 4 deletions devnet/substrate_bob.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Copyright 2022 ChainSafe Systems (ON)
# SPDX-License-Identifier: LGPL-3.0-only

ARG POLKADOT_VERSION=v0.9.10
FROM golang:1.17 as openmetrics

ARG METRICS_NAMESPACE=substrate.local.devnet
Expand All @@ -13,17 +13,22 @@ RUN go mod download
COPY ./devnet .
RUN go run cmd/update-dd-agent-confd/main.go -n=${METRICS_NAMESPACE} -t=key:alice > conf.yaml

FROM parity/polkadot:v0.9.17
FROM parity/polkadot:${POLKADOT_VERSION}

ARG key
ARG CHAIN=cross-client
ARG POLKADOT_VERSION
# Using a genesis file with 3 authority nodes (alice, bob, charlie) generated using polkadot $POLKADOT_VERSION
ARG CHAIN=3-auth-node-${POLKADOT_VERSION}
ARG DD_API_KEY=somekey
ARG key

ENV DD_API_KEY=${DD_API_KEY}
qdm12 marked this conversation as resolved.
Show resolved Hide resolved
ENV CHAIN=${CHAIN}
ENV key=${key}

USER root
RUN gpg --recv-keys --keyserver hkps://keys.mailvelope.com 9D4B2B6EB8F97156D19669A9FF0812D491B96798
RUN gpg --export 9D4B2B6EB8F97156D19669A9FF0812D491B96798 > /usr/share/keyrings/parity.gpg
Comment on lines +29 to +30
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what are these for?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was getting problem in the apt update because no pub keys were provided, so I follow the Polkadot README (link) installation guide that adds these gpg keys


RUN apt update && apt install -y curl && rm -r /var/cache/* /var/lib/apt/lists/*

WORKDIR /cross-client
Expand Down