---
title: Charmhub | Deploy WordPress using Charmhub - The Open Operator Collection
description: Deploy the latest version of WordPress as a Kubernetes Operator on any
  cloud.
url: https://charmhub.io/wordpress-k8s/docs/how-to-configure-object-storage
---

# WordPress

[Canonical IS DevOps](https://charmhub.io/publisher/canonical-is-devops "View all packages from Canonical IS DevOps")

* [Canonical IS DevOps](https://charmhub.io/publisher/canonical-is-devops "View all packages from Canonical IS DevOps")

Platform:

stable 15

```
juju deploy wordpress-k8s
```

[Learn to deploy on juju >](https://juju.is/docs/juju/manage-applications)

---

#### Contacts

##### Maintainers

+ [Launchpad Team](https://launchpad.net/~canonical-is-devops)

* [Submit a bug](https://github.com/canonical/wordpress-k8s-operator/issues)

---

Share your thoughts on this charm with the community on discourse.

[Join the discussion](https://discourse.charmhub.io/)

# How to configure object storage

Object storage configuration is required for the `wordpress-k8s` charm to work with
multi-unit deployments.

### [Prerequisites](https://charmhub.io/wordpress-k8s/docs/how-to-configure-object-storage#p-23553-prerequisites)

Follow the instructions on installing OpenStack from the OpenStack
[documentation](https://docs.openstack.org/install-guide/). For testing purposes, you can install
[DevStack](https://docs.openstack.org/devstack/latest/).

After a successful installation, you should be able to see the `openrc` file at the location of
installation. Source `openrc` and load the credentials with:

```
source openrc && printenv | grep OS_
```

The output of the command above should look something similar to the following.

```
export OS_CACERT=
export OS_PROJECT_NAME=demo
export OS_TENANT_NAME=demo
export OS_USERNAME=demo
export OS_PASSWORD=<strong-password>
export OS_REGION_NAME=RegionOne
export OS_IDENTITY_API_VERSION=3
export OS_AUTH_TYPE=password
export OS_AUTH_URL=http://<openstack-deployment-address>/identity
export OS_USER_DOMAIN_ID=default
export OS_PROJECT_DOMAIN_ID=default
export OS_VOLUME_API_VERSION=3
```

### [Configure the OpenStack object storage plugin](https://charmhub.io/wordpress-k8s/docs/how-to-configure-object-storage#p-23553-configure-the-openstack-object-storage-plugin)

To configure Swift storage for `wordpress-k8s`, copy and paste the following yaml content and adjust
the values accordingly.

```
auth-url: http://<openstack-deployment-address>/identity/v3
bucket: WordPress
copy-to-swift: 1
domain: Default
object-prefix: wp-content/uploads/
password: <strong-password>
region: RegionOne
remove-local-file: 0
serve-from-swift: 1
swift-url: swift_auth_url
tenant: demo
username: demo
```

The `swift-url` value can be obtained by running `swift auth`. The value should look
something like http://:8080/v3/AUTH\_1d449b4237d3499dabd95210c33ca150, exported under
OS\_STORAGE\_URL key.

You can then configure the `wordpress-k8s` charm using the yaml contents above.

```
juju config wordpress-k8s wp_plugin_openstack-objectstorage_config="$(cat <path-to-yaml>)"
```

---
