# Basic Setup

Simple infrastructure setup examples for getting started with the Provisioning platform.

## Single Server Deployment

Deploy a simple web server with UpCloud:

```nickel
# workspace/infra/web-server.ncl
{
  servers = [
    {
      name = "web-01",
      provider = 'upcloud,
      plan = 'medium,
      zone = "fi-hel1",
      storage = [
        {size_gb = 50, type = 'ssd}
      ]
    }
  ]
}
```

Deploy:

```bash
provisioning workspace create basic-web
cd basic-web
cp ../examples/web-server.ncl infra/

provisioning deploy --workspace basic-web --yes
```

## Three-Tier Application

Web frontend, application backend, database:

```nickel
{
  servers = [
    {name = "web-01", provider = 'upcloud, plan = 'small, zone = "fi-hel1"},
    {name = "app-01", provider = 'upcloud, plan = 'medium, zone = "fi-hel1"},
    {name = "db-01", provider = 'upcloud, plan = 'large, zone = "fi-hel1",
     storage = [{size_gb = 100, type = 'ssd}]},
  ],

  task_services = [
    {name = "nginx", target = "web-01"},
    {name = "nodejs", target = "app-01"},
    {name = "postgresql", target = "db-01"},
  ]
}
```

## Development Environment

Local development stack with Docker:

```nickel
{
  servers = [
    {name = "dev-local", provider = 'local, plan = 'medium}
  ],

  task_services = [
    {name = "docker"},
    {name = "postgresql"},
    {name = "redis"},
  ]
}
```

## References

- [Quick Start](../getting-started/quick-start.md)
- [First Deployment](../getting-started/first-deployment.md)
