fix: remove unused variables and ignore certs/README.md when build image

This commit is contained in:
Ian
2026-10-05 08:50:12 +02:00
parent 3bb88ec54e
commit 754fa84a5e
4 changed files with 4 additions and 13 deletions
+2 -1
View File
@@ -1,4 +1,5 @@
.git
.gitignore
README.md
*.log
README.md
certs/README.md
+1 -1
View File
@@ -11,7 +11,7 @@ IMAGE="${IMAGE_REPO:-localhost/opencode-dev}"
usage() {
echo 'Usage: $0 [--no-cache] [--update] [--dry-run] [--remove] [--prune] [--apt-packages="pack1 pack2"]'
exit 2
exit 0
}
BUILD_OPTS=()
+1 -2
View File
@@ -50,8 +50,7 @@ so both system tools and Node.js applications trust the added certificates.
* Only **public** CA certificates belong here. Never commit private material
(`*.key`, `*.p12`, `*.pfx`) — everything matched here is copied into the image
verbatim. The `.gitignore` in this directory blocks those extensions, but it
is a safety net, not a guarantee.
verbatim.
* Files must be PEM encoded. Convert DER with:
```bash
-9
View File
@@ -1,8 +1,6 @@
#!/usr/bin/env bash
set -euo pipefail
SCRIPT_DIR=$(realpath -- "$(dirname -- "${BASH_SOURCE[0]}")")
IMAGE_REPO="${IMAGE_REPO:-localhost/opencode-dev}"
IMAGE="${IMAGE_REPO}"
@@ -18,15 +16,9 @@ OPC_CONFIG="${OPENCODE_CONFIG:-$BASE_DIR/opencode-config}"
OPC_DATA="${OPENCODE_SHARE_DATA:-$BASE_DIR/opencode-data}"
OPC_CACHE="${OPENCODE_CACHE:-$BASE_DIR/opencode-cache}"
M2_FOLDER="${M2_FOLDER:-$BASE_DIR/m2}"
NPM_MODULES="${NPM_MODULES:-$BASE_DIR/npm-modules}"
NPM_CACHE="${NPM_CACHE:-$BASE_DIR/npm-cache}"
PIP_CACHE="${PIP_CACHE:-$BASE_DIR/pip-cache}"
if [[ ! -d "$PROJECTS_DIR" ]]; then
echo "Project directory missing: $PROJECTS_DIR" >&2
exit 1
fi
mkdir -p \
"$BASE_DIR" \
"$PROJECTS_DIR" \
@@ -34,7 +26,6 @@ mkdir -p \
"$OPC_DATA" \
"$OPC_CACHE" \
"$M2_FOLDER" \
"$NPM_MODULES" \
"$NPM_CACHE" \
"$PIP_CACHE"