diff --git a/.github/dependabot.yml b/.github/dependabot.yml index a3ea771e73..447042ef44 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -107,7 +107,7 @@ updates: rebase-strategy: disabled - package-ecosystem: pip directories: - - / + - /docs-site schedule: interval: monthly day: sunday diff --git a/Makefile b/Makefile index 5b7c500015..f98c6386c9 100644 --- a/Makefile +++ b/Makefile @@ -36,7 +36,7 @@ serve-docs: docker run --rm --name $(DOCS_CONTAINER) -it -p 8000:8000 \ -v $(PWD):/testcontainers-go \ -w /testcontainers-go \ - $(DOCS_IMAGE) bash -c "pip install -Ur requirements.txt && mkdocs serve -f mkdocs.yml -a 0.0.0.0:8000" + $(DOCS_IMAGE) bash -c "pip install -Ur docs-site/requirements.txt && mkdocs serve -f mkdocs.yml -a 0.0.0.0:8000" ## -------------------------------------- diff --git a/Pipfile b/docs-site/Pipfile similarity index 100% rename from Pipfile rename to docs-site/Pipfile diff --git a/Pipfile.lock b/docs-site/Pipfile.lock similarity index 100% rename from Pipfile.lock rename to docs-site/Pipfile.lock diff --git a/docs-site/go.mod b/docs-site/go.mod new file mode 100644 index 0000000000..fc4a8adfdc --- /dev/null +++ b/docs-site/go.mod @@ -0,0 +1,8 @@ +// This module only exists to keep the Python tooling used to build the docs site +// (https://golang.testcontainers.org) out of the github.com/testcontainers/testcontainers-go +// module: the Go toolchain excludes any directory containing a go.mod file from the parent +// module's zip, so these files no longer land in users' module caches and vendor directories, +// where they were picked up by dependency scanners. It contains no Go code and is never released. +module github.com/testcontainers/testcontainers-go/docs-site + +go 1.26.0 diff --git a/requirements.txt b/docs-site/requirements.txt similarity index 100% rename from requirements.txt rename to docs-site/requirements.txt diff --git a/netlify.toml b/netlify.toml new file mode 100644 index 0000000000..2ff2276975 --- /dev/null +++ b/netlify.toml @@ -0,0 +1,8 @@ +# Netlify build configuration for the docs site (https://golang.testcontainers.org). +# The Python dependencies live in docs-site, so that they are not part of the Go module. +[build] + command = "pip install -r docs-site/requirements.txt && mkdocs build" + publish = "site" + +[build.environment] + PYTHON_VERSION = "3.13" diff --git a/runtime.txt b/runtime.txt deleted file mode 100644 index 24ee5b1be9..0000000000 --- a/runtime.txt +++ /dev/null @@ -1 +0,0 @@ -3.13 diff --git a/scripts/changed-modules.sh b/scripts/changed-modules.sh index a3db8a6a99..f41a40dec1 100755 --- a/scripts/changed-modules.sh +++ b/scripts/changed-modules.sh @@ -71,7 +71,7 @@ set -euxo pipefail readonly ROOT_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd) # define an array of modules that won't be included in the list -readonly excluded_modules=(".devcontainer" ".vscode" "docs") +readonly excluded_modules=(".devcontainer" ".vscode" "docs" "docs-site") # define an array of files that won't be included in the list readonly excluded_files=( @@ -96,11 +96,9 @@ readonly excluded_files=( "CONTRIBUTING.md" "LICENSE" "mkdocs.yml" - "Pipfile*" + "netlify.toml" "README.md" "RELEASING.md" - "requirements.txt" - "runtime.txt" "docs/usage-metrics/core.csv" "docs/usage-metrics/modules.csv" "docs/usage-metrics/clones.csv"