Bastion¶
Roles with access
- Access to the section: any user with bastion permission, on their own desktops.
- The bastion must be enabled in the installation and the administration must include the user in the bastion permissions (by role, category, group or user); custom domains need a separate permission. See Bastion. Without permission, the bastion options do not appear.
Video: walkthrough of the page
The bastion makes it possible to reach a virtual desktop from outside IsardVDI, over SSH and HTTP/HTTPS, without having to set up any VPN connection. IsardVDI acts as a bridge: it receives the connection and, depending on the subdomain or the port, redirects it to the corresponding service of the desktop.
graph LR
dt1(Client):::dt -.- dk1([IsardVDI Bastion]):::dk -.- dt2(Virtual desktop):::dt
classDef dk fill:#ffd1dc,stroke:#ff3465,stroke-width:1px
Each desktop with the bastion enabled gets its own identifier, and this identifier forms the subdomain used to access it. It is especially useful to publish web services set up inside the desktop or to log in over SSH without additional tunnels.
Requirements
- The bastion must be enabled in the installation and the user must have permissions for it. The administration configures it: see Bastion configuration.
- The desktop must have the Wireguard VPN network interface. IsardVDI adds it automatically when the bastion is enabled, if the user has permission to use it (see Resources).
Deployments
To enable the bastion on all the desktops of a deployment at once, see Bastion in deployments.
In the side menu, the Desktops section: the bastion is configured when editing the desktop and consulted with the Bastion access (HTTP / HTTPS / SSH) icon of the card. Your own SSH key is saved in the profile.
Enable the bastion on a desktop¶
The Bastion section appears when editing the desktop, under Viewers.
The top switch enables or disables the bastion for that desktop. Once enabled, choose which services are published:
| Option | What it does |
|---|---|
| HTTP | Publishes the desktop's web server. |
| HTTP port / HTTPS port | Ports the web server listens on inside the desktop. Externally, they are published on the installation's web ports (usually 80 and 443). |
| Proxy Protocol v2 | Passes the client's real IP to the web server. Only enable it if the desktop's server understands this protocol. |
| Custom domain names (optional) | Your own domains to access the desktop. See «Custom domains». |
| SSH | Publishes the desktop's SSH service. |
| SSH port | Port the SSH server listens on inside the desktop. |
| Authorized keys (one per line) | SSH public keys of other people authorized to connect to it. |
The configuration is not saved in templates
When a template is created from a desktop, the bastion configuration is not kept. It must be enabled again on each desktop, or all at once from a deployment.
The bastion is configured when editing the desktop, in the All access configuration section (Bastion and Bastion configuration subsections). This section only appears if the user has permission to use the bastion, which the administration grants (see Bastion configuration).
- Turn on the Enable bastion switch. If the desktop does not have the wireguard network interface yet, it is added automatically and the «Wireguard interface added» notice appears.
- In Bastion configuration, turn on Enable HTTP / HTTPS access, Enable SSH access or both.
- Check the ports (see the table) and save the desktop changes.
| Option | What it does |
|---|---|
| HTTP Port / HTTPS Port | Ports the web server listens on inside the desktop. Default values: 80 and 443. Accepts 1 to 65535. |
| Proxy Protocol v2 | Forwards the client's real IP to the desktop. Only enable it if the desktop's web server supports Proxy Protocol v2. |
| SSH Port | Port the SSH server listens on inside the desktop. Default value: 22. Accepts 1 to 65535. |
| Authorized SSH Keys (one per line) | Public keys of other people who must be able to log in. Your own key is managed in the profile. |
The wireguard interface is required
- Without permission to use the wireguard interface, the bastion is not enabled and the «Wireguard interface required» error appears. The administration grants the permission in Resources.
- If the wireguard interface is removed from the desktop while the bastion is enabled, the bastion is disabled and «Bastion access disabled» appears.
Where to find it later
When the desktop has HTTP or SSH enabled, the Bastion access (HTTP / HTTPS / SSH) icon appears on its card.
Authorized SSH keys¶
To log in over SSH, the desktop must accept the public key of whoever connects. The keys can be changed at any time, without stopping the desktop.
The bastion checks, at the moment of each connection, the bastion SSH key of the profile and, on deployment desktops, the profile keys of the owner and the co-owners. Nothing is copied to the desktop, so a change in a profile applies straight away. The box is only left for the keys of other people.
The profile key was copied to the desktop when it started, and the copy stayed there even if the profile key was deleted. See Bastion SSH key to find out what has changed.
Add all the public keys that must have access, one per line, including that of the desktop owner.
Changes take a few seconds
The bastion keeps what it reads for a few seconds. Adding or removing a key, disabling a user or disabling the bastion of a desktop takes effect in less than 10 seconds. Changes to the owner or co-owners of a deployment and switching off the bastion for the whole installation can take up to 30 seconds.
Your own SSH key is saved only once in the profile (Bastion SSH Key button) and opens, through the bastion, your own desktops and those of the deployments you own or co-own. See Bastion SSH key.
- In the profile, click Bastion SSH Key.
- Fill in the Your device's SSH public key field.
- Click Save key.
Other people's keys are added on each desktop, in the Authorized SSH Keys (one per line) field of the desktop edit form or of the Bastion information for desktop '…' window. If the profile has no key yet, «User SSH key missing» appears with the Add it to your profile button.
Conditions and messages
- The Your device's SSH public key field is required.
- Only add your own public key to the profile; adding someone else's may breach the organization's security policy.
- If the key is removed from the profile, access with that key is revoked.
- A line that is not a valid public key gives «Invalid SSH public key on line N.».
Development details
For those who develop or integrate IsardVDI: where in the code each element of this section is located, from which version it has been available, which API operation it calls, and what messages it may return.
- New interface · file
views/ProfileView.vue:347· interface text (translation key)views.profile.security.actions.ssh-key- since v17.0.0 (2026-07-09,
48700c853f) - on click:
showSshKeyModal = true
- since v17.0.0 (2026-07-09,
Commit code fe99ad98.
Desktop credentials¶
Just below is the credentials section, with the username and password of the desktop's operating system. They are the same ones the RDP viewer uses.
The SSH connection has two steps. First the user authenticates to the bastion with their SSH key. Then the bastion logs in to the desktop with these credentials, by password. Therefore:
- the username and password must match an account of the desktop's operating system, and
- the desktop's SSH server must accept password authentication for this account
(
PasswordAuthentication yes, the default value in most distributions).
They are stored in plain text
These credentials are stored unencrypted. Use an account created for this purpose instead of a personal password.
In the All access configuration section of the desktop edit form, the Credentials subsection has the Username and Password fields. They are the account of the desktop's operating system that the bastion uses to log in over SSH (see the two-step process in the Old interface tab).
- If they are missing, the form asks «Enter a username to reach the desktop with» or «Enter a password to reach the desktop with».
- If the desktop or the source template already has saved credentials, they are preloaded only when it has the wireguard interface; otherwise the form starts empty.
They are stored unencrypted
The form warns: «WARNING: The password will be stored unencrypted in the database.» Use an account created for this purpose.
Look up the access details¶
Once the configuration is saved, the bastion button appears in the actions menu of the desktop card.
It opens a window with everything needed to connect:
| Field | Description |
|---|---|
| Bastion ID: | Unique identifier of the desktop in the bastion. It is the SSH user. |
| HTTP URL: / HTTPS URL: | Public addresses of the desktop's web server. |
| SSH: | Connection command, ready to copy and paste. |
| Authorized keys for other users | Keys of other people you want to give access to. If the profile has no bastion SSH key yet, the window warns about it and links to the profile (Add it in your profile). |
Each field has a button to copy it to the clipboard, and the URLs have another one to open them in a new tab.
The identifier appears in two forms
The Bastion ID has four hyphens (c64a159b-52f2-4ebd-a226-d2bd53cf9b5f) and is the one SSH uses.
In the URLs, the last hyphen becomes a dot (c64a159b-52f2-4ebd-a226.d2bd53cf9b5f.bastion.example.com).
The CNAME of a custom domain points to the form with hyphens.
Tip
If the IsardVDI website has already been visited with the same browser, it is a good idea to open the service URL in a private window or in another browser.
In Desktops, click the Bastion access (HTTP / HTTPS / SSH) icon on the desktop card. On large cards a panel opens with actions to open in the browser and copy the URL or the SSH connection; on small cards the Bastion information for desktop '…' window opens directly.
| Field | Description |
|---|---|
| Bastion target ID | Identifier of the desktop in the bastion; it is the SSH user. |
| HTTP / HTTPS | Public URLs. The port is only added if it is not 80 (HTTP) or 443 (HTTPS). |
| SSH | ssh <bastion ID>@<bastion domain> command; -p <port> is added if the bastion port is not 22. |
| Custom domains | List of the configured domains. The URLs and the SSH command only use the first one. |
In the URLs, the first four blocks of the ID keep their hyphens and only the last hyphen is shown as a dot (c64a159b-52f2-4ebd-a226.d2bd53cf9b5f.<bastion domain>), as in the Old interface.
Conditions and messages
- «Bastion is not enabled for this desktop»: «Edit the desktop and enable HTTP/HTTPS or SSH access to use the bastion.»
- «Could not load bastion access»: error loading the bastion data or the user's configuration.
- If the bastion SSH key is not in the profile, «User SSH key missing» appears with the «Add it to your profile» button.
- For a deployment owner, a user's per-desktop access is shown in User bastion access, in read-only mode (only copying the URL and the SSH command).
Custom domains¶
Instead of the subdomain formed by the identifier, you can use your own domain. This needs the custom domains permission, which the administration grants in Bastion. Your own domain is also what makes it possible to get a valid HTTPS certificate for the desktop's service.
A desktop accepts up to 10 domains. The procedure is:
- Click Add domain and type the domain name.
- Click the information icon to see the address the CNAME record must point to:
<Bastion ID>.<bastion domain>, for examplec64a159b-52f2-4ebd-a226-d2bd53cf9b5f.bastion.example.com. - Create this CNAME record at the DNS provider.
- Click the shield icon (Verify domain DNS) to verify the DNS.
- Click Update custom domains to save.
The icon next to the domain shows its status: a warning while it is not verified, a loading indicator while the DNS is being checked, an empty tick when it is verified but not saved yet, and a filled tick when it is saved and active.
Warning
If the administration has enabled mandatory domain verification, a new domain cannot be saved until its CNAME record points to the expected address. Verification fails if the CNAME record does not exist yet, does not exactly match the expected value or the domain is already used by another desktop.
A subdomain is needed
The root of a domain (example.com) cannot be a CNAME record. Publish a name below it, such as
app.example.com or www.example.com.
In the bastion information window, the Custom domain name field (placeholder mydesktop.example.com)
lets you save your own domain for the desktop; on saving, «Custom domain updated successfully» appears.
- Click More details to see the DNS instruction: add a CNAME record at the DNS provider that points to the address shown.
- Type the domain and save it. The DNS is checked on saving; the new interface has no verification button.
Only one domain in the editor
The editor in this window only reads and writes the first custom domain (marked in the code as pending migration). The full list is shown in Custom domains.
The desktop edit form also has Add custom domain and Custom domain name (Optional).
Conditions and messages
- If the domain is already used by another desktop or is not valid, the screen says so.
Examples¶
Web service¶
Test of a web service inside a desktop with the Caddy server.
-
Install Caddy and check that the installation went well:
-
If the desktop has a firewall, allow the web ports instead of disabling it:
-
Create a demo page:
-
Make Caddy's default site, which listens on port 80 for any name, serve this page:
Opening the HTTP URL of the information window should show the content of index.html.
The bastion name does not go in the Caddyfile
If the site address in the Caddyfile is a domain name, Caddy enables automatic HTTPS: it redirects HTTP to HTTPS and tries to get a certificate on its own. For names under the bastion domain this certificate cannot be obtained, and both URLs stop working. To publish HTTPS with a valid certificate, follow HTTPS certificates for bastion desktops.
Turn on Enable HTTP / HTTPS access and set the HTTP Port and the HTTPS Port the web server listens on inside the desktop (80 and 443 by default). Then open the HTTP / HTTPS URL of the bastion information window. The Caddy test and the Caddyfile warning of the Old interface tab apply here too, because they depend on the desktop and not on the interface.
Conditions and messages
- Each port must be an integer between 1 and 65535.
- Proxy Protocol v2: only enable it if the web server supports it.
SSH service¶
On the virtual desktop, check that:
- The SSH server is installed and running:
sudo apt install openssh-serverandsudo systemctl enable --now ssh - If there is a firewall, SSH is allowed:
sudo ufw allow OpenSSH - The desktop credentials match an account on the desktop.
Then just copy the SSH command from the information window and run it:
ssh c64a159b-52f2-4ebd-a226-d2bd53cf9b5f@bastion.example.com -p 443 'uname -a'
scp -P 443 file.txt c64a159b-52f2-4ebd-a226-d2bd53cf9b5f@bastion.example.com:
sftp -P 443 c64a159b-52f2-4ebd-a226-d2bd53cf9b5f@bastion.example.com
Before 17.0.0 only interactive sessions and sftp worked; a command such as ssh … 'uname -a'
ended with no output.
Turn on Enable SSH access, set the SSH Port (22 by default) and copy the SSH command from the bastion information window. The public key of whoever connects must be in the profile or in Authorized SSH Keys (one per line), and the desktop must have credentials and an SSH server that accepts passwords (see the Old interface tab).
Messages when the SSH connection fails¶
The bastion explains why it has rejected a connection:
| Message | What to do |
|---|---|
key authentication failed. Ensure you've correctly added your authorized_key(s)… |
The key is not in the profile, nor in the desktop box, nor in the profile of the owner or a co-owner of the deployment. Check it and wait 10 seconds. |
SSH is not enabled for this target |
Enable SSH in the bastion section of the desktop. |
Desktop not started. Ensure it's started in IsardVDI |
Start the desktop. |
Desktop has no credentials set… |
Fill in the desktop credentials. |
Desktop has no IP assigned yet… |
The desktop does not have the Wireguard VPN interface or is still booting. Wait or add the interface. |
Error connecting to target host… |
The bastion reached the desktop, but its SSH server rejected the login: wrong credentials, SSH server stopped, password login disabled or a different SSH port. |
authentication failed |
The bastion is disabled in the installation. |
The connection also takes 10 seconds to be rejected when the user is not a bastion identifier. It is better to copy the command from the information window than to type it.
The bastion shows these messages in the SSH client (bastion service):
| Message | What it means |
|---|---|
key authentication failed. Ensure you've correctly added your authorized_key(s) to this desktop bastion in IsardVDI |
The key is not in the profiles or in the keys of other people. |
SSH is not enabled for this target |
Turn on Enable SSH access on the desktop. |
Desktop not started. Ensure it's started in IsardVDI |
Start the desktop. |
Desktop has no credentials set. Ensure desktop user/password was set for this desktop |
Fill in Credentials. |
Desktop has no IP assigned yet. Ensure it has the WireGuard interface and wait till it's being assigned |
The wireguard interface is missing or the desktop is still booting. |
authentication failed |
Bastion disabled in the installation, or the identifier does not exist. |
authentication failed. |
The user does not have an identifier format; the response is delayed by 10 seconds. |
service not available |
Internal bastion error when querying the data; try again and, if it persists, tell the administration. |
Error connecting to target host: … (followed by Please check if the target VM is running and has SSH enabled.) |
The bastion reached the desktop, but the internal SSH connection failed: wrong credentials, SSH server stopped, password authentication disabled, a different SSH port or timeout (5 s) exceeded. |
Conditions and messages
- When the SSH connection to the bastion fails, the corresponding error messages are shown.







