Skip to content
Open
Show file tree
Hide file tree
Changes from 18 commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
1859682
feat: add TLS configuration for proxy service in workspace.yml
marcomc Jun 17, 2026
c660f3d
feat: update proxy service configurations to use dynamic domain varia…
marcomc Jun 17, 2026
830868e
feat: simplify enable function in init scripts and add TLS configurat…
marcomc Jun 17, 2026
f82d195
feat: add tests for global proxy domain configuration and overrides
marcomc Jun 17, 2026
ee3ff1a
feat: add documentation for custom global proxy domain configuration
marcomc Jun 17, 2026
17dd727
feat: remove unused environment variables from proxy service command …
marcomc Jun 17, 2026
f3fa4b4
feat: add descriptions for logger and tracing service commands in glo…
marcomc Jun 17, 2026
bd2ecb2
feat: enhance create command with description and exec block formatting
marcomc Jun 17, 2026
29bcfa4
feat: update attribute source handling to use latest source and highe…
marcomc Jun 17, 2026
97804ec
feat: update offsetGet method to return mixed type and add test for a…
marcomc Jun 17, 2026
6582f60
feat: add MY127WS_PROXY_DOMAIN export in service init scripts and tes…
marcomc Jun 17, 2026
0241a4e
feat: add tracing service environment file to files-bin in box.json
marcomc Jun 17, 2026
e13be5a
feat: enhance global proxy configuration with environment variable su…
marcomc Jun 17, 2026
9a4bf43
feat: add TLS validation functions to ensure certificate and key file…
marcomc Jun 17, 2026
cac212c
feat: enhance global proxy service tests with TLS validation and erro…
marcomc Jun 17, 2026
3c7ac04
feat: update documentation for proxy configuration with HTTPS require…
marcomc Jun 17, 2026
283b292
feat: implement proxy environment population and update service initi…
marcomc Jun 18, 2026
adeb1b3
feat: update init script to use dynamic workspace binary reference fo…
marcomc Jun 18, 2026
1b9e48b
feat: enhance workspace binary reference handling and update proxy en…
marcomc Jun 18, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions bin/workspace
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ function main(): void
install();
}

putenv('MY127WS_WORKSPACE_BIN='.($_SERVER['argv'][0] ?? __FILE__));

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This gives internal service wrappers a deterministic way to call back into the same ws executable that launched the current command.

Without it, nested calls inside ws-service / service init scripts would fall back to resolving ws from PATH, which can pick a different installed version. That is especially risky during tests, local branch validation, or when multiple ws binaries exist on the machine.

putenv('PATH='.home().'/.my127/workspace/bin:'.getenv('PATH'));
$exitStatus = application()->run();

Expand Down
3 changes: 2 additions & 1 deletion box.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"files-bin": [
"home/service/logger/.env",
"home/service/mail/.env",
"home/service/proxy/.env"
"home/service/proxy/.env",
"home/service/tracing/.env"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

home/service/tracing/.env already exists in the source tree and is required by home/service/tracing/docker-compose.yml because Compose reads TRAEFIK_NETWORK from that file.

The phar packaging explicitly whitelists hidden .env files, but tracing was missing from that list. As a result, an installed ws could create ~/.my127/workspace/service/tracing/ without .env, causing ws global service tracing restart to fail with an empty TRAEFIK_NETWORK.

],
"blacklist": [
"tools/scripts/compile.sh",
Expand Down
20 changes: 12 additions & 8 deletions config/workspace/global.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,27 @@

command('global service logger (enable|disable)', 'global service logger'): |
#!bash|=
ws-service logger ={input.command(4)}
command('global service logger (enable|disable)', 'global service logger'):
description: Actions for the logging service
exec: |
#!bash|=
ws-service logger ={input.command(4)}

command('global service mail (enable|disable)', 'global service mail'):
description: Actions for mailhog (mail.my127.site)
description: Actions for mailhog
exec: |
#!bash|=
ws-service mail ={input.command(4)}

command('global service proxy (enable|disable|restart)', 'global service proxy'):
description: Actions for Traefik proxy (my127.site)
description: Actions for Traefik proxy
exec: |
#!bash|=
ws-service proxy ={input.command(4)}

command('global service tracing (start|stop|restart)', 'global service tracing'): |
#!bash|=
ws-service tracing ={input.command(4)}
command('global service tracing (start|stop|restart)', 'global service tracing'):
description: Actions for the tracing service
exec: |
#!bash|=
ws-service tracing ={input.command(4)}

command('global service', 'global service'):
description: Perform an action (start/stop etc.) on a global service
Expand Down
22 changes: 20 additions & 2 deletions docs/cheatsheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,24 @@ You need only to restart the Traefik proxy service:
ws global service proxy restart
```

## Custom proxy domain

See [Custom Global Proxy Domain](custom-proxy-domain.md) for the full setup.

Minimal global config file:

```text
~/.config/my127/workspace/proxy.yml
```

```yaml
attribute('global.service.proxy.domain'): dev.example.test
attribute('global.service.proxy.https.crt'): https://example.test/dev.example.test.crt
attribute('global.service.proxy.https.key'): https://example.test/dev.example.test.key
```

Restart the proxy after changing these values.

## How-to receive email

The email service is not running by default. It can be started with:
Expand All @@ -18,6 +36,6 @@ The email service is not running by default. It can be started with:
ws global service mail enable
```

This will allow email to be viewed at `https://mail.my127.site/`
This will allow email to be viewed at `https://mail.<proxy-domain>/`

This will collect email sent from any server through native `sendmail`.
This will collect email sent from any server through native `sendmail`.
Loading
Loading