-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The viceroy_version
field seems to not be working
#1037
Comments
👋🏻 Thanks @dbraley for alerting us to this. It might be that the TTL on the Viceroy check hadn't expired. If you run
If the TTL hasn't expired, no checks will be executed. In those cases you can either modify the config to have a shorter TTL (e.g. "1m" for one minute) or you can force past the TTL using But that's only related to installing updates (which you clearly already had done) so I'll investigate as I'm thinking maybe there's a disconnect between what's specified in the fastly.toml manifest vs the internal Thanks again for raising this issue. |
Thanks! |
Hi @dbraley I'm not sure which CLI version you were using, but I just used a local build of the CLI and found the ability to install a specific Viceroy version worked fine (i.e. The fastly.toml config looked like this: [local_server]
viceroy_version = "0.8.0" |
I'm going to close this issue now, as it seems the CLI is working as intended. As you have correctly mentioned (and have used) there are also other options to allow you to change the Viceroy version:
|
AH! Okay, I think I see where we were going astray. Thank you for the quick feedback by the way, and sorry for not providing the cli version in the issue text where I was supposed to (had something else in my copy buffer, meant to come back and do that and forgot). Anyway, I think the problem is that we were using env files, which is where we have all of our ❯ head -3 fastly.frontend.toml
# This toml is part of the frontend development configuration.
[local_server]
viceroy_version = "0.8.1"
❯ fastly compute serve --env frontend --addr=0.0.0.0:8090 -v --file=local/wasm32-wasi/release/ka-fastly.wasm --skip-build
Fastly API token provided via config file (profile: personal)
Fastly API endpoint: https://api.fastly.com
INFO: Viceroy is installed but the CLI config (`fastly config`) shows the TTL, checking for a newer version,
hasn't expired. To force a refresh, re-run the command with the `--viceroy-check` flag.
✓ Running local server
Manifest: /Users/davidbraley/khan/webapp/services/fastly-khanacademy-dev/fastly.frontend.toml
Wasm binary: local/wasm32-wasi/release/ka-fastly.wasm
Viceroy binary: /Users/davidbraley/Library/Application Support/fastly/viceroy
Viceroy version: viceroy 0.9.1 But it doesn't work there. It does if you add it to the actual ❯ tail -2 fastly.toml
[local_server]
viceroy_version = "0.8.1"
❯ fastly compute serve --env frontend --addr=0.0.0.0:8090 -v --file=local/wasm32-wasi/release/ka-fastly.wasm --skip-build --viceroy-check
Fastly API token provided via config file (profile: personal)
Fastly API endpoint: https://api.fastly.com
INFO: Viceroy is already installed, and the installed version matches the required version (0.8.1) in the
fastly.toml file.
✓ Running local server
Manifest: /Users/davidbraley/khan/webapp/services/fastly-khanacademy-dev/fastly.frontend.toml
Wasm binary: local/wasm32-wasi/release/ka-fastly.wasm
Viceroy binary: /Users/davidbraley/Library/Application Support/fastly/viceroy
Viceroy version: viceroy 0.8.1 I'm honestly not sure if that's a bug or not, but if not it should probably be documented somewhere that the Anyway, I'm definitely unblocked a few ways, so I'll leave it to y'all to figure out if there's any actual action to be done here. Thanks again! |
This is great feedback @dbraley thank you! I actually forgot about the |
Version
Fastly CLI version v10.4.0 (4b869ab)
Built with go version go1.21.0 linux/amd64
Viceroy version: viceroy 0.9.1
What happened
This morning, we noticed a new version of Viceroy (0.9.0) seems to have broken our local development environment. I've filed fastly/Viceroy#321 with Viceroy to resolve that.
To keep our engineers moving while they work on it, we tried to force the version with the
viceroy_version
field in thefastly.toml
(https://developer.fastly.com/reference/compute/fastly-toml/#local-server) file used for development:We also tried with
viceroy_version = "v0.8.1"
. If I'm providing that information incorrectly, please do let me know.Neither attempt to set the version through the toml file showed any indication that they were using an older version of viceroy, and both still failed with the same exact bug. However, downloading v0.8.1 directly from https://github.com/fastly/Viceroy/releases/tag/v0.8.1 and using the
--viceroy-path
flag on thefastly compute serve
command did resolve the problem.The text was updated successfully, but these errors were encountered: