diff --git a/app/app.go b/app/app.go index d0426689..5abe9610 100644 --- a/app/app.go +++ b/app/app.go @@ -7,6 +7,7 @@ import ( "math/big" "os" "path/filepath" + "strconv" "github.com/spf13/cast" @@ -589,6 +590,12 @@ func NewApp( panic(err) } + if maxSize := os.Getenv("MAX_WASM_SIZE"); maxSize != "" { + // https://github.com/CosmWasm/wasmd#compile-time-parameters + val, _ := strconv.ParseInt(maxSize, 10, 32) + wasmtypes.MaxWasmSize = int(val) // default 819200 (800 * 1024) + } + /* =================================================== */ /* TRANSFER STACK */ /* =================================================== */