Skip to content

Conversation

@codefromthecrypt
Copy link
Contributor

Description

This refactors aigw to use distinct directories following XDG Base Directory Specification conventions:

  • --config-home/$AIGW_CONFIG_HOME: Configuration files (default: ~/.config/aigw)
  • --data-home/$AIGW_DATA_HOME: Envoy binaries via func-e (default: ~/.local/share/aigw)
  • --state-home/$AIGW_STATE_HOME: Run logs and state (default: ~/.local/state/aigw)
  • --runtime-dir/$AIGW_RUNTIME_DIR: Ephemeral files like UDS (default: /tmp/aigw-${UID})

This separation aligns with XDG principles where configuration, data, state, and runtime files are independently configurable for different storage tiers. This is particularly useful for Docker deployments to map volumes appropriately.

This also adds --run-id/$AIGW_RUN_ID to override the default YYYYMMDD_HHMMSS_UUU timestamp format with a custom identifier. Setting this to '0' enables predictable paths for Docker/Kubernetes single-run scenarios.

Related Issues/PRs (if applicable)

once envoyproxy/gateway#7225 is merged we have some maintenance to remove the /tmp/envoy-gateway/certs tech debt

@codecov-commenter
Copy link

codecov-commenter commented Oct 14, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.64%. Comparing base (25cd552) to head (f4e5f70).

❌ Your project status has failed because the head coverage (78.64%) is below the target coverage (86.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1368   +/-   ##
=======================================
  Coverage   78.64%   78.64%           
=======================================
  Files         140      140           
  Lines       13789    13789           
=======================================
  Hits        10845    10845           
  Misses       2287     2287           
  Partials      657      657           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

**Description**

This refactors aigw to use distinct directories following XDG Base Directory
Specification conventions:

- --config-home/$AIGW_CONFIG_HOME: Configuration files (default: ~/.config/aigw)
- --data-home/$AIGW_DATA_HOME: Envoy binaries via func-e (default: ~/.local/share/aigw)
- --state-home/$AIGW_STATE_HOME: Run logs and state (default: ~/.local/state/aigw)
- --runtime-dir/$AIGW_RUNTIME_DIR: Ephemeral files like UDS (default: /tmp/aigw-${UID})

This separation aligns with XDG principles where configuration, data, state,
and runtime files are independently configurable for different storage tiers.
This is particularly useful for Docker deployments to map volumes appropriately.

This also adds --run-id/$AIGW_RUN_ID to override the default YYYYMMDD_HHMMSS_UUU
timestamp format with a custom identifier. Setting this to '0' enables predictable
paths for Docker/Kubernetes single-run scenarios.

Signed-off-by: Adrian Cole <[email protected]>
@mathetake mathetake self-assigned this Oct 23, 2025
# Conflicts:
#	cmd/aigw/main.go
#	cmd/aigw/main_test.go
Signed-off-by: Takeshi Yoneda <[email protected]>
@mathetake mathetake enabled auto-merge (squash) October 24, 2025 21:59
@mathetake mathetake merged commit 6604b49 into envoyproxy:main Oct 24, 2025
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants