From 21ac0eb4f84d90d06d50c0e89830663c01cea05a Mon Sep 17 00:00:00 2001 From: Alessandro Arzilli Date: Mon, 3 Jun 2019 19:20:26 +0200 Subject: [PATCH] Documentation: add Frequently Asked Questions. (#1567) --- Documentation/faq.md | 41 +++++++++++++++++++++++++++++++++++++++++ README.md | 1 + 2 files changed, 42 insertions(+) create mode 100644 Documentation/faq.md diff --git a/Documentation/faq.md b/Documentation/faq.md new file mode 100644 index 00000000..e87c1c88 --- /dev/null +++ b/Documentation/faq.md @@ -0,0 +1,41 @@ +## Frequently Asked Questions + +#### I'm getting an error while compiling Delve / unsupported architectures and OSs + +The most likely cause of this is that you are running an unsupported Operating System or architecture. +Currently Delve supports Linux, Windows and macOS on the amd64 architecture (also known as Intel 86x64). + +For example if you are getting the `undefined: ArchInst` error message while compiling Delve, that means that Delve doesn't currently support your processor architecture. + +There is no planned ETA for support of other architectures or operating systems. Bugs tracking requested support are: + +- [i386 support](https://github.com/go-delve/delve/issues/20) +- [ARM support](https://github.com/go-delve/delve/issues/118) +- [PowerPC support](https://github.com/go-delve/delve/issues/1564) +- [FreeBSD support](https://github.com/go-delve/delve/issues/213) + +#### How do I use Delve with Docker? + +When running the container you should pass the `--security-opt=seccomp:unconfined` option to Docker. You can start a headless instance of Delve inside the container like this: + +``` +dlv exec --headless --listen :4040 /path/to/executable +``` + +And then connect to it from outside the container: + +``` +dlv connect :4040 +``` + +The program will not start executing until you connect to Delve and send the `continue` command. If you want the program to start immediately you can do that by: + +1. Passing the `--accept-multiclient` option to the headless instance of delve: `dlv exec --headless --listen :4040 --accept-multiclient /path/to/executable` +2. Using the following script: + +``` +#!/bin/bash +while true; do sleep 1; dlv connect :4040 --init <(echo quit -c) && exit; done +``` + +Note that the connection to Delve is unauthenticated and will allow arbitrary remote code execution: *do not do this in production*. diff --git a/README.md b/README.md index 5a3093ae..80287a69 100644 --- a/README.md +++ b/README.md @@ -19,6 +19,7 @@ The GitHub issue tracker is for **bugs** only. Please use the [developer mailing - [Command line options](Documentation/usage/dlv.md) - [Command line client](Documentation/cli/README.md) - [Plugins and GUIs](Documentation/EditorIntegration.md) + - [Frequently Asked Questions](Documentation/faq.md) - [Contributing](CONTRIBUTING.md) - [Internal Documentation](Documentation/internal) - [API documentation](Documentation/api)