How to install Landscape Server with Juju¶
See also: Landscape Server charm (Charmhub)
You can deploy Landscape in a scalable way with Juju. This document provides a very high-level overview.
For detailed instructions on deploying Landscape with Juju in a high-availability environment, see How to install and configure Landscape for high-availability deployments.
Install Juju¶
Install Juju as a snap with this command:
sudo snap install juju --classic
To learn more about Juju and to bootstrap a Juju controller, check out their getting started page.
Deploy self-hosted Landscape Server¶
Choose the appropriate option for your Landscape charm deployment.
If you have an Ubuntu Pro subscription, attach your Pro token to each machine that will host Landscape Server components. For guidance, see How to attach your Ubuntu Pro subscription.
Important
Starting with the 26.04 version of the landscape-server charm, the deployment architecture changes to PostgreSQL 14+ over the database relation (backed by the postgresql_client charm interface), HAProxy 2.8 over haproxy-route, and TLS via tls-certificates.
The Charmhub landscape-scalable bundle was deprecated in 26.04 and does not have a 26.04/* track. For 26.04+ deployments, follow How to install and configure Landscape for high-availability deployments.
Deploy with Terraform¶
You can deploy Landscape with the Landscape Scalable Terraform product module (see its reference documentation for inputs and outputs), or with the Charmhub bundle described below.
Other deployment methods¶
When deploying with Juju, you will use a Juju bundle. A bundle is an encapsulation of all of the parts needed to deploy the required services as well as associated relations and configurations that the deployment requires.
See also: Landscape-scalable bundle on Charmhub
The landscape-scalable bundle published on Charmhub was deprecated in 26.04 and should not be used for new deployments. It uses the older topology (external HAProxy charm, PostgreSQL 14 over the legacy pgsql interface).
For the 26.04 architecture (recommended), the new deployment approach uses:
External HAProxy charm (
2.8/stable) for load balancing via thehaproxy-routeinterfacePostgreSQL 14+ over the
databaserelation (postgresql_clientinterface)TLS certificates provided via the
tls-certificatesinterface integrated with HAProxy (e.g.,self-signed-certificatescharm)The Debarchive and Landscape Task Handler charms, integrated with Landscape Server for repository mirroring and offloaded task processing, respectively
Key benefits of the new approach:
HAProxy charm handles all traffic routing and TLS termination
True high-availability with multiple Landscape Server units behind HAProxy
Better scalability and resilience
For detailed instructions on deploying with the new architecture, create and deploy a custom bundle as documented in How to install and configure Landscape for high-availability deployments.
Previously, there were additional bundles: landscape-dense and landscape-dense-maas. These bundles are now deprecated and should not be used for new deployments.
Access self-hosted Landscape¶
Once the deployment has finished, Landscape Server is accessible in different ways depending on the deployment approach:
Select your Landscape Server version:
HAProxy routes traffic based on the
hostnameset in thehaproxy-routerelation, not by port alone, so you must connect using that hostname (for example, with--resolveor a DNS entry pointing it at the HAProxy unit’s IP). Connecting directly to the HAProxy unit’s own IP address (with no matchingHostheader) hits HAProxy’s default page instead of Landscape.If you set
root_url, that hostname is what you must connect with.If you leave
root_urlunset, thelandscape-servercharm falls back to using the leader unit’s IP address as the routing hostname, so you’d need to connect using that IP as theHostheader/SNI value (not the HAProxy unit’s IP). In practice, settingroot_urlto a real hostname is much simpler for testing.HAProxy handles load balancing across all Landscape Server units once you’re routed correctly.
Tip
For the 26.04+ deployment, set root_url to a real hostname and point that hostname (via DNS or curl --resolve) at your HAProxy unit’s IP address (or external load balancer) before testing.
Access via the IP address of the first
haproxyunitHAProxy typically runs on port 443 (HTTPS)
With an external load balancer (LBaaS)¶
When using a cross-model HAProxy deployment
Access via the hostname specified in your
root_urlThe external HAProxy distributes traffic across Landscape Server units