My engineering team has created a suite of CLI tools that can create users, interact with APIs, modify data, etc. It’s basically a CLI interface on top of our business logic.<p>It became so useful for testing purposes that I started using it for day-to-day operations. When ops makes a request, I SSH into our production environment (running in a secure EC2 instance) and run the CLI.<p>We use Retool for internal tools, but it’s become way faster to iterate on this terminal than to iterate on a UI, write the APIs, and maintain both the Retool and terminal app.<p>I’d like to expose this terminal application behind our private company VPN to specific team members in a controlled way. Really what I want is AWS CloudShell, and I want it to only run that specific script.<p>Is there a way to do this using open source tools?
I'm not 100% sure of the ask but I think Teleport can do this sort of thing. <a href="https://goteleport.com/docs/" rel="nofollow">https://goteleport.com/docs/</a><p>also -<p>AWS has AWS Systems Manager. Any system can run AWS SSM agent and SSM Documents define scripts that can be run on machines running SSM agent. On demand or scheduled, with some dynamic inputs etc.
Users can ssh but the server admin can limit which commands they're able to run by setting a different shell command, e.g. <a href="https://www.linuxshelltips.com/restrict-ssh-user-commands/" rel="nofollow">https://www.linuxshelltips.com/restrict-ssh-user-commands/</a><p>So you could instruct users to run "ssh me@cli-server.internal 'cli-command --param1 --param2'" without them having extra access to the server.<p>That said even in school it was a fun game trying to get around such limitations, e.g. trying to crash the script to get shell access.
I'm also not quite sure about the ask, but if you want to have a runbook or documentation that authorizes specific GitHub users/teams/orgs, prompts them for inputs and builds the exact commands they need to run, optionally with scoped temporary AWS credentials, you might check out Speedrun. <a href="https://speedrun.nobackspacecrew.com" rel="nofollow">https://speedrun.nobackspacecrew.com</a>