Team tunnel policies
A team admin can decide which tunnels the team's members may use for their automated tests: require a tunnel for every test, allow only shared tunnels, or keep a personal tunnel to the person who started it.
Team tunnel policies are being switched on team by team. If you do not see a Tunnels tab under Team management, contact us to enable it for your team. During the rollout a session that breaks a rule may still start; this page will say when every rule is enforced.
Without a policy
Tunnels belong to your team. A test can only use a tunnel that was started with the credentials of someone on your team, so a tunnel is never available to another TestingBot account.
Within the team, any member can send a test through any of the team's running tunnels, by using its identifier:
{
"browserName": "chrome",
"tunnelIdentifier": "staging"
}
Starting a tunnel with --shared marks it as shared on the Tunnels page. Without a policy that mark does not stop a colleague from using a tunnel that was started without it. The Keep personal tunnels personal rule changes that.
java -jar testingbot-tunnel.jar key secret --shared --tunnel-identifier staging
The three rules
Turn on any combination. Each rule only looks at the tunnel the test asked for.
| Rule | What it does | Typical use |
|---|---|---|
| Require a tunnel | A test that does not go through a tunnel is refused. A test goes through a tunnel when it is sent to the tunnel's local endpoint (http://localhost:4445/wd/hub) or sets tunnel: true or the tunnelIdentifier capability, and that tunnel is running. |
Your sites are only reachable through your network, or company rules say test traffic must leave through your own tunnel. |
| Only allow shared tunnels | Only tunnels started with --shared may be used. A tunnel started without it is refused, also for the member who started it. |
Your team runs a few central tunnels, for example on a build server, and members should not start their own. |
| Keep personal tunnels personal | A tunnel started without --shared can only be used by the member who started it. Shared tunnels stay available to everyone on the team. |
Members run tunnels to their own machines and a colleague's test must not reach into them by picking the same identifier. |
Who is checked
- Automated Selenium and Appium sessions started with the credentials of a team member or a service account.
- Sessions started with the team owner's own credentials are not checked.
- Live sessions you start from the dashboard are not checked.
- A policy applies to sessions that start after it was saved. Allow up to a minute for a change to take effect. Sessions that are already running are not stopped.
Setting a policy
- Sign in as the team owner or a team admin.
- Open Team management and pick the Tunnels tab.
- Tick the rules you want and click Save policy.
Every change is recorded in the team's activity log as Changed the team's tunnel policy.
Refused sessions
A test that breaks a rule fails before a browser or device is started, and the message names the rule.
| Message starts with | How to fix it |
|---|---|
Your team requires every test to run through a TestingBot tunnel. |
Start a tunnel and send the test through it, or set tunnelIdentifier to a running tunnel. |
Your team only allows shared tunnels |
Use a tunnel that was started with --shared. |
The tunnel … was started by a colleague without --shared |
Start your own tunnel, or ask your colleague to restart theirs with --shared. |
Without Require a tunnel, a test that asks for a tunnel that is not running is handled as described in tunnel troubleshooting.