I have tried this on a couple different GCP instances with the same error below
ffoti@ep-test-gcp-debian:~$ sudo rpm -vi elastic-agent-7.10.0-x86_64.rpm
sudo: rpm: command not found
ffoti@ep-test-gcp-debian:~$ curl -L -O https://artifacts.elastic.co/downloads/beats/elastic-agent/elastic-agent-7.10.0-amd64.deb
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 90.4M 100 90.4M 0 0 74.7M 0 0:00:01 0:00:01 --:--:-- 74.7M
ffoti@ep-test-gcp-debian:~$ sudo dpkg -i elastic-agent-7.10.0-amd64.deb
Selecting previously unselected package elastic-agent.
(Reading database ... 38712 files and directories currently installed.)
Preparing to unpack elastic-agent-7.10.0-amd64.deb ...
Unpacking elastic-agent (7.10.0) ...
Setting up elastic-agent (7.10.0) ...
Processing triggers for systemd (241-7~deb10u4) ...
ffoti@ep-test-gcp-debian:~$ cd /usr/share/elastic-agent/bin
ffoti@ep-test-gcp-debian:/usr/share/elastic-agent/bin$
ffoti@ep-test-gcp-debian:/usr/share/elastic-agent/bin$
ffoti@ep-test-gcp-debian:/usr/share/elastic-agent/bin$ sudo ./elastic-agent install -f --kibana-url=https://2fadc60b34cf40479ee0bee875eeaab9.us-east4.gcp.elastic-cloud.com:443 --enrollment-token=Y1ZEN3ZYVUJDM28telBHWEpXZlo6WFlxYWlIRzBSQzZsTU9BNUVVV1oxUQ==
The Elastic Agent is currently in BETA and should not be used in production
Error: failed to discover the source directory for installation: missing elastic-agent