Skip to content

Commit

Permalink
terra/devnet: update to bombay network
Browse files Browse the repository at this point in the history
Change-Id: I2169adc1b0df9103b10dc50ba6e7470e38ad8fe9
  • Loading branch information
Reisen committed Oct 4, 2021
1 parent d2c976b commit 2163f42
Show file tree
Hide file tree
Showing 10 changed files with 877 additions and 609 deletions.
10 changes: 4 additions & 6 deletions Tiltfile
Original file line number Diff line number Diff line change
Expand Up @@ -333,14 +333,12 @@ docker_build(

k8s_yaml_with_ns("devnet/terra-devnet.yaml")

k8s_resource(
"terra-lcd",
port_forwards = [port_forward(1317, name = "Terra LCD interface [:1317]")],
)

k8s_resource(
"terra-terrad",
port_forwards = [port_forward(26657, name = "Terra RPC [:26657]")],
port_forwards = [
port_forward(26657, name = "Terra RPC [:26657]"),
port_forward(1317, name = "Terra LCD [:1317]"),
],
)

k8s_resource(
Expand Down
65 changes: 10 additions & 55 deletions devnet/terra-devnet.yaml
Original file line number Diff line number Diff line change
@@ -1,18 +1,3 @@
---
apiVersion: v1
kind: Service
metadata:
labels:
app: terra-lcd
name: terra-lcd
spec:
ports:
- name: lcd
port: 1317
protocol: TCP
selector:
app: terra-lcd
---
apiVersion: v1
kind: Service
metadata:
Expand All @@ -24,6 +9,9 @@ spec:
- name: rpc
port: 26657
protocol: TCP
- name: rest
port: 1317
protocol: TCP
selector:
app: terra-terrad
---
Expand All @@ -43,40 +31,6 @@ spec:
---
apiVersion: apps/v1
kind: StatefulSet
metadata:
labels:
app: terra-lcd
name: terra-lcd
spec:
replicas: 1
selector:
matchLabels:
app: terra-lcd
template:
metadata:
labels:
app: terra-lcd
spec:
containers:
- args:
- terracli
- rest-server
- --laddr=tcp://0.0.0.0:1317
- --node=tcp://terra-terrad:26657
- --trust-node=true
- --unsafe-cors
image: terra-image
name: terra-lcd
ports:
- containerPort: 1317
readinessProbe:
tcpSocket:
port: 1317
restartPolicy: Always
serviceName: terra-lcd
---
apiVersion: apps/v1
kind: StatefulSet
metadata:
labels:
app: terra-terrad
Expand All @@ -99,6 +53,7 @@ spec:
name: terra-terrad
ports:
- containerPort: 26657
- containerPort: 1317
readinessProbe:
httpGet:
port: 26657
Expand Down Expand Up @@ -137,7 +92,7 @@ spec:
value: dev
- name: POSTGRES_DB
value: fcd
- image: terramoney/fcd:0.10.8
- image: terramoney/fcd:bombay
name: fcd-collector
args:
- collector
Expand All @@ -146,9 +101,9 @@ spec:
- name: CHAIN_ID
value: localterra
- name: LCD_URI
value: http://terra-lcd:1317
value: http://terra-terrad:1317
- name: BYPASS_URI
value: http://terra-lcd:1317
value: http://terra-terrad:1317
- name: RPC_URI
value: http://terra-terrad:26657
- name: TYPEORM_CONNECTION
Expand All @@ -167,7 +122,7 @@ spec:
value: "false"
- name: TYPEORM_ENTITIES
value: "src/orm/*Entity.ts"
- image: terramoney/fcd:0.10.8
- image: terramoney/fcd:bombay
name: fcd-api
args:
- start
Expand All @@ -178,9 +133,9 @@ spec:
- name: CHAIN_ID
value: localterra
- name: LCD_URI
value: http://terra-lcd:1317
value: http://terra-terrad:1317
- name: BYPASS_URI
value: http://terra-lcd:1317
value: http://terra-terrad:1317
- name: RPC_URI
value: http://terra-terrad:26657
- name: TYPEORM_CONNECTION
Expand Down
4 changes: 2 additions & 2 deletions terra/devnet/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
FROM terramoney/localterra-core:0.4.9@sha256:0bf371656e2d8b13c8809835d81fcc7ca2c9fb15bcb715bfd9d5a24d863f7e64
FROM terramoney/localterra-core:bombay@sha256:0f93576ae0716f835b2adbd5ac550ef90063b536e99c4dd682b6dd905927f261

ADD config /root/.terrad/config
ADD config /root/.terra/config
4 changes: 0 additions & 4 deletions terra/devnet/config/addrbook.json

This file was deleted.

174 changes: 172 additions & 2 deletions terra/devnet/config/app.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
# This is a TOML config file.
# For more information, see https://github.com/toml-lang/toml

##### main base config options #####
###############################################################################
### Base Configuration ###
###############################################################################

# The minimum gas prices a validator is willing to accept for processing a
# transaction. A transaction's fees must meet the minimum of any denomination
# specified in this config (e.g. 0.25token1;0.0001token2).
minimum-gas-prices = "0.00506uluna,0.0015uusd,0.00102usdr,1.7805ukrw,4.31626umnt"
minimum-gas-prices = "0.01133uluna,0.15uusd,0.104938usdr,169.77ukrw,428.571umnt,0.125ueur,0.98ucny,16.37ujpy,0.11ugbp,10.88uinr,0.19ucad,0.14uchf,0.19uaud,0.2usgd,4.62uthb,1.25usek"

# default: the last 100 states are kept in addition to every 500th state; pruning at 10 block intervals
# nothing: all historic states will be saved, nothing will be deleted (i.e. archiving node)
Expand All @@ -32,5 +34,173 @@ halt-height = 0
# Note: Commitment of state will be attempted on the corresponding block.
halt-time = 0

# MinRetainBlocks defines the minimum block height offset from the current
# block being committed, such that all blocks past this offset are pruned
# from Tendermint. It is used as part of the process of determining the
# ResponseCommit.RetainHeight value during ABCI Commit. A value of 0 indicates
# that no blocks should be pruned.
#
# This configuration value is only responsible for pruning Tendermint blocks.
# It has no bearing on application state pruning which is determined by the
# "pruning-*" configurations.
#
# Note: Tendermint block pruning is dependant on this parameter in conjunction
# with the unbonding (safety threshold) period, state pruning and state sync
# snapshot parameters to determine the correct minimum value of
# ResponseCommit.RetainHeight.
min-retain-blocks = 0

# InterBlockCache enables inter-block caching.
inter-block-cache = true

# IndexEvents defines the set of events in the form {eventType}.{attributeKey},
# which informs Tendermint what to index. If empty, all events will be indexed.
#
# Example:
# ["message.sender", "message.recipient"]
index-events = []

###############################################################################
### Telemetry Configuration ###
###############################################################################

[telemetry]

# Prefixed with keys to separate services.
service-name = ""

# Enabled enables the application telemetry functionality. When enabled,
# an in-memory sink is also enabled by default. Operators may also enabled
# other sinks such as Prometheus.
enabled = false

# Enable prefixing gauge values with hostname.
enable-hostname = false

# Enable adding hostname to labels.
enable-hostname-label = false

# Enable adding service to labels.
enable-service-label = false

# PrometheusRetentionTime, when positive, enables a Prometheus metrics sink.
prometheus-retention-time = 0

# GlobalLabels defines a global set of name/value label tuples applied to all
# metrics emitted using the wrapper functions defined in telemetry package.
#
# Example:
# [["chain_id", "cosmoshub-1"]]
global-labels = [
]

###############################################################################
### API Configuration ###
###############################################################################

[api]

# Enable defines if the API server should be enabled.
enable = true

# Swagger defines if swagger documentation should automatically be registered.
swagger = true

# Address defines the API server to listen on.
address = "tcp://0.0.0.0:1317"

# MaxOpenConnections defines the number of maximum open connections.
max-open-connections = 1000

# RPCReadTimeout defines the Tendermint RPC read timeout (in seconds).
rpc-read-timeout = 10

# RPCWriteTimeout defines the Tendermint RPC write timeout (in seconds).
rpc-write-timeout = 30

# RPCMaxBodyBytes defines the Tendermint maximum response body (in bytes).
rpc-max-body-bytes = 1000000

# EnableUnsafeCORS defines if CORS should be enabled (unsafe - use it at your own risk).
enabled-unsafe-cors = true

###############################################################################
### Rosetta Configuration ###
###############################################################################

[rosetta]

# Enable defines if the Rosetta API server should be enabled.
enable = false

# Address defines the Rosetta API server to listen on.
address = ":8080"

# Network defines the name of the blockchain that will be returned by Rosetta.
blockchain = "app"

# Network defines the name of the network that will be returned by Rosetta.
network = "network"

# Retries defines the number of retries when connecting to the node before failing.
retries = 3

# Offline defines if Rosetta server should run in offline mode.
offline = false

###############################################################################
### gRPC Configuration ###
###############################################################################

[grpc]

# Enable defines if the gRPC server should be enabled.
enable = true

# Address defines the gRPC server address to bind to.
address = "0.0.0.0:9090"

###############################################################################
### gRPC Web Configuration ###
###############################################################################

[grpc-web]

# GRPCWebEnable defines if the gRPC-web should be enabled.
# NOTE: gRPC must also be enabled, otherwise, this configuration is a no-op.
enable = true

# Address defines the gRPC-web server address to bind to.
address = "0.0.0.0:9091"

# EnableUnsafeCORS defines if CORS should be enabled (unsafe - use it at your own risk).
enable-unsafe-cors = true

###############################################################################
### State Sync Configuration ###
###############################################################################

# State sync snapshots allow other nodes to rapidly join the network without replaying historical
# blocks, instead downloading and applying a snapshot of the application state at a given height.
[state-sync]

# snapshot-interval specifies the block interval at which local state sync snapshots are
# taken (0 to disable). Must be a multiple of pruning-keep-every.
snapshot-interval = 0

# snapshot-keep-recent specifies the number of recent snapshots to keep and serve (0 to keep all).
snapshot-keep-recent = 2

[wasm]
# The maximum gas amount can be spent for contract query.
# The contract query will invoke contract execution vm,
# so we need to restrict the max usage to prevent DoS attack
contract-query-gas-limit = "3000000"

# The flag to specify whether print contract logs or not
contract-debug-mode = "false"

# The WASM VM memory cache size in MiB not bytes
contract-memory-cache-size = "500"

contract-logging-whitelist = "*"
Loading

0 comments on commit 2163f42

Please sign in to comment.