diff --git a/.github/workflows/docker-image-verify.yml b/.github/workflows/docker-image-verify.yml index a2825d52..9a9ad057 100644 --- a/.github/workflows/docker-image-verify.yml +++ b/.github/workflows/docker-image-verify.yml @@ -108,7 +108,9 @@ jobs: # Same Compose project name as the step above; stop that stack first. docker compose -f deployment/docker-compose-standalone.yaml down -v pipx run build --wheel --outdir "$RUNNER_TEMP/dist" - export DOCSGPT_PACKAGE="$(ls "$RUNNER_TEMP"/dist/docsgpt-*.whl)" + # Assigned before export, so a missing wheel fails here instead of installing from PyPI. + DOCSGPT_PACKAGE="$(ls "$RUNNER_TEMP"/dist/docsgpt-*.whl)" + export DOCSGPT_PACKAGE # No uv is set up beforehand, so the installer's pinned uv download runs too. # Without a terminal the installer passes --yes to docsgpt up. bash deployment/install.sh --image-tag verify "$script"; then + rm -f "$script" + die "could not download $url" + fi + "$@" "$script" || status=$? + rm -f "$script" + return "$status" + } # version_ge A B: A >= B for dotted version numbers. version_ge() { local -a left right @@ -82,7 +96,7 @@ main() { sudo="sudo" fi say "Installing Docker" - download https://get.docker.com | $sudo sh + run_downloaded https://get.docker.com $sudo sh $sudo systemctl enable --now docker >/dev/null 2>&1 || true if [ -n "$sudo" ]; then $sudo usermod -aG docker "$(id -un)" @@ -108,7 +122,7 @@ main() { if [ -z "$uv" ]; then local uv_dir="${XDG_BIN_HOME:-$HOME/.local/bin}" say "Installing uv $UV_VERSION into $uv_dir" - download "https://astral.sh/uv/$UV_VERSION/install.sh" | env UV_INSTALL_DIR="$uv_dir" UV_NO_MODIFY_PATH=1 UV_PRINT_QUIET=1 sh + run_downloaded "https://astral.sh/uv/$UV_VERSION/install.sh" env UV_INSTALL_DIR="$uv_dir" UV_NO_MODIFY_PATH=1 UV_PRINT_QUIET=1 sh uv="$uv_dir/uv" [ -x "$uv" ] || die "uv did not install into $uv_dir" fi @@ -117,7 +131,7 @@ main() { die "set DOCSGPT_VERSION or DOCSGPT_PACKAGE, not both" fi if [ -n "${DOCSGPT_PACKAGE:-}" ]; then - say "Installing docsgpt from $DOCSGPT_PACKAGE" + say "Installing docsgpt from DOCSGPT_PACKAGE" "$uv" tool install --reinstall --python 3.12 "$DOCSGPT_PACKAGE" elif [ -n "${DOCSGPT_VERSION:-}" ]; then say "Installing docsgpt $DOCSGPT_VERSION" diff --git a/docs/content/Deploying/Docker-Deploying.mdx b/docs/content/Deploying/Docker-Deploying.mdx index 400c0207..b4c5f87f 100644 --- a/docs/content/Deploying/Docker-Deploying.mdx +++ b/docs/content/Deploying/Docker-Deploying.mdx @@ -24,9 +24,16 @@ you. It needs Docker with Compose 2.24 or newer. The installer gets [uv](https://docs.astral.sh/uv/), installs the package with it and runs `docsgpt up`: +macOS and Linux: + ```bash -curl -fsSL https://docs.ac/install | bash # macOS and Linux -irm https://docs.ac/install.ps1 | iex # Windows (PowerShell) +curl -fsSL https://docs.ac/install | bash +``` + +Windows (PowerShell): + +```powershell +irm https://docs.ac/install.ps1 | iex ``` Both scripts are attached to every [release](https://github.com/arc53/DocsGPT/releases) diff --git a/docs/content/quickstart.mdx b/docs/content/quickstart.mdx index 63917cfb..3b134fe6 100644 --- a/docs/content/quickstart.mdx +++ b/docs/content/quickstart.mdx @@ -34,7 +34,7 @@ The installer: * **Who should reach DocsGPT:** only this computer; other machines on your network (plain HTTP, with an access token); or a domain name with HTTPS (a certificate from Let's Encrypt, with an access token). * **Which model provider:** the DocsGPT public API (no key needed), OpenAI, Anthropic, Google Gemini, OpenRouter, Groq, or an OpenAI-compatible server such as Ollama or vLLM. -It then starts DocsGPT and prints its address, [http://localhost:7091](http://localhost:7091) for a local install. Settings and generated secrets are in `~/.docsgpt/server/.env`. +It then starts DocsGPT and prints its address, [http://localhost:7091](http://localhost:7091) for a local install. Settings and generated secrets are in `~/.docsgpt/server/.env`, or `/opt/docsgpt/.env` when the installer runs as root on Linux; `docsgpt up --dir` or `DOCSGPT_HOME` choose another folder. To read the script before running it, download it first: `curl -fsSL https://docs.ac/install -o install.sh`, then `bash install.sh`. On Windows: `irm https://docs.ac/install.ps1 -OutFile install.ps1`, then `.\install.ps1`.