{"id":17596121,"url":"https://github.com/fyko/run.sh","last_synced_at":"2025-08-03T04:09:38.433Z","repository":{"id":258426108,"uuid":"868283287","full_name":"Fyko/run.sh","owner":"Fyko","description":"Execute sandboxed code on Discord","archived":false,"fork":false,"pushed_at":"2024-10-16T23:42:34.000Z","size":128,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-27T17:04:48.409Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Fyko.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-06T00:47:06.000Z","updated_at":"2024-10-26T06:27:41.000Z","dependencies_parsed_at":"2024-10-19T00:11:18.317Z","dependency_job_id":null,"html_url":"https://github.com/Fyko/run.sh","commit_stats":null,"previous_names":["fyko/run.sh"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fyko%2Frun.sh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fyko%2Frun.sh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fyko%2Frun.sh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fyko%2Frun.sh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Fyko","download_url":"https://codeload.github.com/Fyko/run.sh/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246237429,"owners_count":20745348,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-22T08:08:01.442Z","updated_at":"2025-03-29T19:43:23.975Z","avatar_url":"https://github.com/Fyko.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# run.sh\n\n\u003e Execute sandboxed code on Discord\n\n[Invite](https://discord.com/oauth2/authorize?client_id=1044442383288389692)\n\n## Want a new language?\n\nCreate a [language request](https://github.com/Fyko/run.sh/issues/new?assignees=\u0026labels=\u0026template=feature_request.yml\u0026title=).\n\n## Development\n\n1. Copy `.env.example` to `.envrc` and fill in the values.\n2. Install [sqlx-cli] via `cargo`.\n3. Run `sqlx db create` to create the database.\n4. Run `sqlx migrate run` to create the database schema.\n5. Run `cargo run` to start the bot. (optionally use `cargo make dev` to run with hot reloading)\n\n## Development (tcp server)\n\nIf you're developing a new language and don't want to run the bot, you can run the tcp server with `cargo run --bin tcp` and connect with `nc localhost 8080`.\n\nThe .env file requirements are the same except DISCORD_TOKEN can be any random string.\n\n[sqlx-cli]: https://github.com/launchbadge/sqlx/tree/main/sqlx-cli\n\n# Deployment (Linux only)\n\nYou have to [install](https://gvisor.dev/docs/user_guide/docker/) [gVisor](https://github.com/google/gvisor) as a runtime for docker to provide an additional isolation boundary between the containers and the host kernel.\n\n```sh\n# source https://gvisor.dev/docs/user_guide/install/#install-latest\n(\n  set -e\n  ARCH=$(uname -m)\n  URL=https://storage.googleapis.com/gvisor/releases/release/latest/${ARCH}\n  wget ${URL}/runsc ${URL}/runsc.sha512 \\\n    ${URL}/containerd-shim-runsc-v1 ${URL}/containerd-shim-runsc-v1.sha512\n  sha512sum -c runsc.sha512 \\\n    -c containerd-shim-runsc-v1.sha512\n  rm -f *.sha512\n  chmod a+rx runsc containerd-shim-runsc-v1\n  sudo mv runsc containerd-shim-runsc-v1 /usr/local/bin\n  sudo /usr/local/bin/runsc install\n  sudo systemctl reload docker\n)\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffyko%2Frun.sh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffyko%2Frun.sh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffyko%2Frun.sh/lists"}