Deploy custom PrestaShop Helm chart (internal repos)
Notes#
Note: This guide assumes you are working within a cPouta VM. For instructions on deploying a VM, see Instructions for installing virtual machine(s) in cPouta.
- This guide was partially based on the following tutorial: Securing NGINX-ingress
- This guide requires you to familiarize yourself with Kubernetes Ingress concepts to expose your PrestaShop store. Learn more here: Ingress
- This guide uses environment variables in the PrestaShop Docker image: prestashop/prestashop
- This guide uses Helm. To learn more, refer to the Helm documentation
- This guide uses microk8s commands. Read more here: Command reference
- This guide uses microk8s addon commands. Read more here: MicroK8s Addons
- This guide requires you to familiarize yourself with the concept of persistence. Learn more here: Persistent Volumes
Requirements#
- Image: Ubuntu-24.04
- Flavor: standard.medium (3.91 GB RAM, 3 vCPUs) or standard.large (7.81 GB RAM, 4 vCPUs)
- Ports: 22(SSH), 80(HTTP), 443(HTTPS)
- Storage: At least 16 GB for Persistent Volumes if persistence is enabled
Prerequisites#
- Install
microk8s:
- Setup a Kubernetes user:
- Enable
ingressaddon:
- Enable
dnsaddon (if you’ve performed a cleanup and want to install any chart again):
-
Obtain floating ip and domain:
The cPouta documentation states: "All our floating IPs are by default mapped to a hostname". For more information, see DNS services in cPouta.
-
Enable
metallb. Note: Since the IP range is not provided, use the same floating IP address for both start and end. This may trigger warnings but will typically work as expected.
-
Get the PrestaShop helm chart:
Commands#
This guide uses microk8s, which integrates kubectl and helm as part of its toolset. You’ve already seen some microk8s commands, and more will follow. Below is a summary of key microk8s commands used in this guide and their explanations:
Enable a specific addon in your microk8s environment:
Install the chart:
You can modify <release-name> and <chart-path> as needed. However, for consistency, this guide uses presta-helm as the <release-name> throughout. It also assumes that you’re in the root directory of the chart repository presta-shop-helm-x, so the chart path is prestashop:
Upgrade the chart:
Look up the ingress:
The -w flag is used to continuously watch the status of a resource in real-time. If you only want to see its current state, omit this flag.
Check the deployment logs:
The -f flag is used to display continuous logs in real-time. If you only want to view the logs up to the current moment, omit the flag.
Variables#
The PrestaShop Docker image used in the Helm chart has an auto-install feature, meaning there is no installation wizard. You will need to manually configure the parameters. The only required parameter is psDomain, which represents your shop’s domain (note that separate formats of the psDomain are needed for HTTP and HTTPS, as explained in respective installation instructions below). Other parameters can remain at their default values, but it’s recommended that you customize them.
A semi-required parameter is adminMail, as it is used to set up a Let’s Encrypt issuer. If you wish to be notified when your SSL certificate needs to be renewed, provide your private or student email address.
| Variable | Default value | Description |
|---|---|---|
dbName |
prestashop | The name of the database: Used in the mysql container to define the database name and in the prestashop container to connect to the database created by mysql. |
dbPasswd |
adminPrEsTa123 | The password of the database: Used in the mysql container to define the database password and in the prestashop container to connect to the database created by mysql. |
psDomain |
wimma-capstone.jamk.fi | The domain of the website: Used in the prestashop container for SEO, redirection, and other configurations. Additionally, it is utilized in the HTTP and HTTPS setups by the ingress controller for routing configuration and to obtain SSL certificates from Let’s Encrypt in the HTTPS setup. |
psCountry |
FI | The country of the website: Used in the prestashop container to set up the country. |
psLanguage |
en | The language of the website: Used in the prestashop container to set up the language. |
adminMail |
testuser@mail.com | The admin mail: Used in the prestashop container to configure the admin email, which is used for logging into the admin account and is displayed as a contact email on the main page. It is also used to configure Let’s Encrypt issuers for staging and production environments. |
adminPasswd |
ReAlPaSsWoRd759*** | The admin password: Used in the prestashop container to configure the admin password, which is used for logging into the admin account. |
psFolderAdmin |
admin228 | The admin folder: Used in the prestashop container to configure the name of the admin folder, which also serves as the path to the admin dashboard on the website. |
How to set variables#
To set a variable, use the --set flag followed by the variable name and its new value. If you want to split the command across multiple lines for better readability when providing multiple variables, you need to use the backslash \ at the end of each line, except for the last one.
Example 1 - set variables without backslash \:
microk8s helm install presta-helm prestashop --set prestashop.env.psDomain="$FLOATING_IP" --set prestashop.env.dbPasswd="mypass***"
Example 2 - set floating ip as a domain for HTTP ingress:
Example 3 - set multiple variables:
microk8s helm install presta-helm prestashop \
--set prestashop.env.psDomain="$FLOATING_IP" \
--set prestashop.env.dbPasswd="superstrongpassword***" \
--set prestashop.env.adminMail="student@jamk.fi" \
--set prestashop.env.adminPasswd="superstrongpassword***" \
--set prestashop.env.psFolderAdmin="adminfolder" \
--set prestashop.env.psLanguage="fi" \
--set prestashop.env.psCountry="US" \
--set prestashop.env.dbName="prestadb"
Example 4 - export and set multiple variables:
For better flexibility and ease of use, you can first export the desired values as environment variables and then use them during the helm install command.
export FLOATING_IP="$FLOATING_IP"
export DB_PASSWD="superstrongpassword***"
export ADMIN_MAIL="student@jamk.fi"
export ADMIN_PASSWD="superstrongpassword***"
export PS_FOLDER_ADMIN="adminfolder"
export PS_LANGUAGE="fi"
export PS_COUNTRY="US"
export DB_NAME="prestadb"
microk8s helm install presta-helm prestashop \
--set prestashop.env.psDomain="$FLOATING_IP" \
--set prestashop.env.dbPasswd="$DB_PASSWD" \
--set prestashop.env.adminMail="$ADMIN_MAIL" \
--set prestashop.env.adminPasswd="$ADMIN_PASSWD" \
--set prestashop.env.psFolderAdmin="$PS_FOLDER_ADMIN" \
--set prestashop.env.psLanguage="$PS_LANGUAGE" \
--set prestashop.env.psCountry="$PS_COUNTRY" \
--set prestashop.env.dbName="$DB_NAME"
Ingress variables#
There are three ingresses in this Helm chart: HTTP, HTTPS (staging), and HTTPS (production). You can choose which type of ingress to use by modifying the appropriate variables.
By default, the ingress is set to HTTP. If you want to use it, no modification is necessary:
# Snippet from presta-shop-helm-x/prestashop/values.yaml
ingress:
# true: use https ingress
# false: use http ingress
enabled: false
letsencrypt:
# true: use production version of the letsencrypt issuer and ingress
# false: use staging version of letsencrypt issuer and ingress
isProd: false
To use the HTTPS staging ingress, run the following command:
microk8s helm install presta-helm prestashop \
--set prestashop.env.psDomain="$domain" \
--set prestashop.ingress.enabled=true
To use the HTTPS production ingress, run this command:
microk8s helm install presta-helm prestashop \
--set prestashop.env.psDomain="$domain" \
--set prestashop.ingress.enabled=true \
--set prestashop.ingress.letsencrypt.isProd=true
For more information on setting up ingresses, refer to the installation instructions.
Persistent storage#
This chart offers the option to use persistent storage. While optional, it is highly recommended as it ensures the safety of your data in the event of a pod failure. Additionally, it saves time during setup transitions with helm upgrade, as PrestaShop will not be reinstalled. Moreover, persistent storage allows you to delete and later restore your deployment without losing data.
The persistent storage components in this chart are as follows:
-
StorageClass: defines the rules for dynamically provisioning persistent volumes for PrestaShop and MySQL workloads. The
StorageClassuses areclaimPolicy: Retain, meaning that the persistent volumes will not be deleted when the deployment is removed. These volumes must be manually cleaned up from the previousPersistentVolumeClaim(claim reference) before they can be reused in a new deployment. -
PersistentVolume (PV): represents the actual storage. In this chart, the
PersistentVolumeis dynamically provisioned by theStorageClass, but you manually create the storage directory (the data will be deleted during reset if stored in the dynamically managed directory). -
PersistentVolumeClaim (PVC): is a request for storage resources, specifying the amount and type of storage needed. The claim ensures the resources are allocated according to the specified requirements.
Some things to consider when using persistent storage:
-
This persistent setup is designed for the
MicroK8saddonhostpath-storageand may not be compatible with other Kubernetes distributions. -
Keep in mind that the control plane verifies storage requests for both
PersistentVolume(PV) andPersistentVolumeClaim(PVC). In this chart, storage is only requested in the PVC, and the PV is created with the same allocation. However, if you modify the storage request while an existing PV still holds the previous allocation (e.g., if your current PV is 8GB and you want to increase it to 10GB), simply updating the PVC won’t automatically resize the PV. While resizing is possible without recreating the PV and loosing your data, it requires manual intervention, which is outlined here: "Resizing" a PVC and its PV in Microk8s
Installation instructions#
As mentioned earlier, this Helm chart includes three types of ingresses, which you can think of as separate phases or projects. It is recommended to test them in the following order: HTTP, staging HTTPS, and production HTTPS.
When switching between these phases, you don’t need to delete and reinstall all resources. Instead, you can use the helm upgrade command, which applies only the changes based on the updated values.
The basic helm upgrade command is:
If you’re installing the chart for the first time or want to skip directly to a specific ingress type, use the helm install command:
Detailed installation-specific helm install and helm upgrade commands can be found in the respective sections below.
There are also two deployment options available: persistent and non-persistent. If you’re patient, you can follow both versions, but if you’re looking for a quicker solution, choose the one that suits your case best. Keep in mind that while you can helm upgrade from a non-persistent to a persistent deployment, this process can be a bit cumbersome. Therefore, if you intend to test both deployment options, I recommend to perform a cleanup of your first deployment (whether persistent or not) and start fresh with the second option.
Additionally, the persistent deployment involves a custom script for switching between HTTP and HTTPS (or vice versa). While the script has been thoroughly tested, being custom, it may cause unforeseen issues. If you plan to host your website long-term with persistence, I suggest sticking with HTTPS staging or production, as these options don’t require domain and settings updates when doing helm upgrade back and forth.
Deployment without Persistence#
HTTP#
Note: you have to complete prerequisites before following these instructions
-
Install or upgrade the chart:
If you wish, you can set more variables
Install#
If you didn't do any installations yet and this is the first chart you installing, run the following command:
Upgrade#
If you already installed a chart and have any active deployment (HTTP, HTTPS staging, HTTPS production), run the following command:
-
Check ingress:
Expected output:
-
Wait for the resources to be deployed (it might take a few minutes), you can check the logs of the
prestashopdeployment by running the following command: -
Visit your website at:
Staging HTTPS#
Note: you have to complete prerequisites before following these instructions
The HTTPS ingress uses Let’s Encrypt to obtain SSL certificates. While Let’s Encrypt is free, it has rate limits. If exceeded, you won’t be able to obtain new certificates for a certain period. To address this, there’s a staging version that doesn’t issue valid certificates but helps verify if your ingress is configured correctly. Once confirmed, you can proceed to request a production certificate.
-
Enable
cert-manager: -
Install or upgrade the chart:
If you wish, you can set more variables
Install#
If you didn't do any installations yet and this is the first chart you installing, run the following command:
microk8s helm install presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=trueUpgrade#
If you already installed a chart and have any active deployment (HTTP, HTTPS staging, HTTPS production), run the following command:
-
Check ingress:
Expected output:
-
Check issuer:
Expected output:
-
Check certificate:
Expected output:
-
Wait for the resources to be deployed (it might take a few minutes), you can check the logs of the
prestashopdeployment by running the following command: -
Visit your website at:
Note that the browser will infrom you that the site is not secure since it is a staging certificate.
Production HTTPS#
Note: you have to complete prerequisites before following these instructions
-
Enable
cert-managerif not enabled: -
Install or upgrade the chart:
If you wish, you can set more variables
Install#
If you didn't do any installations yet and this is the first chart you installing, run the following command:
microk8s helm install presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=true \ --set prestashop.ingress.letsencrypt.isProd=trueUpgrade#
If you already installed a chart and have any active deployment (HTTP, HTTPS staging, HTTPS production), run the following command:
-
Check ingress:
Expected output:
-
Check issuer:
Expected output:
-
Check certificate:
Expected output:
-
Wait for the resources to be deployed (it might take a few minutes), you can check the logs of the
prestashopdeployment by running the following command: -
Visit your website at:
Deployment with Persistence#
Note: If you’ve already read the installation instructions for deployment without persistence, you might notice some repetition. This is intentional, as it helps keep each set of instructions clear and self-contained while avoiding unnecessary complexity.
Prerequisites#
-
Enable MicroK8s plugin
2. Create a directory forhostpath-storage:PVsto store the data:Note: You can change the storage directory by updating the
common.persistence.storageDirectoryvalue in thevalues.yamlfile, which is located at the root of the chart. Alternatively, you can provide a custom directory path as a variable during thehelm installcommand by using the--setflag (e.g.,--set common.persistence.storageDirectory=/new/directory/path).
HTTP#
Note: you have to complete prerequisites before following these instructions
-
Install or upgrade the chart:
If you wish, you can set more variables
Install#
If you didn't do any installations yet and this is the first chart you installing, run the following command:
microk8s helm install presta-helm prestashop \ --set prestashop.env.psDomain="$FLOATING_IP" \ --set common.persistence.enabled=trueUpgrade#
If you already installed a chart and have any active deployment with persistence enabled (HTTP, HTTPS staging, HTTPS production), perform an upgrade.
You need to specify the name of PrestaShop’s Persistent Volume to ensure the new pod connects to it instead of creating a new one. MySQL is managed automatically during upgrades. Since persistent volumes are dynamically provisioned by the
hostpath-storageaddon, their names are randomly generated, so be sure to double-check the correct PV name before proceeding.You can retrieve the name of your Persistent Volume by executing the following command. Look at the
NAMEattribute to find the PV’s name, and use theCLAIMattribute to identify which PV corresponds to your PrestaShop workload:Note: Make sure to replace
<pv-name>with the actual name of your existing Persistent Volume (existingPVName).microk8s helm upgrade presta-helm prestashop \ --set prestashop.env.psDomain="$FLOATING_IP" \ --set prestashop.ingress.enabled=false \ --set prestashop.ingress.letsencrypt.isProd=false \ --set common.persistence.enabled=true \ --set prestashop.persistence.existingPVName="<pv-name>" \ --set common.persistence.switchDomain=trueExample:
ubuntu@vm-1:~$ microk8s kubectl get pv NAME CAPACITY ACCESS MODES RECLAIM POLICY STATUS CLAIM STORAGECLASS VOLUMEATTRIBUTESCLASS REASON AGE pvc-1ca90b3f-f4ad-4525-ae33-53a9b52c4344 8Gi RWO Retain Bound default/mysql-data-presta-helm-mysql-0 hostpath-retain <unset> 2d23h pvc-7ddc2709-b613-4b6a-a16e-51405258bc3e 8Gi RWO Retain Bound default/prestashop-pvc hostpath-retain <unset> 2d23hmicrok8s helm upgrade presta-helm prestashop \ --set prestashop.env.psDomain="$FLOATING_IP" \ --set prestashop.ingress.enabled=false \ --set prestashop.ingress.letsencrypt.isProd=false \ --set common.persistence.enabled=true \ --set prestashop.persistence.existingPVName="pvc-7ddc2709-b613-4b6a-a16e-51405258bc3e" \ --set common.persistence.switchDomain=true -
Check persistent volumes and persistent volume claims:
-
Check domain update logs (if doing
helm upgrade) -
Check ingress:
Expected output:
-
Wait for the resources to be deployed (it might take a few minutes if doing
helm install), you can check the logs of theprestashopdeployment by running the following command: -
Visit your website at:
Staging HTTPS#
Note: you have to complete prerequisites before following these instructions
The HTTPS ingress uses Let’s Encrypt to obtain SSL certificates. While Let’s Encrypt is free, it has rate limits. If exceeded, you won’t be able to obtain new certificates for a certain period. To address this, there’s a staging version that doesn’t issue valid certificates but helps verify if your ingress is configured correctly. Once confirmed, you can proceed to request a production certificate.
-
Enable
cert-manager: -
Install or upgrade the chart:
If you wish, you can set more variables
Install#
If you didn't do any installations yet and this is the first chart you installing, run the following command:
microk8s helm install presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=true \ --set common.persistence.enabled=trueUpgrade#
If you already installed a chart and have any active deployment with persistence enabled (HTTP, HTTPS staging, HTTPS production), perform an upgrade.
You need to specify the name of PrestaShop’s Persistent Volume to ensure the new pod connects to it instead of creating a new one. MySQL is managed automatically during upgrades. Since persistent volumes are dynamically provisioned by the
hostpath-storageaddon, their names are randomly generated, so be sure to double-check the correct PV name before proceeding.You can retrieve the name of your Persistent Volume by executing the following command. Look at the
NAMEattribute to find the PV’s name, and use theCLAIMattribute to identify which PV corresponds to your PrestaShop workload:Note: Make sure to replace
<pv-name>with the actual name of your existing Persistent Volume (existingPVName).microk8s helm upgrade presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=true \ --set prestashop.ingress.letsencrypt.isProd=false \ --set common.persistence.enabled=true \ --set prestashop.persistence.existingPVName="<pv-name>" \ --set common.persistence.switchDomain=trueExample:
ubuntu@vm-1:~$ microk8s kubectl get pv NAME CAPACITY ACCESS MODES RECLAIM POLICY STATUS CLAIM STORAGECLASS VOLUMEATTRIBUTESCLASS REASON AGE pvc-1ca90b3f-f4ad-4525-ae33-53a9b52c4344 8Gi RWO Retain Bound default/mysql-data-presta-helm-mysql-0 hostpath-retain <unset> 2d23h pvc-7ddc2709-b613-4b6a-a16e-51405258bc3e 8Gi RWO Retain Bound default/prestashop-pvc hostpath-retain <unset> 2d23hmicrok8s helm upgrade presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=true \ --set prestashop.ingress.letsencrypt.isProd=false \ --set common.persistence.enabled=true \ --set prestashop.persistence.existingPVName="pvc-7ddc2709-b613-4b6a-a16e-51405258bc3e" \ --set common.persistence.switchDomain=true -
Check persistent volumes and persistent volume claims:
-
Check domain update logs (if doing
helm upgrade) -
Check ingress:
Expected output:
-
Check issuer:
Expected output:
-
Check certificate:
Expected output:
-
Wait for the resources to be deployed (it might take a few minutes if doing
helm install), you can check the logs of theprestashopdeployment by running the following command: -
Visit your website at:
Note that the browser will infrom you that the site is not secure since it is a staging certificate.
Production HTTPS#
Note: you have to complete prerequisites before following these instructions
-
Enable
cert-managerif not enabled: -
Install or upgrade the chart:
If you wish, you can set more variables
Install#
If you didn't do any installations yet and this is the first chart you installing, run the following command:
microk8s helm install presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=true \ --set prestashop.ingress.letsencrypt.isProd=true \ --set common.persistence.enabled=trueUpgrade#
If you already installed a chart and have any active deployment with persistence enabled (HTTP, HTTPS staging, HTTPS production), perform an upgrade.
You need to specify the name of PrestaShop’s Persistent Volume to ensure the new pod connects to it instead of creating a new one. MySQL is managed automatically during upgrades. Since persistent volumes are dynamically provisioned by the
hostpath-storageaddon, their names are randomly generated, so be sure to double-check the correct PV name before proceeding.You can retrieve the name of your Persistent Volume by executing the following command. Look at the
NAMEattribute to find the PV’s name, and use theCLAIMattribute to identify which PV corresponds to your PrestaShop workload:Note: Make sure to replace
<pv-name>with the actual name of your existing Persistent Volume (existingPVName).microk8s helm upgrade presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=true \ --set prestashop.ingress.letsencrypt.isProd=true \ --set common.persistence.enabled=true \ --set common.persistence.switchDomain=true \ --set prestashop.persistence.existingPVName="<pv-name>"Example:
ubuntu@vm-1:~$ microk8s kubectl get pv NAME CAPACITY ACCESS MODES RECLAIM POLICY STATUS CLAIM STORAGECLASS VOLUMEATTRIBUTESCLASS REASON AGE pvc-1ca90b3f-f4ad-4525-ae33-53a9b52c4344 8Gi RWO Retain Bound default/mysql-data-presta-helm-mysql-0 hostpath-retain <unset> 2d23h pvc-7ddc2709-b613-4b6a-a16e-51405258bc3e 8Gi RWO Retain Bound default/prestashop-pvc hostpath-retain <unset> 2d23hmicrok8s helm upgrade presta-helm prestashop \ --set prestashop.env.psDomain="$domain" \ --set prestashop.ingress.enabled=true \ --set prestashop.ingress.letsencrypt.isProd=true \ --set common.persistence.enabled=true \ --set common.persistence.switchDomain=true \ --set prestashop.persistence.existingPVName="pvc-7ddc2709-b613-4b6a-a16e-51405258bc3e" -
Check persistent volumes and persistent volume claims:
-
Check domain update logs (if doing
helm upgrade) -
Check ingress:
Expected output:
-
Check issuer:
Expected output:
-
Check certificate:
Expected output:
-
Wait for the resources to be deployed (it might take a few minutes if doing
helm install), you can check the logs of theprestashopdeployment by running the following command: -
Visit your website at:
Testing Persistent Storage#
To verify that your data will actually be preserved even if you reset your cluster, follow these steps:
-
Deploy one of the variants of persistent deployment, if not deployed.
-
Log in to the admin dashboard and modify any product:
-
From the admin dashboard, navigate to
Catalog-->Products:
-
Choose any product you like and modify its name or price:

-
Visit your store to verify that the change was successful:

-
-
Reset the deployment:
-
Follow steps 3-6 in prerequisites and step 1 in prerequisites for persistent deployment, also enable
cert-managerif you had HTTPS deployment -
Reinstall the deployment, reconnecting to the existing PVs
Note: It is recommended to reinstall (using
helm installwith instructions from Deployment with Persistence ) the exact same setup as before deletion. For example, if you previously had an HTTP setup, you should reinstall the HTTP setup. However, if you want to switch to a different setup (e.g., changing from HTTP to HTTPS after a reset) while reinstalling, you can do so by addingcommon.persistence.switchDomain=true.Note: Unlike the instructions in Deployment with Persistence upgrades, you will also need to provide the MySQL’s PV name at
mysql.persistence.existingPVNameduring the installation:-
List existing PVs:
Example output:
ubuntu@presta-helm-test:~$ microk8s kubectl get pv NAME CAPACITY ACCESS MODES RECLAIM POLICY STATUS CLAIM STORAGECLASS VOLUMEATTRIBUTESCLASS REASON AGE pvc-782c6800-9bac-467f-bcc3-8287797e7aea 8Gi RWO Retain Released default/prestashop-pvc hostpath-retain <unset> 3d3h pvc-8488c67f-324f-4498-83c5-2b6371198f9f 8Gi RWO Retain Released default/mysql-data-presta-helm-mysql-0 hostpath-retain <unset> 3d3hRemember which PVCs these PVs were associated with, as we will remove this association in the next step. You can identify the association by checking the
CLAIMcolumn. -
Remove claims:
You need to do this because the PVs are still associated with the PVCs from the previous deployment, even though the deployment was removed. This happens because the
Retainpolicy requires manual reclamation.Example output:
ubuntu@presta-helm-test:~$ microk8s kubectl patch pv pvc-782c6800-9bac-467f-bcc3-8287797e7aea -p '{"spec":{"claimRef":null}}' persistentvolume/pvc-782c6800-9bac-467f-bcc3-8287797e7aea patched ubuntu@presta-helm-test:~$ microk8s kubectl patch pv pvc-8488c67f-324f-4498-83c5-2b6371198f9f -p '{"spec":{"claimRef":null}}' persistentvolume/pvc-8488c67f-324f-4498-83c5-2b6371198f9f patched -
Install the setup you had before or you want to upgrade to:
Example 1: Reinstalling the same deployment as before (HTTP deployment in this case):
microk8s helm install presta-helm prestashop \ --set prestashop.env.psDomain="$FLOATING_IP" \ --set common.persistence.enabled=true \ --set mysql.persistence.existingPVName="<pv-name>" \ --set prestashop.persistence.existingPVName="<pv-name>"Example 2: Installing a different deployment than before (switching to HTTP in this case):
-
-
Verify that the product you modified stayed the same.
Cleanup#
Note: This process will delete all resources and reset the MicroK8s node to its initial state.
Deployments without persistence#
Reset MicroK8s:
Deployments with persistence#
Preserving data (e.g., persistent volumes)#
-
Scale down the MySQL StatefulSet (otherwise,
resetmay get stuck):If you named your release differently:
-
Reset MicroK8s:
Removing data (e.g., persistent volumes)#
-
Scale down the MySQL StatefulSet (otherwise,
resetmay get stuck):If you named your release differently:
-
Reset MicroK8s:
-
Delete the Persistent Volumes:
-
Remove the directories sssociated with the Persistent Volumes (modify the command if using another directory):
Debug#
-
Website is not displayed properly.
If the website doesn’t display correctly after switching between deployments, clear your browser’s data (cookies and cache).
-
I want to test my configuration before deployment.
If you’re unsure whether you’ve provided the correct variables, enabled the required addons, or want to verify the behavior of your deployment, you can do a test run. This won’t deploy any resources, so no cleanup is needed afterward. Instead, it will show you details like the ingress type, provided and default values, and errors if the configuration is incorrect or required addons are not enabled. You can use the following commands with any
helm installorhelm upgradecommands in this tutorial: