From 2ae69c0775db2d3668b158d303df9ac4ecd61584 Mon Sep 17 00:00:00 2001 From: itowlson Date: Tue, 17 Oct 2023 13:55:45 +1300 Subject: [PATCH 1/3] Manifest v2 support Signed-off-by: itowlson --- Cargo.lock | 1018 ++++++++++++++++------------------------ Cargo.toml | 18 +- src/commands/deploy.rs | 55 +-- 3 files changed, 433 insertions(+), 658 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 4b93782..591dd14 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -30,21 +30,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ac1f845298e95f983ff1944b728ae08b8cebab80d684f0a832ed0fc74dfa27e2" dependencies = [ "cfg-if", - "cipher 0.4.4", + "cipher", "cpufeatures", ] -[[package]] -name = "ahash" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" -dependencies = [ - "getrandom 0.2.10", - "once_cell", - "version_check", -] - [[package]] name = "ahash" version = "0.8.3" @@ -130,19 +119,6 @@ dependencies = [ "futures-core", ] -[[package]] -name = "async-compression" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "942c7cd7ae39e91bde4820d74132e9862e62c2f386c3aa90ccf55949f5bad63a" -dependencies = [ - "flate2", - "futures-core", - "memchr", - "pin-project-lite", - "tokio", -] - [[package]] name = "async-compression" version = "0.4.4" @@ -391,7 +367,7 @@ dependencies = [ "log", "serde", "serde_json", - "sha2 0.10.8", + "sha2", "thiserror", "time", "url", @@ -440,17 +416,6 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" -[[package]] -name = "bcrypt" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f691e63585950d8c1c43644d11bab9073e40f5060dd2822734ae7c3dc69a3a80" -dependencies = [ - "base64 0.13.1", - "blowfish", - "getrandom 0.2.10", -] - [[package]] name = "bincode" version = "1.3.3" @@ -480,48 +445,6 @@ dependencies = [ "syn 2.0.38", ] -[[package]] -name = "bindle" -version = "0.8.0" -source = "git+https://github.com/fermyon/bindle?tag=v0.8.2#84ea1dd86fab6ffe27235e268f47f632421db8f9" -dependencies = [ - "anyhow", - "async-compression 0.3.15", - "async-trait", - "base64 0.13.1", - "bcrypt", - "bytes", - "dirs 4.0.0", - "ed25519-dalek", - "either", - "futures", - "hyper", - "jsonwebtoken", - "lru 0.7.8", - "mime", - "mime_guess", - "oauth2", - "rand 0.7.3", - "reqwest", - "semver", - "serde", - "serde_cbor", - "serde_json", - "sha2 0.10.8", - "sled", - "tempfile", - "thiserror", - "time", - "tokio", - "tokio-stream", - "tokio-tar", - "tokio-util 0.6.10", - "toml", - "tracing", - "tracing-futures", - "url", -] - [[package]] name = "bitflags" version = "1.3.2" @@ -546,15 +469,6 @@ dependencies = [ "wyz", ] -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array", -] - [[package]] name = "block-buffer" version = "0.10.4" @@ -580,17 +494,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "blowfish" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe3ff3fc1de48c1ac2e3341c4df38b0d1bfb8fdf04632a187c8b75aaa319a7ab" -dependencies = [ - "byteorder", - "cipher 0.3.0", - "opaque-debug", -] - [[package]] name = "bumpalo" version = "3.14.0" @@ -657,7 +560,7 @@ dependencies = [ "reqwest", "serde", "serde_json", - "sha2 0.10.8", + "sha2", "tar", "tempfile", "thiserror", @@ -779,15 +682,6 @@ dependencies = [ "windows-targets 0.48.5", ] -[[package]] -name = "cipher" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" -dependencies = [ - "generic-array", -] - [[package]] name = "cipher" version = "0.4.4" @@ -904,7 +798,7 @@ dependencies = [ "semver", "serde", "serde_json", - "sha2 0.10.8", + "sha2", "spin-app", "spin-common", "spin-http", @@ -1021,18 +915,16 @@ dependencies = [ [[package]] name = "cranelift-bforest" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03b9d1a9e776c27ad55d7792a380785d1fe8c2d7b099eed8dbd8f4af2b598192" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cranelift-entity", ] [[package]] name = "cranelift-codegen" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5528483314c2dd5da438576cd8a9d0b3cedad66fb8a4727f90cd319a81950038" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "bumpalo", "cranelift-bforest", @@ -1051,33 +943,29 @@ dependencies = [ [[package]] name = "cranelift-codegen-meta" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f46a8318163f7682e35b8730ba93c1b586a2da8ce12a0ed545efc1218550f70" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cranelift-codegen-shared", ] [[package]] name = "cranelift-codegen-shared" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37d1239cfd50eecfaed468d46943f8650e32969591868ad50111613704da6c70" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" [[package]] name = "cranelift-control" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcc530560c8f16cc1d4dd7ea000c56f519c60d1a914977abe849ce555c35a61d" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "arbitrary", ] [[package]] name = "cranelift-entity" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f333fa641a9ad2bff0b107767dcb972c18c2bfab7969805a1d7e42449ccb0408" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "serde", "serde_derive", @@ -1085,9 +973,8 @@ dependencies = [ [[package]] name = "cranelift-frontend" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06abf6563015a80f03f8bc4df307d0a81363f4eb73108df3a34f6e66fb6d5307" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cranelift-codegen", "log", @@ -1097,15 +984,13 @@ dependencies = [ [[package]] name = "cranelift-isle" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0eb29d0edc8a5c029ed0f7ca77501f272738e3c410020b4a00f42ffe8ad2a8aa" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" [[package]] name = "cranelift-native" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "006056a7fa920870bad06bf8e1b3033d70cbb7ee625b035efa9d90882a931868" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cranelift-codegen", "libc", @@ -1114,9 +999,8 @@ dependencies = [ [[package]] name = "cranelift-wasm" -version = "0.100.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b3d08c05f82903a1f6a04d89c4b9ecb47a4035710f89a39a21a147a80214672" +version = "0.101.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cranelift-codegen", "cranelift-entity", @@ -1124,7 +1008,7 @@ dependencies = [ "itertools 0.10.5", "log", "smallvec", - "wasmparser 0.112.0", + "wasmparser 0.113.3", "wasmtime-types", ] @@ -1214,7 +1098,7 @@ dependencies = [ "crossterm_winapi", "libc", "mio", - "parking_lot 0.12.1", + "parking_lot", "signal-hook", "signal-hook-mio", "winapi", @@ -1255,19 +1139,6 @@ dependencies = [ "windows-sys 0.48.0", ] -[[package]] -name = "curve25519-dalek" -version = "3.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90f9d052967f590a76e62eb387bd0bbb1b000182c3cefe5364db6b7211651bc0" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - [[package]] name = "darling" version = "0.14.4" @@ -1437,22 +1308,13 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6184e33543162437515c2e2b48714794e37845ec9851711914eec9d308f6ebe8" -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - [[package]] name = "digest" version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ - "block-buffer 0.10.4", + "block-buffer", "crypto-common", "subtle", ] @@ -1538,7 +1400,7 @@ dependencies = [ "serde", "serde_ignored", "serde_json", - "sha2 0.10.8", + "sha2", "strum 0.23.0", "strum_macros 0.23.1", "tar", @@ -1582,29 +1444,6 @@ version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "23d2f3407d9a573d666de4b5bdf10569d73ca9478087346697dcbae6244bfbcd" -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - [[package]] name = "either" version = "1.9.0" @@ -2035,12 +1874,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "half" -version = "1.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eabb4a44450da02c90444cf74558da904edde8fb4e9035a9a6a4e15445af0bd7" - [[package]] name = "half" version = "2.3.1" @@ -2056,9 +1889,6 @@ name = "hashbrown" version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" -dependencies = [ - "ahash 0.7.6", -] [[package]] name = "hashbrown" @@ -2066,7 +1896,7 @@ version = "0.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" dependencies = [ - "ahash 0.8.3", + "ahash", ] [[package]] @@ -2075,7 +1905,7 @@ version = "0.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7dfda62a12f55daeae5015f81b0baea145391cb4520f86c248fc615d72640d12" dependencies = [ - "ahash 0.8.3", + "ahash", "allocator-api2", ] @@ -2130,7 +1960,7 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "digest 0.10.7", + "digest", ] [[package]] @@ -2176,6 +2006,29 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "http-body" +version = "1.0.0-rc.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "951dfc2e32ac02d67c90c0d65bd27009a635dc9b381a2cc7d284ab01e3a0150d" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.0-rc.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92445bc9cc14bfa0a3ce56817dc3b5bcc227a168781a356b702410789cec0d10" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body 1.0.0-rc.2", + "pin-project-lite", +] + [[package]] name = "http-types" version = "2.12.0" @@ -2220,7 +2073,7 @@ dependencies = [ "futures-util", "h2", "http", - "http-body", + "http-body 0.4.5", "httparse", "httpdate", "itoa", @@ -2232,6 +2085,28 @@ dependencies = [ "want", ] +[[package]] +name = "hyper" +version = "1.0.0-rc.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b75264b2003a3913f118d35c586e535293b3e22e41f074930762929d071e092" +dependencies = [ + "bytes", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body 1.0.0-rc.2", + "httparse", + "httpdate", + "itoa", + "pin-project-lite", + "tokio", + "tracing", + "want", +] + [[package]] name = "hyper-rustls" version = "0.24.1" @@ -2240,7 +2115,7 @@ checksum = "8d78e1e73ec14cf7375674f74d7dde185c8206fd9dea6fb6295e8a98098aaa97" dependencies = [ "futures-util", "http", - "hyper", + "hyper 0.14.27", "rustls 0.21.7", "tokio", "tokio-rustls 0.24.1", @@ -2253,7 +2128,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" dependencies = [ "bytes", - "hyper", + "hyper 0.14.27", "native-tls", "tokio", "tokio-native-tls", @@ -2395,17 +2270,6 @@ version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" -[[package]] -name = "is-terminal" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" -dependencies = [ - "hermit-abi 0.3.3", - "rustix 0.38.19", - "windows-sys 0.48.0", -] - [[package]] name = "itertools" version = "0.8.2" @@ -2486,20 +2350,6 @@ dependencies = [ "wasm-bindgen", ] -[[package]] -name = "jsonwebtoken" -version = "8.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6971da4d9c3aa03c3d8f3ff0f4155b534aad021292003895a469716b2a230378" -dependencies = [ - "base64 0.21.4", - "pem 1.1.1", - "ring 0.16.20", - "serde", - "serde_json", - "simple_asn1", -] - [[package]] name = "jwt" version = "0.16.0" @@ -2508,11 +2358,11 @@ checksum = "6204285f77fe7d9784db3fdc449ecce1a0114927a51d5a41c4c7a292011c015f" dependencies = [ "base64 0.13.1", "crypto-common", - "digest 0.10.7", + "digest", "hmac", "serde", "serde_json", - "sha2 0.10.8", + "sha2", ] [[package]] @@ -2699,7 +2549,12 @@ version = "0.2.0-dev" source = "git+https://github.com/rustformers/llm?rev=2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663#2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663" dependencies = [ "llm-base", + "llm-bloom", + "llm-gpt2", + "llm-gptj", + "llm-gptneox", "llm-llama", + "llm-mpt", "serde", "tracing", ] @@ -2711,7 +2566,7 @@ source = "git+https://github.com/rustformers/llm?rev=2f6ffd4435799ceaa1d1bcb5a87 dependencies = [ "bytemuck", "ggml", - "half 2.3.1", + "half", "llm-samplers", "memmap2", "partial_sort", @@ -2724,6 +2579,39 @@ dependencies = [ "tracing", ] +[[package]] +name = "llm-bloom" +version = "0.2.0-dev" +source = "git+https://github.com/rustformers/llm?rev=2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663#2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663" +dependencies = [ + "llm-base", +] + +[[package]] +name = "llm-gpt2" +version = "0.2.0-dev" +source = "git+https://github.com/rustformers/llm?rev=2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663#2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663" +dependencies = [ + "bytemuck", + "llm-base", +] + +[[package]] +name = "llm-gptj" +version = "0.2.0-dev" +source = "git+https://github.com/rustformers/llm?rev=2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663#2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663" +dependencies = [ + "llm-base", +] + +[[package]] +name = "llm-gptneox" +version = "0.2.0-dev" +source = "git+https://github.com/rustformers/llm?rev=2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663#2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663" +dependencies = [ + "llm-base", +] + [[package]] name = "llm-llama" version = "0.2.0-dev" @@ -2733,6 +2621,14 @@ dependencies = [ "tracing", ] +[[package]] +name = "llm-mpt" +version = "0.2.0-dev" +source = "git+https://github.com/rustformers/llm?rev=2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663#2f6ffd4435799ceaa1d1bcb5a8790e5b3e0c5663" +dependencies = [ + "llm-base", +] + [[package]] name = "llm-samplers" version = "0.0.6" @@ -2764,15 +2660,6 @@ dependencies = [ "value-bag", ] -[[package]] -name = "lru" -version = "0.7.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e999beba7b6e8345721bd280141ed958096a2e4abdf74f67ff4ce49b4b54e47a" -dependencies = [ - "hashbrown 0.12.3", -] - [[package]] name = "lru" version = "0.9.0" @@ -2829,7 +2716,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf" dependencies = [ "cfg-if", - "digest 0.10.7", + "digest", ] [[package]] @@ -2974,7 +2861,7 @@ dependencies = [ "mysql_common", "native-tls", "once_cell", - "pem 2.0.1", + "pem", "percent-encoding", "pin-project", "priority-queue", @@ -3015,7 +2902,7 @@ dependencies = [ "serde", "serde_json", "sha1 0.10.6", - "sha2 0.10.8", + "sha2", "smallvec", "subprocess", "thiserror", @@ -3122,26 +3009,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "830b246a0e5f20af87141b25c173cd1b609bd7779a4617d6ec582abaf90870f3" -[[package]] -name = "oauth2" -version = "4.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c38841cdd844847e3e7c8d29cef9dcfed8877f8f56f9071f77843ecf3baf937f" -dependencies = [ - "base64 0.13.1", - "chrono", - "getrandom 0.2.10", - "http", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_path_to_error", - "sha2 0.10.8", - "thiserror", - "url", -] - [[package]] name = "object" version = "0.32.1" @@ -3171,7 +3038,7 @@ dependencies = [ "reqwest", "serde", "serde_json", - "sha2 0.10.8", + "sha2", "thiserror", "tokio", "tokio-util 0.7.9", @@ -3218,12 +3085,6 @@ dependencies = [ "pkg-config", ] -[[package]] -name = "opaque-debug" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" - [[package]] name = "openssl" version = "0.10.57" @@ -3307,8 +3168,8 @@ dependencies = [ [[package]] name = "outbound-http" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "http", @@ -3316,14 +3177,15 @@ dependencies = [ "spin-app", "spin-core", "spin-world", + "terminal", "tracing", "url", ] [[package]] name = "outbound-mysql" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "flate2", @@ -3338,14 +3200,15 @@ dependencies = [ [[package]] name = "outbound-pg" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "native-tls", "postgres-native-tls", "spin-core", "spin-world", + "table", "tokio", "tokio-postgres", "tracing", @@ -3353,13 +3216,14 @@ dependencies = [ [[package]] name = "outbound-redis" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "redis", "spin-core", "spin-world", + "table", "tokio", "tracing", ] @@ -3370,17 +3234,6 @@ version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e52c774a4c39359c1d1c52e43f73dd91a75a614652c825408eec30c95a9b2067" -[[package]] -name = "parking_lot" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99" -dependencies = [ - "instant", - "lock_api", - "parking_lot_core 0.8.6", -] - [[package]] name = "parking_lot" version = "0.12.1" @@ -3388,21 +3241,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" dependencies = [ "lock_api", - "parking_lot_core 0.9.8", -] - -[[package]] -name = "parking_lot_core" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60a2cfe6f0ad2bfc16aefa463b497d5c7a5ecd44a23efa72aa342d90177356dc" -dependencies = [ - "cfg-if", - "instant", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "winapi", + "parking_lot_core", ] [[package]] @@ -3465,10 +3304,10 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" dependencies = [ - "digest 0.10.7", + "digest", "hmac", "password-hash", - "sha2 0.10.8", + "sha2", ] [[package]] @@ -3477,15 +3316,6 @@ version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099" -[[package]] -name = "pem" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8835c273a76a90455d7344889b0964598e3316e2a79ede8e36f16bdcf2228b8" -dependencies = [ - "base64 0.13.1", -] - [[package]] name = "pem" version = "2.0.1" @@ -3633,7 +3463,7 @@ dependencies = [ "md-5", "memchr", "rand 0.8.5", - "sha2 0.10.8", + "sha2", "stringprep", ] @@ -3975,7 +3805,7 @@ version = "0.11.22" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "046cd98826c46c2ac8ddecae268eb5c2e58628688a5fc7a2643704a73faba95b" dependencies = [ - "async-compression 0.4.4", + "async-compression", "base64 0.21.4", "bytes", "encoding_rs", @@ -3983,8 +3813,8 @@ dependencies = [ "futures-util", "h2", "http", - "http-body", - "hyper", + "http-body 0.4.5", + "hyper 0.14.27", "hyper-rustls", "hyper-tls", "ipnet", @@ -4312,9 +4142,6 @@ name = "semver" version = "1.0.20" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "836fa6a3e1e547f9a2c4040802ec865b5d85f4014efe00555d7090a3dcaa1090" -dependencies = [ - "serde", -] [[package]] name = "serde" @@ -4334,16 +4161,6 @@ dependencies = [ "serde", ] -[[package]] -name = "serde_cbor" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bef2ebfde456fb76bbcf9f59315333decc4fda0b2b44b420243c11e0f5ec1f5" -dependencies = [ - "half 1.8.2", - "serde", -] - [[package]] name = "serde_derive" version = "1.0.189" @@ -4376,24 +4193,23 @@ dependencies = [ ] [[package]] -name = "serde_path_to_error" -version = "0.1.14" +name = "serde_qs" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4beec8bce849d58d06238cb50db2e1c417cfeafa4c63f692b15c82b7c80f8335" +checksum = "c7715380eec75f029a4ef7de39a9200e0a63823176b759d055b613f5a87df6a6" dependencies = [ - "itoa", + "percent-encoding", "serde", + "thiserror", ] [[package]] -name = "serde_qs" -version = "0.8.5" +name = "serde_spanned" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7715380eec75f029a4ef7de39a9200e0a63823176b759d055b613f5a87df6a6" +checksum = "96426c9936fd7a0124915f9185ea1d20aa9445cc9821142f0a73bc9207a2e186" dependencies = [ - "percent-encoding", "serde", - "thiserror", ] [[package]] @@ -4453,7 +4269,7 @@ checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" dependencies = [ "cfg-if", "cpufeatures", - "digest 0.10.7", + "digest", ] [[package]] @@ -4462,19 +4278,6 @@ version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae1a47186c03a32177042e55dbc5fd5aee900b8e0069a8d70fba96a9375cd012" -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - [[package]] name = "sha2" version = "0.10.8" @@ -4483,7 +4286,7 @@ checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" dependencies = [ "cfg-if", "cpufeatures", - "digest 0.10.7", + "digest", ] [[package]] @@ -4546,24 +4349,6 @@ dependencies = [ "libc", ] -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simple_asn1" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adc4e5204eb1910f40f9cfa375f6f05b68c3abac4b6fd879c8ff5e7ae8a0a085" -dependencies = [ - "num-bigint", - "num-traits", - "thiserror", - "time", -] - [[package]] name = "siphasher" version = "0.3.11" @@ -4579,22 +4364,6 @@ dependencies = [ "autocfg", ] -[[package]] -name = "sled" -version = "0.34.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f96b4737c2ce5987354855aed3797279def4ebf734436c6aa4552cf8e169935" -dependencies = [ - "crc32fast", - "crossbeam-epoch", - "crossbeam-utils", - "fs2", - "fxhash", - "libc", - "log", - "parking_lot 0.11.2", -] - [[package]] name = "slice-group-by" version = "0.3.1" @@ -4650,46 +4419,47 @@ checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" [[package]] name = "spin-app" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", - "base64 0.21.4", "ouroboros", "serde", "serde_json", "spin-core", + "spin-serde", "thiserror", ] [[package]] name = "spin-common" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "dirs 4.0.0", - "sha2 0.10.8", + "sha2", + "tempfile", "tokio", ] [[package]] name = "spin-componentize" version = "0.1.0" -source = "git+https://github.com/fermyon/spin-componentize?rev=0fa79bfc60f20c172213e2a2c34bd0b3168960b0#0fa79bfc60f20c172213e2a2c34bd0b3168960b0" +source = "git+https://github.com/fermyon/spin-componentize?rev=0c68c5f2afae65c2011fa23b30fd136682506e2a#0c68c5f2afae65c2011fa23b30fd136682506e2a" dependencies = [ "anyhow", - "wasm-encoder 0.32.0", - "wasmparser 0.112.0", + "wasm-encoder 0.35.0", + "wasmparser 0.115.0", "wit-component", - "wit-parser", + "wit-parser 0.12.0", ] [[package]] name = "spin-config" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", @@ -4706,8 +4476,8 @@ dependencies = [ [[package]] name = "spin-core" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", @@ -4722,33 +4492,37 @@ dependencies = [ "wasi-common", "wasmtime", "wasmtime-wasi", + "wasmtime-wasi-http", ] [[package]] name = "spin-http" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "http", - "hyper", + "http-body-util", + "hyper 1.0.0-rc.3", "indexmap 1.9.3", "percent-encoding", "serde", "spin-app", "tracing", + "wasmtime-wasi-http", ] [[package]] name = "spin-key-value" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "lru 0.9.0", "spin-app", "spin-core", "spin-world", + "table", "tokio", "tracing", ] @@ -4756,7 +4530,7 @@ dependencies = [ [[package]] name = "spin-key-value-azure" version = "0.1.0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "azure_data_cosmos", @@ -4771,7 +4545,7 @@ dependencies = [ [[package]] name = "spin-key-value-redis" version = "0.1.0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "redis", @@ -4785,7 +4559,7 @@ dependencies = [ [[package]] name = "spin-key-value-sqlite" version = "0.1.0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "once_cell", @@ -4798,8 +4572,8 @@ dependencies = [ [[package]] name = "spin-llm" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "bytesize", @@ -4811,8 +4585,8 @@ dependencies = [ [[package]] name = "spin-llm-remote-http" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "http", @@ -4823,16 +4597,16 @@ dependencies = [ "spin-core", "spin-llm", "spin-world", + "tracing", ] [[package]] name = "spin-loader" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", - "bindle", "bytes", "dirs 4.0.0", "dunce", @@ -4848,37 +4622,43 @@ dependencies = [ "semver", "serde", "serde_json", + "sha2", "shellexpand 3.1.0", + "spin-app", "spin-common", "spin-config", "spin-manifest", "tempfile", "terminal", + "thiserror", "tokio", "tokio-util 0.6.10", - "toml", + "toml 0.8.2", "tracing", "walkdir", ] [[package]] name = "spin-manifest" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ + "anyhow", "indexmap 1.9.3", + "outbound-http", "serde", + "spin-serde", "thiserror", - "toml", + "toml 0.8.2", ] [[package]] name = "spin-oci" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", - "async-compression 0.4.4", + "async-compression", "async-tar", "base64 0.21.4", "dirs 4.0.0", @@ -4901,24 +4681,33 @@ dependencies = [ "walkdir", ] +[[package]] +name = "spin-serde" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" +dependencies = [ + "base64 0.21.4", + "serde", +] + [[package]] name = "spin-sqlite" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", "spin-app", "spin-core", - "spin-key-value", "spin-world", + "table", "tokio", ] [[package]] name = "spin-sqlite-inproc" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", @@ -4932,8 +4721,8 @@ dependencies = [ [[package]] name = "spin-sqlite-libsql" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", @@ -4947,8 +4736,8 @@ dependencies = [ [[package]] name = "spin-trigger" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", @@ -4983,7 +4772,7 @@ dependencies = [ "spin-world", "terminal", "tokio", - "toml", + "toml 0.5.11", "tracing", "url", "wasmtime", @@ -4991,8 +4780,8 @@ dependencies = [ [[package]] name = "spin-trigger-http" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "anyhow", "async-trait", @@ -5000,7 +4789,8 @@ dependencies = [ "futures", "futures-util", "http", - "hyper", + "http-body-util", + "hyper 1.0.0-rc.3", "indexmap 1.9.3", "outbound-http", "percent-encoding", @@ -5020,12 +4810,13 @@ dependencies = [ "wasi-common", "wasmtime", "wasmtime-wasi", + "wasmtime-wasi-http", ] [[package]] name = "spin-world" -version = "1.6.0-pre0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "wasmtime", ] @@ -5230,6 +5021,11 @@ dependencies = [ "winx", ] +[[package]] +name = "table" +version = "2.0.0-pre0" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" + [[package]] name = "tap" version = "1.0.1" @@ -5278,7 +5074,7 @@ dependencies = [ [[package]] name = "terminal" version = "0.1.0" -source = "git+https://github.com/fermyon/spin?rev=54c4d83987f0519ef885b532d577845443d4d61b#54c4d83987f0519ef885b532d577845443d4d61b" +source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ "atty", "once_cell", @@ -5370,7 +5166,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6e8a215badde081a06ee0a7fbc9c9f0d580c022fbdc547065f62103aef71e178" dependencies = [ "futures-util", - "hyper", + "hyper 0.14.27", "pin-project-lite", "thiserror", "tokio", @@ -5422,7 +5218,7 @@ dependencies = [ "libc", "mio", "num_cpus", - "parking_lot 0.12.1", + "parking_lot", "pin-project-lite", "signal-hook-registry", "socket2 0.5.4", @@ -5464,7 +5260,7 @@ dependencies = [ "futures-channel", "futures-util", "log", - "parking_lot 0.12.1", + "parking_lot", "percent-encoding", "phf", "pin-project-lite", @@ -5498,32 +5294,6 @@ dependencies = [ "tokio", ] -[[package]] -name = "tokio-stream" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" -dependencies = [ - "futures-core", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "tokio-tar" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d5714c010ca3e5c27114c1cdeb9d14641ace49874aa5626d7149e47aedace75" -dependencies = [ - "filetime", - "futures-core", - "libc", - "redox_syscall 0.3.5", - "tokio", - "tokio-stream", - "xattr 1.0.1", -] - [[package]] name = "tokio-util" version = "0.6.10" @@ -5562,6 +5332,41 @@ dependencies = [ "serde", ] +[[package]] +name = "toml" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" +dependencies = [ + "indexmap 2.0.2", + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.20.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" +dependencies = [ + "indexmap 2.0.2", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + [[package]] name = "tower-service" version = "0.3.2" @@ -5600,16 +5405,6 @@ dependencies = [ "once_cell", ] -[[package]] -name = "tracing-futures" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97d095ae15e245a057c8e8451bab9b3ee1e1f68e9ba2b4fbc18d0ac5237835f2" -dependencies = [ - "pin-project", - "tracing", -] - [[package]] name = "try-lock" version = "0.2.4" @@ -5827,9 +5622,8 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasi-cap-std-sync" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec076cd75f207327f5bfaebb915ef03d82c3a01a6d9b5d0deb6eafffceab3095" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "async-trait", @@ -5840,7 +5634,6 @@ dependencies = [ "fs-set-times", "io-extras", "io-lifetimes 2.0.2", - "is-terminal", "once_cell", "rustix 0.38.19", "system-interface", @@ -5851,9 +5644,8 @@ dependencies = [ [[package]] name = "wasi-common" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f391b334c783c1154369be62c31dc8598ffa1a6c34ea05d7f8cf0b18ce7c272" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "bitflags 2.4.1", @@ -5871,9 +5663,8 @@ dependencies = [ [[package]] name = "wasi-tokio" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6de05e4d9f81b8e82672cff04bab4128a170274ed2c44ff4c9e36905aefcaf35" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "cap-std", @@ -5952,15 +5743,6 @@ version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" -[[package]] -name = "wasm-encoder" -version = "0.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ba64e81215916eaeb48fee292f29401d69235d62d8b8fd92a7b2844ec5ae5f7" -dependencies = [ - "leb128", -] - [[package]] name = "wasm-encoder" version = "0.33.2" @@ -6008,16 +5790,6 @@ dependencies = [ "web-sys", ] -[[package]] -name = "wasmparser" -version = "0.112.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e986b010f47fcce49cf8ea5d5f9e5d2737832f12b53ae8ae785bbe895d0877bf" -dependencies = [ - "indexmap 2.0.2", - "semver", -] - [[package]] name = "wasmparser" version = "0.113.3" @@ -6050,9 +5822,8 @@ dependencies = [ [[package]] name = "wasmtime" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16ed7db409c1acf60d33128b2a38bee25aaf38c4bd955ab98a5b623c8294593c" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "async-trait", @@ -6073,8 +5844,8 @@ dependencies = [ "serde_derive", "serde_json", "target-lexicon", - "wasm-encoder 0.32.0", - "wasmparser 0.112.0", + "wasm-encoder 0.33.2", + "wasmparser 0.113.3", "wasmtime-cache", "wasmtime-component-macro", "wasmtime-component-util", @@ -6090,18 +5861,16 @@ dependencies = [ [[package]] name = "wasmtime-asm-macros" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53af0f8f6271bd687fe5632c8fe0a0f061d0aa1b99a0cd4e1df8e4cbeb809d2f" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cfg-if", ] [[package]] name = "wasmtime-cache" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41376a7c094335ee08abe6a4eff79a32510cc805a249eff1b5e7adf0a42e7cdf" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "base64 0.21.4", @@ -6111,17 +5880,16 @@ dependencies = [ "rustix 0.38.19", "serde", "serde_derive", - "sha2 0.10.8", - "toml", + "sha2", + "toml 0.5.11", "windows-sys 0.48.0", "zstd", ] [[package]] name = "wasmtime-component-macro" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74ab5b291f2dad56f1e6929cc61fb7cac68845766ca77c3838b5d05d82c33976" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "proc-macro2", @@ -6129,20 +5897,18 @@ dependencies = [ "syn 2.0.38", "wasmtime-component-util", "wasmtime-wit-bindgen", - "wit-parser", + "wit-parser 0.11.3", ] [[package]] name = "wasmtime-component-util" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21436177bf19f6b60dc0b83ad5872e849892a4a90c3572785e1a28c0e2e1132c" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" [[package]] name = "wasmtime-cranelift" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "920e42058862d1f7a3dd3fca73cb495a20d7506e3ada4bbc0a9780cd636da7ca" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "cfg-if", @@ -6157,7 +5923,7 @@ dependencies = [ "object", "target-lexicon", "thiserror", - "wasmparser 0.112.0", + "wasmparser 0.113.3", "wasmtime-cranelift-shared", "wasmtime-environ", "wasmtime-versioned-export-macros", @@ -6165,9 +5931,8 @@ dependencies = [ [[package]] name = "wasmtime-cranelift-shared" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "516d63bbe18219e64a9705cf3a2c865afe1fb711454ea03091dc85a1d708194d" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "cranelift-codegen", @@ -6181,9 +5946,8 @@ dependencies = [ [[package]] name = "wasmtime-environ" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59cef239d663885f1427f8b8f4fde7be6075249c282580d94b480f11953ca194" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "cranelift-entity", @@ -6195,8 +5959,8 @@ dependencies = [ "serde_derive", "target-lexicon", "thiserror", - "wasm-encoder 0.32.0", - "wasmparser 0.112.0", + "wasm-encoder 0.33.2", + "wasmparser 0.113.3", "wasmprinter", "wasmtime-component-util", "wasmtime-types", @@ -6204,9 +5968,8 @@ dependencies = [ [[package]] name = "wasmtime-fiber" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ef118b557df6193cd82cfb45ab57cd12388fedfe2bb76f090b2d77c96c1b56e" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cc", "cfg-if", @@ -6218,9 +5981,8 @@ dependencies = [ [[package]] name = "wasmtime-jit" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8089d5909b8f923aad57702ebaacb7b662aa9e43a3f71e83e025c5379a1205f" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "addr2line", "anyhow", @@ -6245,9 +6007,8 @@ dependencies = [ [[package]] name = "wasmtime-jit-debug" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b13924aedf6799ad66edb25500a20e3226629978b30a958c55285352bad130a" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "object", "once_cell", @@ -6257,9 +6018,8 @@ dependencies = [ [[package]] name = "wasmtime-jit-icache-coherence" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6ff5f3707a5e3797deeeeac6ac26b2e1dd32dbc06693c0ab52e8ac4d18ec706" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cfg-if", "libc", @@ -6268,9 +6028,8 @@ dependencies = [ [[package]] name = "wasmtime-runtime" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ab4ce04ac05342edfa7f42895f2a5d8b16ee914330869acb865cd1facf265f" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "cc", @@ -6286,7 +6045,7 @@ dependencies = [ "rand 0.8.5", "rustix 0.38.19", "sptr", - "wasm-encoder 0.32.0", + "wasm-encoder 0.33.2", "wasmtime-asm-macros", "wasmtime-environ", "wasmtime-fiber", @@ -6298,22 +6057,20 @@ dependencies = [ [[package]] name = "wasmtime-types" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecf61e21d5bd95e1ad7fa42b7bdabe21220682d6a6046d376edca29760849222" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "cranelift-entity", "serde", "serde_derive", "thiserror", - "wasmparser 0.112.0", + "wasmparser 0.113.3", ] [[package]] name = "wasmtime-versioned-export-macros" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe877472cbdd6d96b4ecdc112af764e3b9d58c2e4175a87828f892ab94c60643" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "proc-macro2", "quote", @@ -6322,9 +6079,8 @@ dependencies = [ [[package]] name = "wasmtime-wasi" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6db393deb775e8bece53a6869be6425e46b28426aa7709df8c529a19759f4be" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "async-trait", @@ -6339,14 +6095,15 @@ dependencies = [ "futures", "io-extras", "io-lifetimes 2.0.2", - "is-terminal", "libc", + "log", "once_cell", "rustix 0.38.19", "system-interface", "thiserror", "tokio", "tracing", + "url", "wasi-cap-std-sync", "wasi-common", "wasi-tokio", @@ -6355,18 +6112,39 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "wasmtime-wasi-http" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" +dependencies = [ + "anyhow", + "async-trait", + "bytes", + "futures", + "http", + "http-body 1.0.0-rc.2", + "http-body-util", + "hyper 1.0.0-rc.3", + "rustls 0.21.7", + "tokio", + "tokio-rustls 0.24.1", + "tracing", + "wasmtime", + "wasmtime-wasi", + "webpki-roots", +] + [[package]] name = "wasmtime-winch" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bc5a770003807c55f2187a0092dea01722b0e24151e35816bd5091538bb8e88" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "cranelift-codegen", "gimli", "object", "target-lexicon", - "wasmparser 0.112.0", + "wasmparser 0.113.3", "wasmtime-cranelift-shared", "wasmtime-environ", "winch-codegen", @@ -6374,21 +6152,19 @@ dependencies = [ [[package]] name = "wasmtime-wit-bindgen" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62003d48822f89cc393e93643366ddbee1766779c0874353b8ba2ede4679fbf9" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "heck 0.4.1", "indexmap 2.0.2", - "wit-parser", + "wit-parser 0.11.3", ] [[package]] name = "wasmtime-wmemcheck" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5412bb464066d64c3398c96e6974348f90fa2a55110ad7da3f9295438cd4de84" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" [[package]] name = "wast" @@ -6458,9 +6234,8 @@ dependencies = [ [[package]] name = "wiggle" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da341f21516453768bd115bdc17b186c0a1ab6773c2b2eeab44a062db49bd616" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "async-trait", @@ -6473,9 +6248,8 @@ dependencies = [ [[package]] name = "wiggle-generate" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e22c6bd943a4bae37052b79d249fb32d7afa22b3f6a147a5f2e7bc2b9f901879" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "heck 0.4.1", @@ -6488,9 +6262,8 @@ dependencies = [ [[package]] name = "wiggle-macro" -version = "13.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d72d838b7c9302b2ca7c44f36d6af5ce1988239a16deba951d99c4630d17caf" +version = "14.0.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "proc-macro2", "quote", @@ -6531,9 +6304,8 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] name = "winch-codegen" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50647204d600a2a112eefac0645ba6653809a15bd362c7e4e6a049a5bdff0de9" +version = "0.12.0" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "cranelift-codegen", @@ -6541,7 +6313,7 @@ dependencies = [ "regalloc2", "smallvec", "target-lexicon", - "wasmparser 0.112.0", + "wasmparser 0.113.3", "wasmtime-environ", ] @@ -6686,6 +6458,15 @@ version = "0.48.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" +[[package]] +name = "winnow" +version = "0.5.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a3b801d0e0a6726477cc207f60162da452f3a95adb368399bef20a946e06f65c" +dependencies = [ + "memchr", +] + [[package]] name = "winreg" version = "0.50.0" @@ -6708,20 +6489,21 @@ dependencies = [ [[package]] name = "wit-component" -version = "0.14.7" +version = "0.15.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66981fe851118de3b6b7a92f51ce8a86b919569c37becbeca8df9bd30141da25" +checksum = "c1bc644bb4205a2ee74035e5d35958777575fa4c6dd38ce7226c7680be2861c1" dependencies = [ "anyhow", "bitflags 2.4.1", "indexmap 2.0.2", "log", "serde", + "serde_derive", "serde_json", - "wasm-encoder 0.33.2", + "wasm-encoder 0.35.0", "wasm-metadata", - "wasmparser 0.113.3", - "wit-parser", + "wasmparser 0.115.0", + "wit-parser 0.12.0", ] [[package]] @@ -6742,11 +6524,27 @@ dependencies = [ "url", ] +[[package]] +name = "wit-parser" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d08c9557c65c428ac18a3cce80bf2527dbec24ab06639642c7db73f2c7613f93" +dependencies = [ + "anyhow", + "id-arena", + "indexmap 2.0.2", + "log", + "semver", + "serde", + "serde_derive", + "serde_json", + "unicode-xid", +] + [[package]] name = "witx" version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e366f27a5cabcddb2706a78296a40b8fcc451e1a6aba2fc1d94b4a01bdaaef4b" +source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", "log", @@ -6783,23 +6581,9 @@ dependencies = [ [[package]] name = "zeroize" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4756f7db3f7b5574938c3eb1c117038b8e07f95ee6718c0efad4ac21508f1efd" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] +checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" [[package]] name = "zip" diff --git a/Cargo.toml b/Cargo.toml index b87113c..df10fa8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -32,15 +32,15 @@ semver = "1.0" serde = { version = "1.0", features = ["derive"] } serde_json = "1.0.82" sha2 = "0.10.2" -spin-app = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -spin-common = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -spin-loader = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -spin-manifest = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -spin-http = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -spin-oci = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -spin-trigger = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -spin-trigger-http = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } -terminal = { git = "https://github.com/fermyon/spin", rev = "54c4d83987f0519ef885b532d577845443d4d61b" } +spin-app = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +spin-common = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +spin-loader = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +spin-manifest = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +spin-http = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +spin-oci = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +spin-trigger = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +spin-trigger-http = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } +terminal = { git = "https://github.com/fermyon/spin", rev = "57b004cf7fa2b6ad545bd8292f2745ed6424f05b" } tempfile = "3.3.0" url = "2.3" uuid = { version = "1.3", features = ["v4"] } diff --git a/src/commands/deploy.rs b/src/commands/deploy.rs index c81a434..5a8f84e 100644 --- a/src/commands/deploy.rs +++ b/src/commands/deploy.rs @@ -12,7 +12,6 @@ use cloud_openapi::models::{ use oci_distribution::{token_cache, Reference, RegistryOperation}; use spin_common::{arg_parser::parse_kv, sloth}; use spin_http::{app_info::AppInfo, routes::RoutePattern}; -use spin_manifest::ApplicationTrigger; use tokio::fs; use tracing::instrument; @@ -303,45 +302,22 @@ impl DeployCommand { async fn load_cloud_app(&self, working_dir: &Path) -> Result { let app_source = self.resolve_app_source(); - match &app_source { + let locked_app = match &app_source { AppSource::File(app_file) => { - let cfg_any = spin_loader::local::raw_manifest_from_file(&app_file).await?; - let cfg = cfg_any.into_v1(); - - match cfg.info.trigger { - ApplicationTrigger::Http(_) => {} - ApplicationTrigger::Redis(_) => bail!("Redis triggers are not supported"), - ApplicationTrigger::External(_) => bail!("External triggers are not supported"), - } - - let app = spin_loader::from_file(app_file, Some(working_dir)).await?; - let locked_app = spin_trigger::locked::build_locked_app(app, working_dir)?; - - Ok(DeployableApp(locked_app)) + spin_loader::from_file( + &app_file, + spin_loader::FilesMountStrategy::Copy(working_dir.to_owned()), + ) + .await? } AppSource::OciRegistry(reference) => { let mut oci_client = spin_oci::Client::new(false, None) .await .context("cannot create registry client")?; - let locked_app = spin_oci::OciLoader::new(working_dir) + spin_oci::OciLoader::new(working_dir) .load_app(&mut oci_client, reference) - .await?; - - let unsupported_triggers = locked_app - .triggers - .iter() - .filter(|t| t.trigger_type != "http") - .map(|t| format!("'{}'", t.trigger_type)) - .collect::>(); - if !unsupported_triggers.is_empty() { - bail!( - "Non-HTTP triggers are not supported - app uses {}", - unsupported_triggers.join(", ") - ); - } - - Ok(DeployableApp(locked_app)) + .await? } AppSource::None => { anyhow::bail!("Default file '{DEFAULT_MANIFEST_FILE}' not found."); @@ -349,7 +325,22 @@ impl DeployCommand { AppSource::Unresolvable(err) => { anyhow::bail!("{err}"); } + }; + + let unsupported_triggers = locked_app + .triggers + .iter() + .filter(|t| t.trigger_type != "http") + .map(|t| format!("'{}'", t.trigger_type)) + .collect::>(); + if !unsupported_triggers.is_empty() { + bail!( + "Non-HTTP triggers are not supported - app uses {}", + unsupported_triggers.join(", ") + ); } + + Ok(DeployableApp(locked_app)) } async fn validate_deployment_environment( From eff5f261c531070df201a148d6d035cd8d72e090 Mon Sep 17 00:00:00 2001 From: itowlson Date: Tue, 24 Oct 2023 12:52:51 +1300 Subject: [PATCH 2/3] Set default base Signed-off-by: itowlson --- Cargo.lock | 278 ++++++++++++++++--------------- src/commands/deploy.rs | 82 +++++++++ testdata/based_v1.toml | 10 ++ testdata/based_v2.toml | 12 ++ testdata/dummy.not-actually-wasm | 1 + testdata/unbased_v1.toml | 10 ++ testdata/unbased_v2.toml | 9 + 7 files changed, 266 insertions(+), 136 deletions(-) create mode 100644 testdata/based_v1.toml create mode 100644 testdata/based_v2.toml create mode 100644 testdata/dummy.not-actually-wasm create mode 100644 testdata/unbased_v1.toml create mode 100644 testdata/unbased_v2.toml diff --git a/Cargo.lock b/Cargo.lock index 591dd14..efa23f1 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -36,13 +36,14 @@ dependencies = [ [[package]] name = "ahash" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" +checksum = "cd7d5a2cecb58716e47d67d5703a249964b14c7be1ec3cad3affc295b2d1c35d" dependencies = [ "cfg-if", "once_cell", "version_check", + "zerocopy", ] [[package]] @@ -175,9 +176,9 @@ dependencies = [ "log", "parking", "polling", - "rustix 0.37.25", + "rustix 0.37.26", "slab", - "socket2 0.4.9", + "socket2 0.4.10", "waker-fn", ] @@ -203,7 +204,7 @@ dependencies = [ "cfg-if", "event-listener 3.0.0", "futures-lite", - "rustix 0.38.19", + "rustix 0.38.20", "windows-sys 0.48.0", ] @@ -219,7 +220,7 @@ dependencies = [ "cfg-if", "futures-core", "futures-io", - "rustix 0.38.19", + "rustix 0.38.20", "signal-hook-registry", "slab", "windows-sys 0.48.0", @@ -289,9 +290,9 @@ dependencies = [ [[package]] name = "async-task" -version = "4.4.1" +version = "4.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9441c6b2fe128a7c2bf680a44c34d0df31ce09e5b7e401fcca3faa483dbc921" +checksum = "b4eb2cdb97421e01129ccb49169d8279ed21e829929144f4a22a6e54ac549ca1" [[package]] name = "async-trait" @@ -334,7 +335,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32568c56fda7f2f1173430298bddeb507ed44e99bd989ba1156a25534bff5d98" dependencies = [ "async-trait", - "base64 0.21.4", + "base64 0.21.5", "bytes", "dyn-clone", "futures", @@ -406,9 +407,9 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.4" +version = "0.21.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ba43ea6f343b788c8764558649e08df62f86c6ef251fdaeb1ffd010a9ae50a2" +checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" [[package]] name = "base64ct" @@ -587,7 +588,7 @@ checksum = "6ffc30dee200c20b4dcb80572226f42658e1d9c4b668656d7cc59c33d50e396e" dependencies = [ "cap-primitives", "cap-std", - "rustix 0.38.19", + "rustix 0.38.20", "smallvec", ] @@ -603,7 +604,7 @@ dependencies = [ "io-lifetimes 2.0.2", "ipnet", "maybe-owned", - "rustix 0.38.19", + "rustix 0.38.20", "windows-sys 0.48.0", "winx", ] @@ -627,7 +628,7 @@ dependencies = [ "cap-primitives", "io-extras", "io-lifetimes 2.0.2", - "rustix 0.38.19", + "rustix 0.38.20", ] [[package]] @@ -638,7 +639,7 @@ checksum = "f8f52b3c8f4abfe3252fd0a071f3004aaa3b18936ec97bdbd8763ce03aff6247" dependencies = [ "cap-primitives", "once_cell", - "rustix 0.38.19", + "rustix 0.38.20", "winx", ] @@ -841,13 +842,13 @@ dependencies = [ [[package]] name = "comfy-table" -version = "7.0.1" +version = "7.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ab77dbd8adecaf3f0db40581631b995f312a8a5ae3aa9993188bb8f23d83a5b" +checksum = "7c64043d6c7b7a4c58e39e7efccfdea7b93d885a795d0c054a69dbbf4dd52686" dependencies = [ "crossterm", - "strum 0.24.1", - "strum_macros 0.24.3", + "strum 0.25.0", + "strum_macros 0.25.3", "unicode-width", ] @@ -906,9 +907,9 @@ dependencies = [ [[package]] name = "cpufeatures" -version = "0.2.9" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" +checksum = "3fbc60abd742b35f2492f808e1abbb83d45f72db402e14c55057edc9c7b1e9e4" dependencies = [ "libc", ] @@ -934,7 +935,7 @@ dependencies = [ "cranelift-entity", "cranelift-isle", "gimli", - "hashbrown 0.14.1", + "hashbrown 0.14.2", "log", "regalloc2", "smallvec", @@ -1090,17 +1091,14 @@ dependencies = [ [[package]] name = "crossterm" -version = "0.26.1" +version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a84cda67535339806297f1b331d6dd6320470d2a0fe65381e79ee9e156dd3d13" +checksum = "f476fe445d41c9e991fd07515a6f463074b782242ccf4a5b7b1d1012e70824df" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.1", "crossterm_winapi", "libc", - "mio", "parking_lot", - "signal-hook", - "signal-hook-mio", "winapi", ] @@ -1544,7 +1542,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0b0377f1edc77dbd1118507bc7a66e4ab64d2b90c66f90726dc801e73a8c68f9" dependencies = [ "cfg-if", - "rustix 0.38.19", + "rustix 0.38.20", "windows-sys 0.48.0", ] @@ -1628,7 +1626,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dd738b84894214045e8414eaded76359b4a5773f0a0a56b16575110739cdcf39" dependencies = [ "io-lifetimes 2.0.2", - "rustix 0.38.19", + "rustix 0.38.20", "windows-sys 0.48.0", ] @@ -1901,9 +1899,9 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.1" +version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dfda62a12f55daeae5015f81b0baea145391cb4520f86c248fc615d72640d12" +checksum = "f93e7192158dbcda357bdec5fb5788eebf8bbac027f3f33e719d29135ae84156" dependencies = [ "ahash", "allocator-api2", @@ -1915,7 +1913,7 @@ version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" dependencies = [ - "hashbrown 0.14.1", + "hashbrown 0.14.2", ] [[package]] @@ -1970,7 +1968,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f16b4e41e289da3fd60e64f245246a97e78fab7b3788c6d8147b3ae7d9f5e533" dependencies = [ "anyhow", - "base64 0.21.4", + "base64 0.21.5", "serde", "serde_json", ] @@ -2078,7 +2076,7 @@ dependencies = [ "httpdate", "itoa", "pin-project-lite", - "socket2 0.4.9", + "socket2 0.4.10", "tokio", "tower-service", "tracing", @@ -2197,7 +2195,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8adf3ddd720272c6ea8bf59463c04e0f93d0bbf7c5439b691bca2987e0270897" dependencies = [ "equivalent", - "hashbrown 0.14.1", + "hashbrown 0.14.2", "serde", ] @@ -2266,9 +2264,9 @@ checksum = "bffb4def18c48926ccac55c1223e02865ce1a821751a95920448662696e7472c" [[package]] name = "ipnet" -version = "2.8.0" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" [[package]] name = "itertools" @@ -2507,7 +2505,7 @@ version = "0.31.11" source = "git+https://github.com/vdice/libsql-client-rs?branch=chore/bump-deps#f60e71ca91ba6d914d3482a79ba994a7157be0c3" dependencies = [ "anyhow", - "base64 0.21.4", + "base64 0.21.5", "fallible-iterator 0.3.0", "futures", "hrana-client-proto", @@ -2643,9 +2641,9 @@ dependencies = [ [[package]] name = "lock_api" -version = "0.4.10" +version = "0.4.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" +checksum = "3c168f8615b12bc01f9c17e2eb0cc07dcae1940121185446edc3744920e8ef45" dependencies = [ "autocfg", "scopeguard", @@ -2731,7 +2729,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2cffa4ad52c6f791f4f8b15f0c05f9824b2ced1160e88cc393d64fff9a8ac64" dependencies = [ - "rustix 0.38.19", + "rustix 0.38.20", ] [[package]] @@ -2785,9 +2783,9 @@ dependencies = [ [[package]] name = "mio" -version = "0.8.8" +version = "0.8.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" +checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" dependencies = [ "libc", "log", @@ -2867,7 +2865,7 @@ dependencies = [ "priority-queue", "serde", "serde_json", - "socket2 0.5.4", + "socket2 0.5.5", "thiserror", "tokio", "tokio-native-tls", @@ -2882,7 +2880,7 @@ version = "0.30.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "57349d5a326b437989b6ee4dc8f2f34b0cc131202748414712a8e7d98952fc8c" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "bindgen", "bitflags 2.4.1", "bitvec", @@ -3016,7 +3014,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9cf5f9dd3933bd50a9e1f149ec995f39ae2c496d31fd772c1fd45ebc27e902b0" dependencies = [ "crc32fast", - "hashbrown 0.14.1", + "hashbrown 0.14.2", "indexmap 2.0.2", "memchr", ] @@ -3230,9 +3228,9 @@ dependencies = [ [[package]] name = "parking" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e52c774a4c39359c1d1c52e43f73dd91a75a614652c825408eec30c95a9b2067" +checksum = "bb813b8af86854136c6922af0598d719255ecb2179515e6e7730d468f05c9cae" [[package]] name = "parking_lot" @@ -3246,13 +3244,13 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.8" +version = "0.9.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" +checksum = "4c42a9226546d68acdd9c0a280d17ce19bfe27a46bf68784e4066115788d008e" dependencies = [ "cfg-if", "libc", - "redox_syscall 0.3.5", + "redox_syscall 0.4.1", "smallvec", "windows-targets 0.48.5", ] @@ -3322,7 +3320,7 @@ version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6b13fe415cdf3c8e44518e18a7c95a13431d9bdf6d15367d82b23c377fdd441a" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "serde", ] @@ -3455,7 +3453,7 @@ version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49b6c5ef183cd3ab4ba005f1ca64c21e8bd97ce4699cfea9e8d9a2c4958ca520" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "byteorder", "bytes", "fallible-iterator 0.2.0", @@ -3740,6 +3738,15 @@ dependencies = [ "bitflags 1.3.2", ] +[[package]] +name = "redox_syscall" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" +dependencies = [ + "bitflags 1.3.2", +] + [[package]] name = "redox_users" version = "0.4.3" @@ -3806,7 +3813,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "046cd98826c46c2ac8ddecae268eb5c2e58628688a5fc7a2643704a73faba95b" dependencies = [ "async-compression", - "base64 0.21.4", + "base64 0.21.5", "bytes", "encoding_rs", "futures-core", @@ -3863,9 +3870,9 @@ dependencies = [ [[package]] name = "ring" -version = "0.17.4" +version = "0.17.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fce3045ffa7c981a6ee93f640b538952e155f1ae3a1a02b84547fc7a56b7059a" +checksum = "fb0205304757e5d899b9c2e448b867ffd03ae7f988002e47cd24954391394d0b" dependencies = [ "cc", "getrandom 0.2.10", @@ -3973,9 +3980,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.37.25" +version = "0.37.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4eb579851244c2c03e7c24f501c3432bed80b8f720af1d6e5b0e0f01555a035" +checksum = "84f3f8f960ed3b5a59055428714943298bf3fa2d4a1d53135084e0544829d995" dependencies = [ "bitflags 1.3.2", "errno", @@ -3987,9 +3994,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.19" +version = "0.38.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "745ecfa778e66b2b63c88a61cb36e0eea109e803b0b86bf9879fbc77c70e86ed" +checksum = "67ce50cb2e16c2903e30d1cbccfd8387a74b9d4c938b6a4c5ec6cc7556f7a8a0" dependencies = [ "bitflags 2.4.1", "errno", @@ -4039,7 +4046,7 @@ version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", ] [[package]] @@ -4205,9 +4212,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96426c9936fd7a0124915f9185ea1d20aa9445cc9821142f0a73bc9207a2e186" +checksum = "12022b835073e5b11e90a14f86838ceb1c8fb0325b72416845c487ac0fa95e80" dependencies = [ "serde", ] @@ -4319,27 +4326,6 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a7cee0529a6d40f580e7a5e6c495c8fbfe21b7b52795ed4bb5e62cdf92bc6380" -[[package]] -name = "signal-hook" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8621587d4798caf8eb44879d42e56b9a93ea5dcd315a6487c357130095b62801" -dependencies = [ - "libc", - "signal-hook-registry", -] - -[[package]] -name = "signal-hook-mio" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29ad2e15f37ec9a6cc544097b78a1ec90001e9f71b81338ca39f430adaca99af" -dependencies = [ - "libc", - "mio", - "signal-hook", -] - [[package]] name = "signal-hook-registry" version = "1.4.1" @@ -4378,9 +4364,9 @@ checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" [[package]] name = "socket2" -version = "0.4.9" +version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" +checksum = "9f7916fc008ca5542385b89a3d3ce689953c143e9304a9bf8beec1de48994c0d" dependencies = [ "libc", "winapi", @@ -4388,9 +4374,9 @@ dependencies = [ [[package]] name = "socket2" -version = "0.5.4" +version = "0.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4031e820eb552adee9295814c0ced9e5cf38ddf1e8b7d566d6de8e2538ea989e" +checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" dependencies = [ "libc", "windows-sys 0.48.0", @@ -4453,7 +4439,7 @@ dependencies = [ "wasm-encoder 0.35.0", "wasmparser 0.115.0", "wit-component", - "wit-parser 0.12.0", + "wit-parser 0.12.1", ] [[package]] @@ -4485,7 +4471,7 @@ dependencies = [ "cap-std", "crossbeam-channel", "io-extras", - "rustix 0.37.25", + "rustix 0.37.26", "system-interface", "tokio", "tracing", @@ -4633,7 +4619,7 @@ dependencies = [ "thiserror", "tokio", "tokio-util 0.6.10", - "toml 0.8.2", + "toml 0.8.4", "tracing", "walkdir", ] @@ -4649,7 +4635,7 @@ dependencies = [ "serde", "spin-serde", "thiserror", - "toml 0.8.2", + "toml 0.8.4", ] [[package]] @@ -4660,7 +4646,7 @@ dependencies = [ "anyhow", "async-compression", "async-tar", - "base64 0.21.4", + "base64 0.21.5", "dirs 4.0.0", "dkregistry", "docker_credential", @@ -4686,7 +4672,7 @@ name = "spin-serde" version = "2.0.0-pre0" source = "git+https://github.com/fermyon/spin?rev=57b004cf7fa2b6ad545bd8292f2745ed6424f05b#57b004cf7fa2b6ad545bd8292f2745ed6424f05b" dependencies = [ - "base64 0.21.4", + "base64 0.21.5", "serde", ] @@ -4904,9 +4890,9 @@ checksum = "cae14b91c7d11c9a851d3fbc80a963198998c2a64eec840477fa92d8ce9b70bb" [[package]] name = "strum" -version = "0.24.1" +version = "0.25.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63f" +checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125" [[package]] name = "strum_macros" @@ -4923,15 +4909,15 @@ dependencies = [ [[package]] name = "strum_macros" -version = "0.24.3" +version = "0.25.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59" +checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0" dependencies = [ "heck 0.4.1", "proc-macro2", "quote", "rustversion", - "syn 1.0.109", + "syn 2.0.38", ] [[package]] @@ -5016,7 +5002,7 @@ dependencies = [ "cap-std", "fd-lock", "io-lifetimes 2.0.2", - "rustix 0.38.19", + "rustix 0.38.20", "windows-sys 0.48.0", "winx", ] @@ -5045,9 +5031,9 @@ dependencies = [ [[package]] name = "target-lexicon" -version = "0.12.11" +version = "0.12.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d0e916b1148c8e263850e1ebcbd046f333e0683c724876bb0da63ea4373dc8a" +checksum = "14c39fd04924ca3a864207c66fc2cd7d22d7c016007f9ce846cbb9326331930a" [[package]] name = "tempfile" @@ -5058,7 +5044,7 @@ dependencies = [ "cfg-if", "fastrand 2.0.1", "redox_syscall 0.3.5", - "rustix 0.38.19", + "rustix 0.38.20", "windows-sys 0.48.0", ] @@ -5095,18 +5081,18 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "thiserror" -version = "1.0.49" +version = "1.0.50" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1177e8c6d7ede7afde3585fd2513e611227efd6481bd78d2e82ba1ce16557ed4" +checksum = "f9a7210f5c9a7156bb50aa36aed4c95afb51df0df00713949448cf9e97d382d2" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.49" +version = "1.0.50" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10712f02019e9288794769fba95cd6847df9874d49d871d062172f9dd41bc4cc" +checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" dependencies = [ "proc-macro2", "quote", @@ -5221,7 +5207,7 @@ dependencies = [ "parking_lot", "pin-project-lite", "signal-hook-registry", - "socket2 0.5.4", + "socket2 0.5.5", "tokio-macros", "windows-sys 0.48.0", ] @@ -5267,7 +5253,7 @@ dependencies = [ "postgres-protocol", "postgres-types", "rand 0.8.5", - "socket2 0.5.4", + "socket2 0.5.5", "tokio", "tokio-util 0.7.9", "whoami", @@ -5334,9 +5320,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.2" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" +checksum = "2ef75d881185fd2df4a040793927c153d863651108a93c7e17a9e591baa95cc6" dependencies = [ "indexmap 2.0.2", "serde", @@ -5347,18 +5333,18 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "0.6.3" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" +checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" dependencies = [ "serde", ] [[package]] name = "toml_edit" -version = "0.20.2" +version = "0.20.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" +checksum = "380f9e8120405471f7c9ad1860a713ef5ece6a670c7eae39225e477340f32fc4" dependencies = [ "indexmap 2.0.2", "serde", @@ -5375,9 +5361,9 @@ checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" [[package]] name = "tracing" -version = "0.1.39" +version = "0.1.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee2ef2af84856a50c1d430afce2fdded0a4ec7eda868db86409b4543df0797f9" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" dependencies = [ "log", "pin-project-lite", @@ -5526,9 +5512,9 @@ dependencies = [ [[package]] name = "uuid" -version = "1.4.1" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79daa5ed5740825c40b389c5e50312b9c86df53fccd33f281df655642b43869d" +checksum = "88ad59a7560b41a70d191093a945f0b87bc1deeda46fb237479708a1d6b6cdfc" dependencies = [ "getrandom 0.2.10", "serde", @@ -5536,9 +5522,9 @@ dependencies = [ [[package]] name = "value-bag" -version = "1.4.1" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d92ccd67fb88503048c01b59152a04effd0782d035a83a6d256ce6085f08f4a3" +checksum = "4a72e1902dde2bd6441347de2b70b7f5d59bf157c6c62f0c44572607a1d55bbe" [[package]] name = "vaultrs" @@ -5635,7 +5621,7 @@ dependencies = [ "io-extras", "io-lifetimes 2.0.2", "once_cell", - "rustix 0.38.19", + "rustix 0.38.20", "system-interface", "tracing", "wasi-common", @@ -5653,7 +5639,7 @@ dependencies = [ "cap-std", "io-extras", "log", - "rustix 0.38.19", + "rustix 0.38.20", "thiserror", "tracing", "wasmtime", @@ -5670,7 +5656,7 @@ dependencies = [ "cap-std", "io-extras", "io-lifetimes 2.0.2", - "rustix 0.38.19", + "rustix 0.38.20", "tokio", "wasi-cap-std-sync", "wasi-common", @@ -5873,11 +5859,11 @@ version = "14.0.0" source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a40605f03e74bd78cefcc9acf3a#c796ce7376a57a40605f03e74bd78cefcc9acf3a" dependencies = [ "anyhow", - "base64 0.21.4", + "base64 0.21.5", "bincode", "directories-next", "log", - "rustix 0.38.19", + "rustix 0.38.20", "serde", "serde_derive", "sha2", @@ -5973,7 +5959,7 @@ source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a406 dependencies = [ "cc", "cfg-if", - "rustix 0.38.19", + "rustix 0.38.20", "wasmtime-asm-macros", "wasmtime-versioned-export-macros", "windows-sys 0.48.0", @@ -5994,7 +5980,7 @@ dependencies = [ "log", "object", "rustc-demangle", - "rustix 0.38.19", + "rustix 0.38.20", "serde", "serde_derive", "target-lexicon", @@ -6012,7 +5998,7 @@ source = "git+https://github.com/bytecodealliance/wasmtime?rev=c796ce7376a57a406 dependencies = [ "object", "once_cell", - "rustix 0.38.19", + "rustix 0.38.20", "wasmtime-versioned-export-macros", ] @@ -6043,7 +6029,7 @@ dependencies = [ "memoffset", "paste", "rand 0.8.5", - "rustix 0.38.19", + "rustix 0.38.20", "sptr", "wasm-encoder 0.33.2", "wasmtime-asm-macros", @@ -6098,7 +6084,7 @@ dependencies = [ "libc", "log", "once_cell", - "rustix 0.38.19", + "rustix 0.38.20", "system-interface", "thiserror", "tokio", @@ -6212,7 +6198,7 @@ version = "0.22.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed63aea5ce73d0ff405984102c42de94fc55a6b75765d621c65262469b3c9b53" dependencies = [ - "ring 0.17.4", + "ring 0.17.5", "untrusted 0.9.0", ] @@ -6503,7 +6489,7 @@ dependencies = [ "wasm-encoder 0.35.0", "wasm-metadata", "wasmparser 0.115.0", - "wit-parser 0.12.0", + "wit-parser 0.12.1", ] [[package]] @@ -6526,9 +6512,9 @@ dependencies = [ [[package]] name = "wit-parser" -version = "0.12.0" +version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d08c9557c65c428ac18a3cce80bf2527dbec24ab06639642c7db73f2c7613f93" +checksum = "f6ace9943d89bbf3dbbc71b966da0e7302057b311f36a4ac3d65ddfef17b52cf" dependencies = [ "anyhow", "id-arena", @@ -6579,6 +6565,26 @@ dependencies = [ "libc", ] +[[package]] +name = "zerocopy" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c19fae0c8a9efc6a8281f2e623db8af1db9e57852e04cde3e754dd2dc29340f" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc56589e9ddd1f1c28d4b4b5c773ce232910a6bb67a70133d61c9e347585efe9" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + [[package]] name = "zeroize" version = "1.6.0" diff --git a/src/commands/deploy.rs b/src/commands/deploy.rs index 5a8f84e..d6f0bfa 100644 --- a/src/commands/deploy.rs +++ b/src/commands/deploy.rs @@ -340,6 +340,8 @@ impl DeployCommand { ); } + let locked_app = ensure_http_base_set(locked_app); + Ok(DeployableApp(locked_app)) } @@ -455,6 +457,25 @@ impl DeployCommand { } } +// Spin now allows HTTP apps to omit the base path, but Cloud +// doesn't yet like this. This works around that by defaulting +// base if not set. (We don't check trigger type because by the +// time this is called we know it's HTTP.) +fn ensure_http_base_set( + mut locked_app: spin_app::locked::LockedApp, +) -> spin_app::locked::LockedApp { + if let Some(trigger) = locked_app + .metadata + .entry("trigger") + .or_insert_with(|| serde_json::Value::Object(Default::default())) + .as_object_mut() + { + trigger.entry("base").or_insert_with(|| "/".into()); + } + + locked_app +} + #[derive(Debug, PartialEq, Eq)] enum AppSource { None, @@ -1186,4 +1207,65 @@ mod test { sanitize_app_version("e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855e3b") ); } + + fn deploy_cmd_for_test_file(filename: &str) -> DeployCommand { + let path = PathBuf::from(env!("CARGO_MANIFEST_DIR")) + .join("testdata") + .join(filename); + DeployCommand { + app_source: None, + file_source: Some(path), + registry_source: None, + build: false, + readiness_timeout_secs: 60, + deployment_env_id: None, + key_values: vec![], + variables: vec![], + } + } + + fn get_trigger_base(mut app: DeployableApp) -> String { + let serde_json::map::Entry::Occupied(trigger) = app.0.metadata.entry("trigger") else { + panic!("Expected trigger metadata but entry was vacant"); + }; + let base = trigger + .get() + .as_object() + .unwrap() + .get("base") + .expect("Manifest should have had a base but didn't"); + base.as_str() + .expect("HTTP base should have been a string but wasn't") + .to_owned() + } + + #[tokio::test] + async fn if_http_base_is_set_then_it_is_respected() { + let temp_dir = tempfile::tempdir().unwrap(); + + let cmd = deploy_cmd_for_test_file("based_v1.toml"); + let app = cmd.load_cloud_app(temp_dir.path()).await.unwrap(); + let base = get_trigger_base(app); + assert_eq!("/base", base); + + let cmd = deploy_cmd_for_test_file("based_v2.toml"); + let app = cmd.load_cloud_app(temp_dir.path()).await.unwrap(); + let base = get_trigger_base(app); + assert_eq!("/base", base); + } + + #[tokio::test] + async fn if_http_base_is_not_set_then_it_is_inserted() { + let temp_dir = tempfile::tempdir().unwrap(); + + let cmd = deploy_cmd_for_test_file("unbased_v1.toml"); + let app = cmd.load_cloud_app(temp_dir.path()).await.unwrap(); + let base = get_trigger_base(app); + assert_eq!("/", base); + + let cmd = deploy_cmd_for_test_file("unbased_v2.toml"); + let app = cmd.load_cloud_app(temp_dir.path()).await.unwrap(); + let base = get_trigger_base(app); + assert_eq!("/", base); + } } diff --git a/testdata/based_v1.toml b/testdata/based_v1.toml new file mode 100644 index 0000000..d3f8856 --- /dev/null +++ b/testdata/based_v1.toml @@ -0,0 +1,10 @@ +spin_manifest_version = "1" +name = "based-v1" +version = "0.0.1" +trigger = { type = "http", base = "/base" } + +[[component]] +id = "dummy" +source = "dummy.not-actually-wasm" +[component.trigger] +route = "/dummy" diff --git a/testdata/based_v2.toml b/testdata/based_v2.toml new file mode 100644 index 0000000..4de381c --- /dev/null +++ b/testdata/based_v2.toml @@ -0,0 +1,12 @@ +spin_manifest_version = 2 + +[application] +name = "unbased_v1" +version = "0.1.0" + +[application.trigger.http] +base = "/base" + +[[trigger.http]] +route = "/..." +component = { source = "dummy.not-actually-wasm" } diff --git a/testdata/dummy.not-actually-wasm b/testdata/dummy.not-actually-wasm new file mode 100644 index 0000000..17a50ae --- /dev/null +++ b/testdata/dummy.not-actually-wasm @@ -0,0 +1 @@ +Dummy file that only exists because the loader checks for the existence of component sources \ No newline at end of file diff --git a/testdata/unbased_v1.toml b/testdata/unbased_v1.toml new file mode 100644 index 0000000..4e9a9cb --- /dev/null +++ b/testdata/unbased_v1.toml @@ -0,0 +1,10 @@ +spin_manifest_version = "1" +name = "based-v1" +version = "0.0.1" +trigger = { type = "http" } + +[[component]] +id = "dummy" +source = "dummy.not-actually-wasm" +[component.trigger] +route = "/dummy" diff --git a/testdata/unbased_v2.toml b/testdata/unbased_v2.toml new file mode 100644 index 0000000..7a769a8 --- /dev/null +++ b/testdata/unbased_v2.toml @@ -0,0 +1,9 @@ +spin_manifest_version = 2 + +[application] +name = "unbased_v1" +version = "0.1.0" + +[[trigger.http]] +route = "/..." +component = { source = "dummy.not-actually-wasm" } From 02c1b02c05f51e4adfd289a760b8b7d0241b3222 Mon Sep 17 00:00:00 2001 From: itowlson Date: Thu, 26 Oct 2023 10:12:16 +1300 Subject: [PATCH 3/3] Fix non-absolute base which Spin 2 allows Signed-off-by: itowlson --- src/commands/deploy.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/commands/deploy.rs b/src/commands/deploy.rs index d6f0bfa..3593db2 100644 --- a/src/commands/deploy.rs +++ b/src/commands/deploy.rs @@ -1010,9 +1010,16 @@ fn print_available_routes(app_base_url: &Url, base: &str, routes: &[HttpRoute]) let app_base_url = app_base_url.to_string(); let route_prefix = app_base_url.strip_suffix('/').unwrap_or(&app_base_url); + // Ensure base starts with a / + let base = if !base.starts_with('/') { + format!("/{base}") + } else { + base.to_owned() + }; + println!("Available Routes:"); for component in routes { - let route = RoutePattern::from(base, &component.route_pattern); + let route = RoutePattern::from(&base, &component.route_pattern); println!(" {}: {}{}", component.id, route_prefix, route); if let Some(description) = &component.description { println!(" {}", description);