ACL and access rule samples

This article provides sample ACLs and access rules for common scenarios. For information about the syntax, see Tailscale policy syntax.

Allow all (default ACL)

When you first create your Tailscale network, it gets initialized with a default “allow all” access policy. This makes it easy to connect to and use Tailscale, and does not restrict any traffic in your network.

What this ACL does:

  • All devices signed into the network can access all other devices
  • All users can establish a Tailscale SSH session to their own devices using check mode, as either root or non-root

If you have a subnet router initialized with --snat-subnet-routes=false, then any devices on the same local network as the subnet router can also access all devices on the tailnet.

If you have a device shared from another network in your network, then that device cannot access any devices on the tailnet. The device can only respond to incoming connections from the network.

{
  "acls": [
    // Allow all connections.
    { "action": "accept", "src": ["*"], "dst": ["*:*"] },
  ],
  "ssh": [
    // Allow all users to SSH into their own devices in check mode.
    {
      "action": "check",
      "src": ["autogroup:member"],
      "dst": ["autogroup:self"],
      "users": ["autogroup:nonroot", "root"]
    }
  ]
}

Important note about autogroup:nonroot

In the default ACL, the ssh rule uses autogroup:self for the dst field and autogroup:nonroot in the users field. If you change the dst field from autogroup:self to some other destination, such as an ACL tag, also consider replacing autogroup:nonroot in the users field. If you don't remove autogroup:nonroot from the users field, then anyone permitted by the src setting will be able to SSH in as any nonroot user on the dst device.

Resource-level access policies

You can enable connectivity from one device or network to another using their IP addresses. Additionally, the hosts section lets you define a human-friendly name for an IP address or CIDR range, to make access rules more readable.

This example is possible with all plans.

What this ACL does:

  • Device with IP 100.3.4.5 can access device with IP 100.101.102.103
  • Device with IP 100.3.4.5 can access devices in the subnet 10.0.0.0/16 via a subnet router
  • Named host example-host-1 can access devices in the subnet 10.0.0.0/16
  • Named host example-host-1 can access named host example-network-1
{
  "acls": [
    // 100.3.4.5 can access 100.101.102.103
    { "action": "accept", "src": ["100.3.4.5"], "dst": ["100.101.102.103:*"] },
    // 100.3.4.5 can access devices in the subnet 10.0.0.0/16
    { "action": "accept", "src": ["100.3.4.5"], "dst": ["10.0.0.0/16:*"] },
    // named host example-host-1 can access devices in the subnet 10.0.0.0/16
    { "action": "accept", "src": ["example-host-1"], "dst": ["10.0.0.0/16:*"] },
    // named host example-host-1 can access named host example-network-1
    { "action": "accept", "src": ["example-host-1"], "dst": ["example-network-1:*"] },
  ],
  // Readable shorthands for devices and networks.
  "hosts": {
    "example-host-1": "100.101.102.103",
    "example-network-1": "10.0.0.0/24",
  },
}

Restrict based on purpose (ACL tags)

Tags let you assign an identity to a device that is separate from human users, and use that identity as part of an ACL to restrict access. Tags should be used when adding servers to your Tailscale network, so that their access is based on their purpose, not based on which member of your operations team enrolled them.

This example is possible with all plans.

What this ACL does:

  • Devices tagged tag:frontend can access devices tagged tag:backend
  • Devices tagged tag:backend can access devices tagged tag:logging
{
  "acls": [
    // devices tagged tag:frontend can access devices tagged tag:backend
    { "action": "accept", "src": ["tag:frontend"], "dst": ["tag:backend:*"] }
    // devices tagged tag:backend can access devices tagged tag:logging
    { "action": "accept", "src": ["tag:backend"], "dst": ["tag:logging:*"] },
  ],
}

Restrict based on group

You can enable access to resources on your tailnet with autogroups, custom groups, or groups provisioned from supported identity providers.

With autogroups

Autogroups are built-in groups that automatically include users, destinations, or usernames with the same properties.

This example is possible with all plans.

What this ACL does:

  • All tailnet members autogroup:member can access devices tagged tag:frontend
  • All Tailscale admins autogroup:admin can access devices tagged tag:backend or tag:logging
{
  "acls": [
    //
    // all tailnet members can access devices tagged tag:fontend
    { "action": "accept", "src": ["autogroup:member"], "dst": ["tag:frontend:*"] }
    // all Tailscale admins can access devices tagged tag:prod
    { "action": "accept", "src": ["autogroup:admin"], "dst": ["tag:backend:*", "tag:logging:*"] },
  ],
}

With custom groups

Custom groups let you define a shorthand for a group of users, which you can then use in access rules instead of listing users out explicitly.

This example is possible with the Personal, Premium, and Enterprise plans.

What this ACL does:

  • The Engineering team group:engineering consists of alice@example.com and bob@example.com
  • The DevOps team group:engineering consists of amelie@example.com and carl@example.com
  • The Engineering team group:engineering can access devices tagged tag:frontend or tag:backend
  • The DevOps team group:devops can access devices tagged tag:frontend or tag:backend or tag:logging
{
  "groups": {
    // Alice and Bob are in group:engineering
    "group:engineering": ["alice@example.com", "bob@example.com"],
    // Amelie and Carl are in group:devops
    "group:devops": ["amelie@example.com", "carl@example.com"],
  },
  "acls": [
    // users in group:engineering can access devices tagged tag:frontend or tag:backend
    { "action": "accept", "src": ["group:engineering"], "dst": ["tag:frontend:*", "tag:backend:*"] },
    // users in group:devops can access devices tagged tag:frontend or tag:backend or tag:logging
    { "action": "accept", "src": ["group:devops"], "dst": ["tag:frontend:*", "tag:backend:*", "tag:logging:*"] },
  ],
}

With provisioned groups

You can use group provisioning from supported identity providers and avoid maintaining custom groups in your ACLs.

{
  "acls": [
    // users in group:engineering@example.com can access devices tagged tag:frontend or tag:backend
    { "action": "accept", "src": ["group:engineering@example.com"], "dst": ["tag:frontend:*", "tag:backend:*"] },
    // users in group:devops@example.com can access devices tagged tag:frontend or tag:backend or tag:logging
    { "action": "accept", "src": ["group:devops@example.com"], "dst": ["tag:frontend:*", "tag:backend:*", "tag:logging:*"] },
  ],
}

Restrict based on individual user

You can enable access to resources based on individual users.

This example is possible with the Personal, Premium, and Enterprise plans.

What this ACL does:

  • User Alice can access devices tagged tag:frontend
  • User Bob can access devices tagged tag:backend
{
  "acls": [
    // Alice can access devices tagged tag:frontend
    { "action": "accept", "src": ["amelie@example.com"], "dst": ["tag:frontend:*"] },
    // Bob can access devices tagged tag:backend
    { "action": "accept", "src": ["bob@example.com"], "dst": ["tag:backend:*"] },
  ]
}

Starter plan ACL

This example provides remote access to corp and prod devices. It is suitable for many Starter plan use cases and is possible with all plans.

Your team can use Tailscale to access remote devices. In this scenario, all users can access their own remote devices, as well as any common corporate devices, such as servers, that are tagged. Only Tailscale admins can access production devices. Admins can configure which devices are tagged. No corporate or production devices can access each other, and no shared users can access devices.

What this ACL does:

  • All employees can access their own devices
  • All employees can access corporate devices tagged tag:corp
  • All Tailscale admins autogroup:admin can access devices tagged tag:prod
  • All Tailscale admins can manage which devices are tagged with tag:corp and tag:prod
{
   "acls": [
    // all employees can access their own devices
    { "action": "accept", "src": ["autogroup:member"], "dst": ["autogroup:self:*"] },
    // all employees can access devices tagged tag:corp
    { "action": "accept", "src": ["autogroup:member"], "dst": ["tag:corp:*"] },
    // all Tailscale admins can access devices tagged tag:prod
    { "action": "accept", "src": ["autogroup:admin"], "dst": ["tag:prod:*"] },
   ],
  "tagOwners": {
    // all Tailscale admins can manage which devices are tagged tag:corp and tag:prod
    "tag:corp": ["autogroup:admin"],
    "tag:prod": ["autogroup:admin"],
   },
 }

Application allowlisting for third-party SaaS application (IP allowlisting)

Your IT team can use Tailscale to allow users access to third-party hosted applications, where access is restricted using IP application allowlisting. In this scenario, traffic for a certain application, www​.example-saas-app.com, is allowed for your organization’s resources only if coming from a known set of fixed IP addresses. You can host an exit node in your network to route all traffic leaving your network, and use that node’s IP address as part of an application allowlist. You can also use auto approvers so that exit nodes are automatically approved.

This example is possible with all plans.

What this ACL does:

  • All Tailscale admins autogroup:admin, for example, the IT team, can access the devices tagged tag:application-exit-node, for maintenance
  • All employees can access the public internet through an exit node in the network. They do not need access to the exit node itself in order to use it
  • All Tailscale admins autogroup:admin, for example, the IT team, can manage which devices are tagged with tag:application-exit-node
  • All Tailscale admins autogroup:admin and devices tagged tag:application-exit-node can auto-approve exit nodes
{
  "groups": {
    // Dave has the admin role in Tailscale, so in autogroup:admin
  },
  "acls": [
    // users who are Tailscale admins can access devices tagged tag:application-exit-node
    { "action": "accept", "src": ["autogroup:admin"], "dst": ["tag:application-exit-node:*"] },
    // all employees can use exit nodes
    { "action": "accept", "src": ["autogroup:member"], "dst": ["autogroup:internet:*"] },
  ],
  "tagOwners": {
    // users who are Tailscale admins can apply the tag tag:application-exit-node
    "tag:application-exit-node": ["autogroup:admin"],
  },
  "autoApprovers": {
    // exit nodes advertised by users who are Tailscale admins or devices tagged
    // tag:application-exit-node will be automatically approved
    "exitNode": ["tag:application-exit-node", "autogroup:admin"],
  }
}

Access to an internal application (VPN)

Your IT team can use Tailscale to allow users to access internal applications, including both custom internal applications and third-party applications hosted internally. In this scenario, users in your network can access applications based on their job role. The IT team can set up internal applications.

This example is possible with the Personal, Premium, and Enterprise plans.

What this ACL does:

  • Members of the engineering team group:engineering can access the devices tagged tag:engineering
  • Members of the finance team group:finance can access the devices tagged tag:finance
  • Members of the legal team group:legal can access the devices tagged tag:legal
  • All employees can access the devices tagged tag:internal
  • All Tailscale admins autogroup:admin, for example, the IT team, can manage which devices are tagged with tag:engineering, tag:finance, tag:legal, and tag:internal
{
  "groups": {
    // Alice is in group:engineering
    "group:engineering": ["alice@example.com",],
    // Bob is in group:finance
    "group:finance": ["bob@example.com",],
    // Carl is in group:legal
    "group:legal": ["carl@example.com",],
    // Dave has the admin role in Tailscale, so in autogroup:admin
  },
  "acls": [
    // users in group:engineering can access devices tagged tag:engineering
    { "action": "accept", "src": ["group:engineering"], "dst": ["tag:engineering:*"] },
    // users in group:finance can access devices tagged tag:finance
    { "action": "accept", "src": ["group:finance"], "dst": ["tag:finance:*"] },
    // users in group:legal can access devices tagged tag:legal
    { "action": "accept", "src": ["group:legal"], "dst": ["tag:legal:*"] },
    // all employees can access devices tagged tag:internal
    { "action": "accept", "src": ["autogroup:member"], "dst": ["tag:internal:*"] },
  ],
  "tagOwners": {
    // users who are Tailscale admins can apply the tag tag:engineering
    "tag:engineering": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:finance
    "tag:finance": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:legal
    "tag:legal": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:internal
    "tag:internal": ["autogroup:admin"],
  },
}

Access to an internal application (VPN) with synced groups

You can also use user & group provisioning to include groups synced from your identity provider in access rules. Synced group names are treated as lowercase. They can include spaces, but not the @ symbol.

This example is possible with the Enterprise plan.

What this ACL does:

  • Members of the engineering team in the synced group group:engineering@example.com can access the devices tagged tag:engineering
  • Members of the finance team in the synced group group:finance team@example.com can access the devices tagged tag:finance
  • Members of the legal team in the synced group group:Legal@example.com can access the devices tagged tag:legal
  • All employees can access the devices tagged tag:internal
  • All Tailscale admins autogroup:admin, for example, the IT team, can manage which devices are tagged with tag:engineering, tag:finance, tag:legal, and tag:internal
{
  "groups": {
    // Alice is in group:engineering@example.com, synced with user & group provisioning
    // Bob is in group:finance team@example.com, synced with user & group provisioning
    // Carl is in group:Legal@example.com, synced with user & group provisioning
    // Dave has the admin role in Tailscale, so in autogroup:admin
  },
  "acls": [
    // users in synced group:engineering@example.com can access devices tagged tag:engineering
    { "action": "accept", "src": ["group:engineering@example.com"], "dst": ["tag:engineering:*"] },
    // users in synced group:finance team@example.com can access devices tagged tag:finance
    { "action": "accept", "src": ["group:finance team@example.com"], "dst": ["tag:finance:*"] },
    // users in synced group:Legal@example.com can access devices tagged tag:legal
    { "action": "accept", "src": ["group:legal@example.com"], "dst": ["tag:legal:*"] },
    // all employees can access devices tagged tag:internal
    { "action": "accept", "src": ["autogroup:member"], "dst": ["tag:internal:*"] },
  ],
  "tagOwners": {
    // users who are Tailscale admins can apply the tag tag:engineering
    "tag:engineering": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:finance
    "tag:finance": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:legal
    "tag:legal": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:internal
    "tag:internal": ["autogroup:admin"],
  },
}

Remote access to production environment

Your DevOps, infrastructure, or SRE team can use Tailscale to access their sensitive and highly protected production environment. In this scenario, a DevOps team might be able to access the production environment, whereas other developers might only be able to access resources in a development environment. All developers are able to access monitoring tools, such as Grafana.

This example is possible with the Personal, Premium, and Enterprise plans. If only your dev team is using Tailscale, use autogroup:member instead of group:dev to use this example on the Starter plan.

What this ACL does:

  • All employees can access their own devices, such as remote workstations
  • Members of the development team group:dev can access the devices tagged tag:dev, such as license servers
  • All Tailscale admins autogroup:admin, such as members of the DevOps team, can access the devices tagged tag:prod, such as the production environment
  • All employees can access devices tagged tag:monitoring on ports 80 and 443, such as monitoring dashboards
  • All Tailscale admins autogroup:admin can manage which devices are tagged with tag:dev, tag:prod, and tag:monitoring
  • Tests ensure that if ACLs are updated, Carl will still be able to access devices tagged tag:prod on port 80, and that Alice will be able to access devices tagged tag:dev but not tag:prod on port 80
{
  "groups": {
    // Alice and Bob are in group:dev
    "group:dev": ["alice@example.com", "bob@example.com",],
    // Carl has the admin role in Tailscale, so in autogroup:admin
  },
  "acls": [
    // all employees can access their own devices
    { "action": "accept", "src": ["autogroup:member"], "dst": ["autogroup:self:*"] },
    // users in group:dev can access devices tagged tag:dev
    { "action": "accept", "src": ["group:dev"], "dst": ["tag:dev:*"] },
    // users who are Tailscale admins can access devices tagged tag:prod
    { "action": "accept", "src": ["autogroup:admin"], "dst": ["tag:prod:*"] },
     // all employees can access devices tagged tag:monitoring on
     // ports 80 and 443
    { "action": "accept", "src": ["autogroup:member"], "dst": ["tag:monitoring:80,443"] },
  ],
  "tagOwners": {
     // users who are Tailscale admins can apply the tag tag:monitoring
    "tag:monitoring": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:dev
    "tag:dev": ["autogroup:admin"],
    // users who are Tailscale admins can apply the tag tag:prod
    "tag:prod": ["autogroup:admin"],
  },
  "tests": [
    {
      "src": "carl@example.com",
      // test that Carl can access devices tagged tag:prod on port 80
      "accept": ["tag:prod:80"],
    },
    {
      "src": "alice@example.com",
      // test that Alice can access devices tagged tag:dev on port 80
      "accept": ["tag:dev:80"],
      // test that Alice cannot access devices tagged tag:prod on port 80
      "deny": ["tag:prod:80"],
    },
  ],
}

VPC access (VPC peering)

Your DevOps team can use Tailscale to allow developers to access existing internal applications running in a Virtual Private Cloud (VPC) on a private or hosted cloud provider. In this scenario, developers can access resources in the VPC, and the DevOps team is able to manage access to the VPC. VPCs can be peered to each other, if they don’t have overlapping IP ranges. To connect an existing subnet to your Tailscale network without installing Tailscale on every node, you can use a subnet router. Run a subnet router in the subnet, and advertise the routes so that Tailscale can route traffic for the subnet to the device for forwarding. For devices on a subnet to connect to devices on your tailnet, disable subnet route masquerading. You can also use auto approvers so that routes are automatically approved.

This example is possible with the Personal, Premium, and Enterprise plans. If only your dev team is using Tailscale, use autogroup:member instead of group:dev to use this example on the Starter plan.

What this ACL does:

  • All Tailscale admins autogroup:admin, for example, the IT team, can access the devices tagged tag:vpc-peering, for maintenance
  • Members of the development team group:dev can access devices in the subnets 10.0.0.0/16 and 10.128.0.0/24
  • The subnet 10.0.0.0/16 can access the subnet 10.128.0.0/24 and vice versa, if subnet route masquerading is disabled
  • All Tailscale admins autogroup:admin, for example, the IT team, can manage which devices are tagged with tag:vpc-peering
  • All Tailscale admins autogroup:admin and devices tagged tag:vpc-peering can auto-approve routes for 10.0.0.0/16 and 10.128.0.0/24
{
  "groups": {
    // Alice and Bob are in group:dev
    "group:dev": ["alice@example.com", "bob@example.com",],
    // Dave has the admin role in Tailscale, so in autogroup:admin
  },
  "acls": [
    // users who are Tailscale admins can access devices tagged tag:vpc-peering
    { "action": "accept", "src": ["autogroup:admin"], "dst": ["tag:vpc-peering:*"] },
    // users in group:dev, and devices in subnets 10.0.0.0/16 and
    // 10.128.0.0/24 can access devices in subnets 10.0.0.0/16 and
    // 10.128.0.0/24
    { "action": "accept", "src": ["group:dev","10.0.0.0/16", "10.128.0.0/24"], "dst": ["10.0.0.0/16:*", "10.128.0.0/24:*"] },
  ],
  "tagOwners": {
    // users who are Tailscale admins can apply the tag tag:vpc-peering
    "tag:vpc-peering": ["autogroup:admin"],
  },
  "autoApprovers": {
    "routes": {
      // subnets included in 10.0.0.0/16 advertised by devices tagged
      // tag:vpc-peering or users who are Tailscale admins will be automatically approved
      "10.0.0.0/16": ["tag:vpc-peering", "autogroup:admin"],
      // subnets included in 10.128.0.0/24 advertised by devices tagged
      // tag:vpc-peering or users who are Tailscale admins will be automatically approved
      "10.128.0.0/24": ["tag:vpc-peering", "autogroup:admin"],
    },
  },
}

Share access with a contractor

Your development team can use Tailscale to share access to specific resources, such as a database or a hosted code repository, with a contractor. In this scenario, developers can access internal development resources. Specific devices can be shared with a contractor as part of their job.

This example is possible with the Personal, Premium, and Enterprise plans. If only your dev team is using Tailscale, use autogroup:member instead of group:dev to use this example on the Starter plan.

What this ACL does:

  • All employees can access their own devices
  • Members of the development team group:dev can access devices tagged tag:dev, such as package registries and databases
  • Contractors who have accepted a share invite can access devices tagged tag:dev which have been shared with them
{
  "groups": {
    // Alice and Bob are in group:dev
    "group:dev": ["alice@example.com", "bob@example.com",],
  },
  "acls": [
    // all employees can access their own devices
    { "action": "accept", "src": ["autogroup:member"], "dst": ["autogroup:self:*"] },
    // users in group:dev and contractors who have accepted a share invite can
    // access devices tagged tag:dev
    { "action": "accept", "src": ["group:dev","autogroup:shared"], "dst": ["tag:dev:*"] },
  ],
  "tagOwners": {
    // users in group:dev can apply the tag tag:dev
    "tag:dev": ["group:dev"],
  },
}

Remote development

Your development team can use Tailscale as part of their remote development setup. In this scenario, a developer might have a local device, like a laptop, and use it to access a remote workstation, hosted in the cloud or hosted on another device in their network. This is useful if you’re accessing a workstation with more processing power, for example, for machine learning or for building. You might also use a remote code environment like GitHub Codespaces, Gitpod, or Coder. From your development environment, you might access a license server, a package registry, a production database, or another development or build resource. You might also access a self-hosted or private code repository.

This example is possible with the Personal, Premium, and Enterprise plans. If only your dev team is using Tailscale, use autogroup:member instead of group:dev to use this example on the Starter plan.

What this ACL does:

  • All employees can access their own devices
  • Members of the development team group:dev can access devices tagged tag:dev, such as package registries and databases
  • The development team group:dev can manage which devices are tagged with tag:dev
{
  "groups": {
    // Alice and Bob are in group:dev
    "group:dev": ["alice@example.com", "bob@example.com",],
  },
  "acls": [
     // all employees can access their own devices
    { "action": "accept", "src": ["autogroup:member"], "dst": ["autogroup:self:*"] },
    // users in group:dev can access devices tagged tag:dev
    { "action": "accept", "src": ["group:dev"], "dst": ["tag:dev:*"] },
  ],
  "tagOwners": {
    // users in group:dev can apply the tag tag:dev
    "tag:dev": ["group:dev"],
  },
}

Pair programming

Your development team can use Tailscale to pair program on the same device remotely. In this scenario, two or more developers can SSH to a corporate device, such as a VM, and share a terminal, for example, a tmux session.

This example is possible with the Personal, Premium, and Enterprise plans. If only Alice and Bob are using Tailscale, use autogroup:member and autogroup:admin instead of named users to use this example on the Starter plan.

What this ACL does:

  • Users Alice and Bob can access the corporate device tagged tag:pair-programming on port 22, for SSH
  • Bob can manage which devices are tagged tag:pair-programming
{
  "acls": [
    // Alice and Bob can access devices tagged tag:pair-programming on
    // port 22
    { "action": "accept", "src": ["alice@example.com", "bob@example.com"], "dst": ["tag:pair-programming:22"] },
  ],
  "tagOwners": {
     // Bob can apply the tag tag:pair-programming
    "tag:pair-programming": ["bob@example.com"],
  },
}

CI/CD deployment pipeline

Your DevOps or infrastructure team can use Tailscale to restrict access to your deployment pipeline. In this scenario, developers can access your development tools, such as your code repository. Then, an automated CI/CD pipeline builds and deploys code. The DevOps team can access the deployment pipeline and production environment.

This example is possible with the Personal, Premium, and Enterprise plans.

What this ACL does:

  • Members of the development team group:dev can access the devices tagged tag:dev, such as code repositories and license servers
  • Members of the DevOps team group:devops can access the devices tagged tag:ci, such as the build tooling; and tag:prod, such as the production environment
  • The DevOps team group:devops can manage which devices are tagged with tag:dev, tag:ci, and tag:prod
  • The tag tag:ci can manage which device are tagged tag:prod and tag:dev, to apply tags as part of the deployment pipeline
{
  "groups": {
    // Alice and Bob are in group:dev
    "group:dev": ["alice@example.com", "bob@example.com",],
    // Carl is in group:devops
    "group:devops": ["carl@example.com",],
  },
  "acls": [
    // users in group:dev can access devices tagged tag:dev
    { "action": "accept", "src": ["group:dev"], "dst": ["tag:dev:*"] },
    // users in group:devops can access devices tagged tag:ci or
    // tagged tag:prod
    { "action": "accept", "src": ["group:devops"], "dst": ["tag:ci:*", "tag:prod:*"] },
  ],
  "tagOwners": {
    // users in group:devops can apply the tag tag:ci
    "tag:ci": ["group:devops"],
    // users in group:devops or devices tagged tag:ci can apply the tag tag:dev
    "tag:dev": ["group:devops", "tag:ci"],
    // users in group:devops or devices tagged tag:ci can apply the tag tag:prod
    "tag:prod": ["group:devops", "tag:ci"],
  },
}

Monitoring access to applications

Your DevOps team can use Tailscale to query logs from services in your network and report these as part of your monitoring tooling. In this scenario, all applications in your network can be accessed by your monitoring server, such as Prometheus, on common ports.

This example is possible with the Personal, Premium, and Enterprise plans. If only your DevOps team is using Tailscale, use autogroup:member instead of group:devops to use this example on the Starter plan.

What this ACL does:

  • Devices tagged tag:monitoring can access services on ports 80, 443, 9100
  • Devices tagged tag:monitoring can access services tagged tag:logging
  • The DevOps team group:devops can access devices tagged with tag:monitoring and tag:logging
  • The DevOps team group:devops can manage which devices are tagged with tag:monitoring and tag:logging
{
  "groups": {
    // Carl is in group:devops
    "group:devops": ["carl@example.com",],
  },
  "acls": [
    // devices tagged tag:monitoring can access all devices in the network on
    // ports 80, 443, and 9100, and devices tagged tag:logging on all ports
    { "action": "accept", "src": ["tag:monitoring"], "dst": ["*:80,443,9100", "tag:logging:*"] },
    // users in group:devops can access devices tagged tag:monitoring and
    // tag:logging
    { "action": "accept", "src": ["group:devops"], "dst": ["tag:monitoring:*", "tag:logging:*"] },
  ],
  "tagOwners": {
    // users in group:devops can apply the tag tag:monitoring
    "tag:monitoring": ["group:devops"],
    // users in group:devops can apply the tag tag:logging
    "tag:logging": ["group:devops"],
  },
}

Application peering

Your infrastructure team can use Tailscale to connect applications or services running in multiple cloud providers or SaaS applications together. In this scenario, one application can connect with another application in your network, for example, to stream from one database to another, such as with Materialize.

This example is possible with the Personal, Premium, and Enterprise plans. If only your infrastructure team is using Tailscale, use autogroup:member instead of group:infra to use this example on the Starter plan.

What this ACL does:

  • Devices tagged tag:database can access other devices tagged tag:database
  • Devices tagged tag:gcp and tag:aws can access devices tagged tag:database, but not vice versa
  • The infrastructure team group:infra can manage which devices are tagged with tag:database, tag:gcp, and tag:aws
{
  "groups": {
    // Carl is in group:infra
    "group:infra": ["carl@example.com",],
  },
  "acls": [
    // devices tagged tag:database, tag:gcp, or tag:aws can access devices
    // tagged tag:database
    { "action": "accept", "src": ["tag:database", "tag:gcp","tag:aws"], "dst": ["tag:database:*"] },
  ],
  "tagOwners": {
    // users in group:infra can apply the tag tag:database
    "tag:database": ["group:infra"],
    // users in group:infra can apply the tag tag:gcp
    "tag:gcp": ["group:infra"],
    // users in group:infra can apply the tag tag:aws
    "tag:aws": ["group:infra"],
  },
}