Skip to content

Commit 4fbf32d

Browse files
committed
rename serve to start
1 parent e6ad1bb commit 4fbf32d

File tree

3 files changed

+13
-13
lines changed

3 files changed

+13
-13
lines changed

.dagger/src/localstack_dagger_module/main.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
@object_type
1212
class LocalstackDaggerModule:
1313
@function
14-
def serve(
14+
def start(
1515
self,
1616
auth_token: Optional[dagger.Secret] = None,
1717
configuration: Optional[str] = None,
@@ -99,7 +99,7 @@ async def state(
9999
health_response = requests.get(f"{localstack_url}/_localstack/info")
100100
health_response.raise_for_status()
101101
except requests.RequestException:
102-
return "Error: LocalStack is not running. Please start it first using the serve function."
102+
return "Error: LocalStack is not running. Please start it first using the start function."
103103

104104
# Handle reset operation
105105
if reset:

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ This module uses Dagger's secret management system to handle sensitive data like
2828

2929
```bash
3030
export LOCALSTACK_AUTH_TOKEN=your-token-here
31-
dagger call serve --auth-token=env:LOCALSTACK_AUTH_TOKEN up
31+
dagger call start --auth-token=env:LOCALSTACK_AUTH_TOKEN up
3232
```
3333

3434
The token will be then securely handled by Dagger and never exposed in logs or command output.
@@ -44,14 +44,14 @@ The token will be then securely handled by Dagger and never exposed in logs or c
4444

4545
### Configuration
4646

47-
#### `serve`
47+
#### `start`
4848

4949
| Input | Description | Default | Example |
5050
|-------|-------------|---------|---------|
51-
| `auth-token` | LocalStack Pro auth token (as Dagger secret) | `None` | `dagger call serve --auth-token=env:LOCALSTACK_AUTH_TOKEN` |
52-
| `configuration` | Configuration variables for LocalStack container | `None` | `dagger call serve --configuration='DEBUG=1,PERSISTENCE=1'` |
53-
| `docker-sock` | Unix socket path for Docker daemon | `None` | `dagger call serve --docker-sock=/var/run/docker.sock` |
54-
| `image-name` | Custom LocalStack image name | `None` | `dagger call serve --image-name=localstack/snowflake:latest` |
51+
| `auth-token` | LocalStack Pro auth token (as Dagger secret) | `None` | `dagger call start --auth-token=env:LOCALSTACK_AUTH_TOKEN` |
52+
| `configuration` | Configuration variables for LocalStack container | `None` | `dagger call start --configuration='DEBUG=1,PERSISTENCE=1'` |
53+
| `docker-sock` | Unix socket path for Docker daemon | `None` | `dagger call start --docker-sock=/var/run/docker.sock` |
54+
| `image-name` | Custom LocalStack image name | `None` | `dagger call start --image-name=localstack/snowflake:latest` |
5555

5656
#### `state`
5757

@@ -79,7 +79,7 @@ The token will be then securely handled by Dagger and never exposed in logs or c
7979

8080
```bash
8181
# Basic start
82-
dagger call serve up
82+
dagger call start up
8383
```
8484

8585
### Start LocalStack Pro Edition
@@ -89,7 +89,7 @@ dagger call serve up
8989
export LOCALSTACK_AUTH_TOKEN=your-token-here
9090

9191
# Basic start with auth token from environment
92-
dagger call serve --auth-token=env:LOCALSTACK_AUTH_TOKEN up
92+
dagger call start --auth-token=env:LOCALSTACK_AUTH_TOKEN up
9393
```
9494

9595
## Development

tests/src/tests/main.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ async def all(self, auth_token: dagger.Secret) -> str:
2222
async def test_localstack_health(self) -> str:
2323
"""Test if LocalStack starts and responds to /_localstack/info endpoint"""
2424
# Start LocalStack using the module
25-
service = dag.localstack_dagger_module().serve()
25+
service = dag.localstack_dagger_module().start()
2626

2727
await service.start()
2828
endpoint = await service.endpoint()
@@ -47,7 +47,7 @@ async def test_localstack_health(self) -> str:
4747
async def test_localstack_pro(self, auth_token: dagger.Secret) -> str:
4848
"""Test if LocalStack starts with Pro services available"""
4949
# Start LocalStack Pro using the module
50-
service = dag.localstack_dagger_module().serve(auth_token=auth_token)
50+
service = dag.localstack_dagger_module().start(auth_token=auth_token)
5151

5252
await service.start()
5353
endpoint = await service.endpoint()
@@ -76,7 +76,7 @@ async def test_localstack_pro(self, auth_token: dagger.Secret) -> str:
7676
async def test_state_operations(self, auth_token: dagger.Secret) -> str:
7777
"""Test LocalStack state operations (save/load/reset) with AWS resources"""
7878
# Start LocalStack Pro
79-
service = dag.localstack_dagger_module().serve(auth_token=auth_token)
79+
service = dag.localstack_dagger_module().start(auth_token=auth_token)
8080
await service.start()
8181
endpoint = await service.endpoint()
8282

0 commit comments

Comments
 (0)