Sidebar navigationMain contentFooter
Jump toContribute on Github

Deploying WordPress on a Kubernetes cluster with the Application Library

Reviewed on 22 August 2023Published on 07 April 2022
  • kubernetes
  • kubernetes-kapsule
  • wordpress
  • container-registry
  • easy-deploy
  • deploy
  • containerized-application
  • docker

WordPress is a well-known CMS (Content Management System) allowing you to create evolving websites.

This tutorial teaches you how to install WordPress on a Scaleway Kubernetes Kapsule or Kosmos cluster by using the Application Library in the Easy-Deploy feature. You can perform most of these steps directly from the Scaleway console.

Security & Identity (IAM)

To perform certain actions described below, you must either be the Owner of the Organization in which the actions will be performed, or an IAM user with the necessary permissions.

Requirements
  • You have an account and are logged into the Scaleway console
  • You have a Kubernetes cluster at Scaleway (Kapsule or Kosmos)
  • You have kubectl installed on your local computer

Creating a Kubernetes Kapsule cluster and deploying WordPress

  1. Go to the Kubernetes dashboard in the Scaleway console.

  2. Select the cluster you want to deploy WordPress to.

  3. Select the Easy Deploy tab.

    The Application Library allows you to deploy a WordPress CMS application. You can use the search bar to locate the application.

  4. Click Deploy an application.

  5. Select Application Library as the application type.

  6. Search for the application you want to deploy using the search bar.

    The default configuration for the application is set automatically in a YAML format when you select it. You can edit the configuration to fit to your application deployment within the YAML editor displayed.

  7. Enter a name for your application and the Kubernetes namespace you want to deploy it to.

    Important

    If no namespace is chosen, your application will be deployed in your cluster’s default namespace. Deploying in the default namespace is not a good practice and it is highly recommended to split your deployments, services, and application in separate namespaces, thus allowing a more secure configuration of your cluster.

  8. Once configured, click Deploy an application to deploy your application on your Kubernetes cluster.

    You are then redirected to the listing page of our deployed applications.

  9. Check that the deployment is successful by running the command kubectl get all -n cms-ns in your terminal.

    You can see that your WordPress application is running, and has even created a MariaDB database within your cluster to store our data on Scaleway Block Storage. You also have access to the Load Balancer that was created to access your WordPress using the external IP displayed.

  10. Access your WordPress application by entering the external IP provided in a web browser. The WordPress website displays in your browser.

    Note
    • When updating the configuration of your application, you may run into some errors returned by the API. Read these errors carefully, as they contain the instructions you need to solve them.
    • When you update your WordPress application setup, you will run into an error that asks you to use the correct password to update the application.

    This behavior is a security measure as the Application Library automatically creates the missing credentials that are not set at the deployment of the application and stores them into secrets within your Kubernetes cluster.
    To retrieve these secrets, you might need to run command lines such as the following:
    kubectl get secret --namespace "cms-ns" wordpress-mariadb -o jsonpath="{.data.mariadb-password}" | base64 --decode
    All required instructions are given in the error message.

Cloud Products & Resources
  • Scaleway Console
  • Compute
  • Storage
  • Network
  • IoT
  • AI
Dedicated Products & Resources
  • Dedibox Console
  • Dedibox Servers
  • Network
  • Web Hosting
Scaleway
  • Scaleway.com
  • Blog
  • Careers
  • Scaleway Learning
Scaleway Docs
Follow us
FacebookTwitterSlackInstagramLinkedin
ContractsLegal NoticePrivacy PolicyCookie PolicyDocumentation license
© 1999-2024 – Scaleway SAS