Skip to main content
Governance11 min read

1003 - Private environments, public domains

Who opens an environment is decided per environment and who reaches an address per address, so one site is a working copy, a client review room, an intranet and a public website at the same time. Sharing with people and personas, opening an environment to everyone internal, the sign-in every pages address asks for, and the owner’s decision that makes a domain public.

What you will take away from this lesson

ACME’s site now has three environments serving two releases, and every address of all three asks for a sign-in. This lesson decides who opens each one: the web team in dev, a supplier and the store operations team on stage, and, once ACME’s domain is on it in lesson 1004, the public on prod.

On Plexara, who opens an environment is decided per environment, and whether an address answers anyone is decided per address. Those two decisions are why the same site is a workshop, a client review room, an intranet and a public website at once, with no copies to keep in step.

Learning Objectives

  1. 01Say what a private address is, and what makes an address public.
  2. 02Share an environment with a person, with a persona, and with everyone internal.
  3. 03Explain why a persona share follows the persona without anyone updating it.
  4. 04Describe what happens when someone opens a private environment for the first time.
  5. 05Say who can make a domain public, what the portal asks first, and what stays private.
  6. 06Read who may do what on a site, by role.

Access belongs to the environment

Most web hosting gives a site one audience: it is on the internet or it is not. Anything else, a preview for a client, a version for staff, is a second site somewhere else with its own way of keeping people out.

On Plexara each environment decides who may open it, independently of the others. This is where ACME’s site is going by the end of the lesson.

acme-stores: one site, three audiences

EnvironmentAccessWho opens itWhat it is for
devPrivate, alwaysThe owner, the people who manage the site, administrators, and the web-team personaThe working copy. The agent’s changes land here and are reviewed here.
stagePrivateEveryone internal, plus the supplier-blue-harbor personaReview by the people the site is about: store operations and one supplier, before anything is public.
prodPublic at ACME’s own domain, requires approvalAnyone at stores.example.com; at its pages addresses, the people who manage the siteThe store finder and supplier page the world uses, once lesson 1004 puts the domain on it.

The three environments serve releases of the same site. Nothing was duplicated to give the supplier a preview or the public a website, and nothing has to be kept in step between them.

Private addresses and public domains

Every address on your deployment’s pages address is private: the platform checks who is asking before it serves a single byte. A domain you add is private too, until the owner or an administrator sets it public, and then it serves anyone at that one name.

A private address and a public domain, side by side

Private addressPublic domain
Who opens itAdministrators, the owner, the people who manage the site, and whoever it is shared withAnyone
Sign-inYour organization’s, checked on every request and every pathNone. A site that wants one of its own builds it.
What a refusal showsNothing of the site: no page, no file, no file nameDoes not apply
Browser cachingThe browser checks back on every request, so removing someone takes effect on their next clickAs published
Search enginesEvery answer asks not to be indexedIndexed as any public site is
Who is signed inThe site’s own script can ask who the visitor isNobody is signed in, and the site is told so
Which addressesThe main address, every <site>--<environment> address, and every domain until it is set publicA domain the owner or an administrator set public, and only that one name

dev is always private and can never have a domain, so it can never be public. Every other environment asks for a sign-in at its pages addresses whatever its domains are set to. A domain set public opens that one name and nothing else.

Sharing an environment

Grace asked the agent to let the web team into dev, and to open stage to everyone at ACME and to Blue Harbor Wholesale, the supplier whose onboarding the supplier page describes.

Sharing dev with a team, and stage with a supplier and everyone internal

What the agent calls. This is the exchange the agent has with Plexara on your behalf, shown for the technical reader. You ask in plain language; you never type any of it.

→ manage_site
  { "command": "grant", "site": "acme-stores",
    "persona": "web-team", "environments": ["dev"] }

← { "persona": "web-team", "level": "view", "environments": ["dev"],
    "granted_by": "[email protected]" }

→ manage_site
  { "command": "grant", "site": "acme-stores",
    "persona": "supplier-blue-harbor", "environments": ["stage"] }

← { "persona": "supplier-blue-harbor", "level": "view", "environments": ["stage"],
    "granted_by": "[email protected]" }

→ manage_site
  { "command": "set_environment", "site": "acme-stores",
    "environment": "stage", "internal_view": true }

← { "status": "done",
    "site": { "name": "acme-stores", "environments": [
      { "name": "stage", "release": 3, "internal_view": true } ] } }

In the portal each of these is Share on an environment card: pick people and personas, tick the environments, send. Share opens on the environment you started from. The supplier’s persona is the external persona built in lesson 805, so every contact at Blue Harbor Wholesale who signs in can open stage, and none of them can open dev.

Who a share can name

A share names who, and which environments. The who is the same vocabulary as everywhere else on Plexara: a person, a persona, or everyone internal.

Who a share can name, and what it opens

A person

by sign-in email

Opens the private environments the share names. Works for a colleague and for someone outside your organization who signs in through your identity provider.

A persona

a whole role

Opens them for everyone who holds the persona, checked on every request. Someone who joins the persona can open the environment on their next visit; someone who leaves cannot. Nobody maintains a list.

Everyone internal

per environment

Opens one private environment to everyone signed in whose persona is not an external one. This is the intranet setting.

No environments named

a site-wide view

A share that names no environments opens every private environment of the site, including ones created later.

Can manage

internal people only

Given to a person by the owner or an administrator, for the whole site. People outside your organization can be shared with and are refused as managers.

A share gives view: it opens an environment and changes nothing. Someone a site is shared with sees, in the portal and through their agent, only the environments open to them and the domains on those environments. At a public domain anyone opens the environment, so a share matters at its private addresses.

A site's Access tab: a Who manages table listing the owner and one person who can manage, with an Add person button, and a Shared with table listing a person shared on stage, a persona called web-team shared on dev, and Everyone internal on stage, each with Change and Remove.
The Access tab. Who manages the site is site-wide; who else can open it is listed by environment.

What a visitor to a private environment experiences

A contact at Blue Harbor Wholesale opens the stage address from an email. They have never used the portal and do not need to know it exists.

Opening a private environment

  1. 1

    The address is checked before anything is served

    Every request to a private environment, on its own address or on a domain, is checked first. A visitor with no sign-in is sent to your organization’s sign-in.

  2. 2

    The visitor comes back to the page they asked for

    After signing in they land on the same address and path. Someone already signed in to the portal passes through without a click.

  3. 3

    The site’s address keeps its own sign-in

    The handover uses a code that works once, for one minute, for that site, that address and that browser. The address then keeps a sign-in of its own for an hour. It never receives the portal’s session, so a page’s script cannot act as you in the portal.

  4. 4

    Access is read again on every request

    Whether this person may open this environment is decided each time, from the current shares and the current persona. Removing a share closes the site on that person’s next request.

API keys are not accepted on a site’s address. A private environment is for people in a browser, and a system that needs data calls an endpoint (700 series).

What it takes to answer anyone

Store operations and the supplier read stage and were satisfied. prod already serves release 2. What remains is the one change on a site that cannot be taken back quietly: opening it to the world. Lesson 1004 takes that step.

Five rules govern it, and each one exists because a public address is a commitment to people the organization cannot see.

The rules for making a domain public

  1. 01

    Public is a setting of a domain, never of an environment

    Every address on your deployment’s pages address asks for a sign-in, whatever happens to the environment’s domains. Opening a site to anyone takes two deliberate steps: adding a domain, and setting that one domain public.

  2. 02

    Only the owner or an administrator makes a domain public

    An agent can do it only when it is working for one of them, and it is then their decision on the record. On an environment that requires approval, the owner’s request waits in Approvals and the domain stays private until it is approved.

  3. 03

    The portal names the domain before it opens it

    Make public asks for the domain’s name to be typed, names that one domain, and says the pages addresses keep asking for a sign-in. Nobody opens an address to the world without having read it.

  4. 04

    An approval covers the access it was asked for

    A domain made private and then public again asks again. Approval is for this change, not a standing permission.

  5. 05

    Anyone who manages the site can make a domain private

    Closing a door needs less standing than opening one. Private takes effect on the next request.

Inside a private environment

The platform’s decision ends at the door: this person may open this environment, or may not. A site that wants to show different people different things does that itself, and the platform gives it the one fact it needs.

A private site can ask who is signed in

// In a page served from a private environment
const who = await fetch('/_viewer').then((r) => r.json())

// { "email": "[email protected]",
//   "user_id": "...",
//   "persona": "supplier-blue-harbor",
//   "name": "Dana Okafor" }

if (who.persona === 'supplier-blue-harbor') {
  showSupplierPriceSheetLink()
}

The platform decides who may open the environment. Anything finer is the site’s own business, and the site has what it needs to do it: a private environment answers /_viewer with the signed-in person. When the environment is part of an application, the application’s endpoints answer on the same address and run as that person, so a rule the page shows is a rule the server enforces. At a public domain /_viewer answers that nobody is signed in, and the endpoints run as nobody.

Who may do what

Lesson 1001 introduced the owner and the people who manage a site. With sharing and public domains in place, the full table is short enough to read at a glance.

Who may do what on a site

Shared withCan manageOwnerAdministrator
Open a private environmentThe ones sharedEvery oneEvery oneEvery one
Publish and edit dev, promote, roll back, add domains and environmentsNoYesYesYes
Share an environment, make a domain private, set approvalNoYesYesYes
Make a domain public, move the main addressNoNoYesYes
Add or remove the people who manage, change the ownerNoNoYesYes
Delete the site, take approval off an environmentNoNoNoYes

The rows climb in consequence, and so do the columns. Putting approval on an environment is something anyone who manages the site can do; taking it off is an administrator’s, because removing a control should never be easier than adding one.

One site, many rooms

What comes next

prod serves release 2 to the people who manage the site, at addresses that ask for a sign-in. Lesson 1004 puts ACME’s own domain on it and makes that domain public. The external persona used here is built in lesson 805.

Key terms

Five terms cover who can open a site and who decides.

Key Terms

Private address
Asks for your organization’s sign-in and opens for administrators, the owner, the people who manage the site, and whoever the environment is shared with. Every address on the pages address is private.
Public domain
A domain set public by the owner or an administrator. It opens its environment for anyone, with no sign-in, at that one name.
Share
View access to named private environments for a person or a persona. Naming no environments opens every private one.
Everyone internal
A setting on one private environment that opens it to everyone signed in whose persona is not external.
Can manage
Site-wide standing to publish and edit dev, promote, roll back, add domains and share. For internal people only.

Related reading

governance
Governance

403 - Sharing prompts, and closing the loop with feedback

A procedure is only worth as much as the people who can run it. Plexara distributes a prompt two ways: a direct share to the teammates or teams you name, or a promotion to a whole role or company through the admin review queue. A shared prompt is live, not a copy. Feedback threads then carry corrections back, with a validation step and a path into the knowledge catalog, and the deprecate-and-supersede lifecycle retires old versions cleanly.

Governance

505 - Next month’s file

The new sheet arrives. Replacing the file’s content writes a new revision, and the registered table keeps reading the old one until it is registered again under the same name; the Scratch Tables page says so. This lesson covers the two cases that look alike and behave differently, moving the table forward, unregistering, what deleting the file does, saving the monthly procedure as a prompt, and the point at which a monthly file needs more than a join, which is where the 600 series begins.

Governance

605 - What a run may do, and the record it leaves

A run presents the roles its author held at the save, every call is authorized at that moment, and narrowing the persona takes effect on the next run. A save requires one format, work in main(), the structural rules, and tests that pass, reach the code, and read the data, and refuses a credential-shaped literal. A new version is replayed against recent successful runs, and one that changes what the automation does waits for the person’s agreement to a plain-language summary. The dialect has no network, no filesystem, no clock, and no imports beyond pinned libraries, so everything a script does is a platform call audited under the script’s own identity. The lifecycle, who sees what, state and checkpoints on a failed run, ownership and an administrator’s transfer, and the administrator’s view of every script and every run.