SWE-agent takes a GitHub issue and tries to automatically fix it, using your LM of choice. It can also be employed for offensive cybersecurity or competitive coding challenges. [NeurIPS 2024]
Doc: Add more docker issue docs (#577)
Kilian Lieret9b8cdd774f93
diff --git a/docs/installation/docker.md b/docs/installation/docker.mdindex 482b5c44..986ead52 100644--- a/docs/installation/docker.md+++ b/docs/installation/docker.md@@ -2,7 +2,7 @@Instead of installing SWE-agent from source, you can also run the software directly using Docker.-1. Install Docker ([follow the docs](https://github.com/docker/docker-install) or use the [get-docker.sh script for linux](https://github.com/docker/docker-install)), then start Docker locally.+1. Install Docker ([follow the docs](https://github.com/docker/docker-install) or use the [get-docker.sh script for linux](https://github.com/docker/docker-install)), then start Docker locally. Problems? See [docker issues](tips.md#docker).2. Run `docker pull sweagent/swe-agent:latest`3. Add your API tokens to a file `keys.cfg` as explained [here](keys.md) or pass them asenvironment variables.@@ -34,7 +34,7 @@ docker run --rm -it -v /var/run/docker.sock:/var/run/docker.sock \(double slash) to escape it ([more information](https://stackoverflow.com/a/47229180/)).!!! tip "More tips"- See the [installation issues section](tips.md) for more help if you run into+ See the [docker issues section](tips.md#docker) for more help if you run intotrouble.If you instead want to pass the keys as environment variables, usediff --git a/docs/installation/source.md b/docs/installation/source.mdindex 5cb6a33d..33efeef6 100644--- a/docs/installation/source.md+++ b/docs/installation/source.md@@ -6,7 +6,7 @@ Installation from source is the preferred way to set up SWE-agent on your machinExpect some issues with Windows (we're working on them).In the meantime, [use Docker](docker.md).-1. Install Docker ([follow the docs](https://github.com/docker/docker-install) or use the [get-docker.sh script for linux](https://github.com/docker/docker-install)), then start Docker locally.+1. Install Docker ([follow the docs](https://github.com/docker/docker-install) or use the [get-docker.sh script for linux](https://github.com/docker/docker-install)), then start Docker locally. Problems? See [docker issues](tips.md#docker).2. If you plan on using the web-based GUI: Install [`nodejs`][nodejs-install].3. Clone the repository, for example with```bash@@ -21,7 +21,7 @@ Installation from source is the preferred way to set up SWE-agent on your machin```bashdocker pull sweagent/swe-agent:latest```- Alternatively, you can run `./setup.sh` to create your own `swe-agent` docker image.+ Errors? See [docker issues](tips.md#docker). Alternatively, you can run `./setup.sh` to create your own `swe-agent` docker image.6. Set up your LM API keys as explained [here](keys.md).[nodejs-install]: https://docs.npmjs.com/downloading-and-installing-node-js-and-npmdiff --git a/docs/installation/tips.md b/docs/installation/tips.mdindex 73b8e0ba..6a09ea86 100644--- a/docs/installation/tips.md+++ b/docs/installation/tips.md@@ -1,11 +1,25 @@# More installation tips-If you seem to be having issues with running docker+## Docker issues <a name="docker"></a>-* Make sure that you allow the use of the Docker socket. In Docker desktop, click *Settings* > *Advanced* > *Allow the default Docker socket to be used (requires password)*+First, test if you can use docker in general, for example by running++```bash+docker run hello-world+```++If you get an error like++```+docker: permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Head "http://%2Fvar%2Frun%2Fdocker.sock/_ping": dial unix /var/run/docker.sock: connect: permission denied.+```++* Make sure that you allow the use of the Docker socket. In Docker desktop, click *Settings* > *Advanced* > *Allow the default Docker socket to be used (requires password)*.+* On the command line, you can try `sudo chmod 666 /var/run/docker.sock` or add your user to the `docker` linux user group* If your docker installation uses a different socket, you might have to symlink them, see [this command for example](https://github.com/princeton-nlp/SWE-agent/issues/20#issuecomment-2047506005)-* If you are using any containers from dockerhub (i.e., you ran `docker pull ...` or you are running `docker run ...`), please make sure that you are using the latest- versions. Just because an image has the `latest` tag (e.g., `sweagent/swe-agent-run:latest`) does not mean that it will auto-update. Please run- `docker pull sweagent/swe-agent-run:latest` to make sure you actually have the most recent version!++If you are using any containers from dockerhub (i.e., you ran `docker pull ...` or you are running `docker run ...`), please make sure that you are using the latest+versions. Just because an image has the `latest` tag (e.g., `sweagent/swe-agent-run:latest`) does not mean that it will auto-update. Please run+`docker pull sweagent/swe-agent-run:latest` to make sure you actually have the most recent version!Any remaining issues? Please [open a GitHub issue](https://github.com/princeton-nlp/SWE-agent/issues/new/choose)!