# configure the shop’s apps

Use the [shop starter](/docs/quickstart/) as the working repository. Keep the API listening on `process.env.PORT` at `127.0.0.1`. In `antil.yaml`, configure the two services:

```yaml
version: 1
project: shop
services:
  api:
    command: [node, api/server.mjs]
    port: {env: PORT}
    env:
      DATABASE_URL: {resource: db, output: url}
      REDIS_URL: {secret: .antil/redis-url}
    ready: {http: {path: /health}}
  web:
    command: [bun, node_modules/vite/bin/vite.js, --host, 127.0.0.1, --port, "${port}", --strictPort]
    port: {env: PORT}
    depends_on: [api]
    env:
      API_URL: "http://127.0.0.1:${services.api.port}"
    ready: {http: {path: /}}
```

The Vite configuration in the starter forwards `/api` to `process.env.API_URL`. Keep `--strictPort`: a port collision should fail rather than silently pick another address.

Inspect the effective settings:

```sh
antil config explain services.web --json
```

After editing a running worker's config, end and start that worker to use it:

```sh
antil session end
antil session start --json
```

Check `data.services.api.state` and `data.services.web.state` are `ready`. If either fails, inspect its returned log. For every accepted field, see [configuration](/docs/reference/configuration/).
