v0.9.0
shuttle: v0.9.0 update
We're excited to release shuttle v0.9.0! 🚀
Here are the highlights in this update.
Poise support
Shuttle now has a Poise integration for building command-based discord bots with ease. Check out the new example here. Thanks to @Anafabula for their first contribution to shuttle!
Binary distributions
Shuttle will now include pre-built binaries for cargo-shuttle
with every release, meaning rather than installing the CLI with cargo install cargo-shuttle
you can now simply download the binary for your OS, put it in your .cargo/bin
folder and you’re good to go!
If you’d prefer a simple tool for this, you can also install the binary using [cargo-binstall](https://github.com/cargo-bins/cargo-binstall).
Note: The current binary paths are incompatible with cargo-binstall
(this will be fixed for the next release), so to install with it you need to add some additional flags: cargo binstall cargo-shuttle --pkg-url="https://github.com/shuttle-hq/shuttle/releases/download/v0.9.0/cargo-shuttle-v0.9.0-8-gf75c2e9-<target>.tar.gz" --bin-dir="shuttle/cargo-shuttle" --pkg-fmt="tgz"
. Remember to add .exe
to the end of bin-dir
if you're using the windows binary.
The following targets will be supported as of 0.9
:
- x86_64-unknown-linux-musl
- aarch64-unknown-linux-musl
- x86_64-pc-windows-msvc
- x86_64-apple-darwin
Expose your shuttle app to your local network
You can now pass the --external
flag to cargo shuttle run
, this will run your app on 0.0.0.0:8000
, exposing your app to your local network. If you’re serving a static website from your app, this makes it easy to open it up on your phone to see that the styling is correct across devices. Thanks to @joshua-mo-143 for this cool new feature!
Override local run database URIs
You can now pass in a local URI as an argument to the shuttle DB resources, allowing you to opt out of the default spawning of a docker container for your local DB. When you set the local_uri
, you can also insert secrets from Secrets.toml
using string interpolation: #596, #597
#[shuttle_service::main]
async fn axum(
#[shuttle_shared_db::Postgres(
local_uri = "postgres://postgres:{secrets.PASSWORD}@localhost:5432/postgres"
)] pool: PgPool) -> ShuttleAxum { ... }
And more
- Added a
cargo shuttle feedback
command that opens a browser on the create new issue page of the shuttle repo, thanks @gautamprikshit1: #592
Bug fixes
- Fixed a bug where using crates with a
rust-toolchain
override, likedashmap
, would lead to errors in deployment: #545 - Fixed a bug where deployer was persisting incorrect historical states, so when doing
cargo shuttle deployment list
users would see deployments that appeared to be stuck in theloading
orbuilding
state: #548
How to upgrade
If you had a project on shuttle, then you will need to manually update the version to 0.9.0
in your Cargo.toml
. You may also need to update the versions of your shuttle resources to 0.9.0
.
To upgrade your project container:
# this will not delete any databases, and you will keep your project name
cargo shuttle project rm # to remove your project
cargo shuttle project new # to recreate your project
cargo shuttle deploy # redeploy your service
To upgrade your shuttle CLI, simply run cargo install cargo-shuttle
or install from the binary releases, see instructions near the top of this release.
New Contributors
- @joshua-mo-143 made their first contribution in #555
- @emmakuen made their first contribution in #553
- @alekspickle made their first contribution in #556
- @Anafabula made their first contribution in #560
- @gautamprikshit1 made their first contribution in #570
Pull requests for this release
- test: fixes by @chesedo in #554
- Refactor: remove deprecated auth command by @oddgrd in #550
- ci: add Makefile command for Windows to convert .sh files to LF format by @joshua-mo-143 in #555
- Fix: dependencies compiled with incompatible versions of rustc by @oddgrd in #545
- feat: create subcommand to list all projects of calling account by @emmakuen in #553
- bug: deployer drifting state by @chesedo in #548
- ci: fix bin builds by @oddgrd in #546
- docs: update contributing by @alekspickle in #556
- feat: Support Poise by @Anafabula in #560
- feat: add flag for router IP local run by @joshua-mo-143 in #565
- bug: no networks by @chesedo in #541
- feat: local uri by @chesedo in #596
- feat: allow string interpolation on resource options by @chesedo in #597
- Upgraded to clap v4 by @gautamprikshit1 in #570
- feat: build prod images in release profile by @oddgrd in #590
- added feedback by @gautamprikshit1 in #592
- refactor: hide some pg catalogs by @chesedo in #593
- chore: update examples submodule by @oddgrd in #601
- chore: v0.9.0 by @oddgrd in #600
Full Changelog: v0.8.1...v0.9.0