feat: add telemetry collection functionality

This commit is contained in:
dido committed 2026-09-24 14:54:17 +03:00
1 parent 5141bcdb0f
commit 5a285ab1a6
10 files changed
+412 -5

No files matched your search

+3
View File
@@ -19,7 +19,10 @@ services:
# Session Recording Configuration
- RECORDING_ENABLED=true
- RECORDING_RETENTION_DAYS=30
- STRIX_TELEMETRY_ENABLED=${STRIX_TELEMETRY_ENABLED:-true}
# Security hardening
extra_hosts:
- "host.docker.internal:host-gateway"
security_opt:
- no-new-privileges:true
tmpfs:
+1 -1
View File
@@ -7,7 +7,7 @@ set -e
# Configuration
IMAGE_NAME="danaildr/webssh"
VERSION="0.4.5"
VERSION="0.5.0"
PLATFORMS="linux/amd64,linux/arm64,linux/arm/v7"
# Colors
+20 -2
View File
@@ -8,6 +8,7 @@ set -e
# Configuration
ROOT_DIR="$(cd "$(dirname "$0")/../.." && pwd)"
VERSION_FILE="$ROOT_DIR/src/help.html"
PACKAGE_VERSION_FILE="$ROOT_DIR/src/webssh_backend/__init__.py"
BUILD_SCRIPT="$ROOT_DIR/deployment/scripts/docker-build-and-push.sh"
GITHUB_WORKFLOW="$ROOT_DIR/.github/workflows/build-and-publish.yml"
@@ -23,13 +24,21 @@ echo -e "${BLUE}=================================${NC}"
# Function to get current version
get_current_version() {
if [[ -f "$VERSION_FILE" ]]; then
grep -o 'WebSSH Multi-Connection Terminal v' "$VERSION_FILE" | sed 's/.*v\([0-9.]\+\).*/\1/'
if [[ -f "$PACKAGE_VERSION_FILE" ]]; then
sed -n 's/^__version__ = "\([0-9.]\+\)"$/\1/p' "$PACKAGE_VERSION_FILE"
else
echo "0.0.0"
fi
}
# Function to update the package version
update_package_version() {
local new_version=$1
echo -e "${GREEN}📦 Updating $PACKAGE_VERSION_FILE to v$new_version${NC}"
sed -i "s/^__version__ = \"[0-9.]\+\"$/__version__ = \"$new_version\"/" "$PACKAGE_VERSION_FILE"
echo -e "${GREEN}✅ $PACKAGE_VERSION_FILE updated to v$new_version${NC}"
}
# Function to update version in help.html
update_help_version() {
local new_version=$1
@@ -121,6 +130,7 @@ main() {
read -p "Enter new version (X.Y.Z): " new_version
if validate_version "$new_version"; then
update_help_version "$new_version"
update_package_version "$new_version"
update_build_version "$new_version"
update_github_workflow "$new_version"
update_dockerfile_version "$new_version"
@@ -135,6 +145,7 @@ main() {
patch=$((${BASH_REMATCH[3]} + 1))
new_version="${major}.${minor}.${patch}"
update_help_version "$new_version"
update_package_version "$new_version"
update_build_version "$new_version"
update_github_workflow "$new_version"
update_dockerfile_version "$new_version"
@@ -151,6 +162,7 @@ main() {
patch=0
new_version="${major}.${minor}.${patch}"
update_help_version "$new_version"
update_package_version "$new_version"
update_build_version "$new_version"
update_github_workflow "$new_version"
update_dockerfile_version "$new_version"
@@ -167,6 +179,7 @@ main() {
patch=0
new_version="${major}.${minor}.${patch}"
update_help_version "$new_version"
update_package_version "$new_version"
update_build_version "$new_version"
update_github_workflow "$new_version"
update_dockerfile_version "$new_version"
@@ -198,6 +211,11 @@ if [[ ! -f "$VERSION_FILE" ]]; then
exit 1
fi
if [[ ! -f "$PACKAGE_VERSION_FILE" ]]; then
echo -e "${RED}❌ $PACKAGE_VERSION_FILE not found${NC}"
exit 1
fi
if [[ ! -f "$BUILD_SCRIPT" ]]; then
echo -e "${RED}❌ $BUILD_SCRIPT not found${NC}"
exit 1