zero-to-production icon indicating copy to clipboard operation
zero-to-production copied to clipboard

Installing sqlx-cli 0.6.0 needs to set native-tls feature

Open zhifengle opened this issue 3 years ago • 0 comments

According to the document of sqlx-cli

# only for postgres
cargo install sqlx-cli --no-default-features --features native-tls,postgres

https://github.com/LukeMathWalker/zero-to-production/blob/root-chapter-03-part1/scripts/init_db.sh#L13

cargo install --version=0.6.0 sqlx-cli --no-default-features --features postgres would output this error

   |
9  | / compile_error!(
10 | |     "one of the features ['runtime-actix-native-tls', 'runtime-async-std-native-tls', \
11 | |      'runtime-tokio-native-tls', 'runtime-actix-rustls', 'runtime-async-std-rustls', \
12 | |      'runtime-tokio-rustls'] must be enabled"
13 | | );
   | |_^

zhifengle avatar Jul 07 '22 08:07 zhifengle