Specifying a Rust Toolchain


By default, Render uses the latest stable Rust toolchain, but you can specify a different toolchain by adding a file called rust-toolchain at the root of your repo. It should contain a single line specifying the version. For example:

nightly-2020-03-15

or

beta

You can also use the RUSTUP_TOOLCHAIN environment variable and set the value to a valid version. The environment variables overrides the version in toolchain files.

If you override the toolchain in your build command with cargo +nightly... the specified toolchain must already be installed. You can install new toolchains using `rustup` as part of your build command.

Learn more about specifying a Rust toolchain.