fluxninja / aperture

Rate limiting, caching, and request prioritization for modern workloads
https://docs.fluxninja.com
Apache License 2.0
616 stars 24 forks source link

Running the playground on Windows #3210

Open PalatinatePotatoFarmer opened 6 months ago

PalatinatePotatoFarmer commented 6 months ago

Hi,

I wanted to have a look at Aperture and tried running the playground with Tilt on my Windows box (yes, that is what my employer gives me). Alas, it fails when trying to run a shell script from within the tilt file. Any suggestions to run this on Windows (aside from using a VM, or maybe WSL)?

Initial Build
Loading Tiltfile at: C:\project\GitHubPublic\aperture\playground\Tiltfile
local: git rev-parse --show-toplevel
 → C:/project/GitHubPublic/aperture
local: hostname
 → XXXXXXX
local: ../scripts/build_aperturectl.sh
ERROR: Traceback (most recent call last):
  C:\project\GitHubPublic\aperture\playground\Tiltfile:1361:30: in <toplevel>
  C:\project\GitHubPublic\aperture\playground\Tiltfile:986:60: in process_aperture_scenario
  C:\project\GitHubPublic\aperture\playground\Tiltfile:631:32: in render_dashboards
Error in local: command "../scripts/build_aperturectl.sh" failed.
error: fork/exec ../scripts/build_aperturectl.sh: %1 is not a valid Win32 application.
stdout:

THX PPF

kwapik commented 6 months ago

Hi @PalatinatePotatoFarmer ,

I am afraid that the playground was designed to work on Linux/MacOS environments only, so my only advice would be to try running this in a VM.

PalatinatePotatoFarmer commented 6 months ago

I was afraid so - but I actually got a bit further without starting yet-another VM - I am using minikube as K8s env (running as a regular Hyper-V VM) and configured kubectl inside my WSL environment (2nd hyper-V VM, effectively) against it. The script now runs, up to this point

ERROR: Traceback (most recent call last):
  /home/xxxx/GitHubPublic/aperture/playground/Tiltfile:1361:30: in <toplevel>
  /home/xxxx/GitHubPublic/aperture/playground/Tiltfile:986:60: in process_aperture_scenario
  /home/xxxx/GitHubPublic/aperture/playground/Tiltfile:631:32: in render_dashboards
Error in local: command "../scripts/build_aperturectl.sh" failed.
error: exit status 1
stdout:

stderr:
go: github.com/open-telemetry/opentelemetry-collector-contrib/extension/healthcheckextension@v0.93.0 requires
        github.com/open-telemetry/opentelemetry-collector-contrib/pkg/golden@v0.93.0-fn.patch.1: reading github.com/open-telemetry/opentelemetry-collector-contrib/pkg/golden/pkg/golden/go.mod at revision pkg/golden/v0.93.0-fn.patch.1: unknown revision pkg/golden/v0.93.0-fn.patch.1

Since this doesn't look like an obvious consequence of my somewhat unorthodox setup, I wonder what is going on there. A quick look on the script seems to indicate that a bit of patching takes place to take open-telemetry from a fork inside fluxninja repo (where the revision mentioned actually exists), but it seems that didn't work as expected, as the file is still taken from the mainline otel repo?