You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/hardware/04.pro/boards/portenta-x8/tutorials/wordpress-webserver/content.md
+19-19Lines changed: 19 additions & 19 deletions
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
2
title: 'Running Wordpress and Database Containers on the Portenta X8'
3
-
description: 'Learn how to run a database and wordpress container on the Portenta X8'
3
+
description: 'Learn how to run a database and Wordpress container on the Portenta X8'
4
4
difficulty: beginner
5
5
tags:
6
6
- containers
@@ -16,7 +16,7 @@ hardware:
16
16
17
17
## Overview
18
18
19
-
The Arduino Portenta X8 is a powerful board that has many features that can be easily utilized with the help of Docker containers. In this tutorial we will be using the Portenta X8 to host a webserver and run wordpress using containers. This is a simple way to configure and run your own webserver and wordpress page. We can then access the wordpress site on the X8 through our web browser and begin setting it up.
19
+
The Arduino Portenta X8 is a powerful board that has many features that can be easily utilized with the help of Docker containers. In this tutorial we will be using the Portenta X8 to host a webserver and run Wordpress using containers. This is a simple way to configure and run your own webserver and Wordpress page. We can then access the Wordpress site on the X8 through our web browser and begin setting it up.
20
20
21
21
## Goals
22
22
@@ -52,39 +52,39 @@ services:
52
52
environment:
53
53
- PUID=1000
54
54
- PGID=1000
55
-
- MYSQL_ROOT_PASSWORD=wordpress
55
+
- MYSQL_ROOT_PASSWORD=Wordpress
56
56
- TZ=Europe/London
57
-
- MYSQL_DATABASE=wordpress
58
-
- MYSQL_USER=wordpress
59
-
- MYSQL_PASSWORD=wordpress
57
+
- MYSQL_DATABASE=Wordpress
58
+
- MYSQL_USER=Wordpress
59
+
- MYSQL_PASSWORD=Wordpress
60
60
volumes:
61
61
- db_data:/var/lib/mysql
62
62
restart: unless-stopped
63
63
64
-
wordpress:
64
+
Wordpress:
65
65
depends_on:
66
66
- db
67
-
image: wordpress:latest
67
+
image: Wordpress:latest
68
68
volumes:
69
-
- wordpress_data:/var/www/html
69
+
- Wordpress_data:/var/www/html
70
70
ports:
71
71
- "8000:80"
72
72
restart: always
73
73
environment:
74
-
WORDPRESS_DB_HOST: db
75
-
WORDPRESS_DB_USER: wordpress
76
-
WORDPRESS_DB_PASSWORD: wordpress
77
-
WORDPRESS_DB_NAME: wordpress
74
+
Wordpress_DB_HOST: db
75
+
Wordpress_DB_USER: Wordpress
76
+
Wordpress_DB_PASSWORD: Wordpress
77
+
Wordpress_DB_NAME: Wordpress
78
78
volumes:
79
-
wordpress_data: {}
79
+
Wordpress_data: {}
80
80
db_data: {}
81
81
```
82
82
83
83
Now lets create a directory on our X8 and put this **docker-compose.yml** file on our device.
84
84
85
85
### Installing The Containers
86
86
87
-
First we create a directory where we want put our **docker-compose.yml** file. Using the `mkdir` command we will create a directory named wordpress-test. Navigate into this directory with a simple `cd` command. Either copy the docker-compose.yml file into this directory or create it directly here.
87
+
First we create a directory where we want put our **docker-compose.yml** file. Using the `mkdir` command we will create a directory named "wordpress-test". Navigate into this directory with a simple `cd` command. Either copy the docker-compose.yml file into this directory or create it directly here.
88
88
89
89

90
90
@@ -96,25 +96,25 @@ When you are in the correct directory and no other container is running on the p
96
96
97
97
### Connecting to the Wordpress Site
98
98
99
-
To connect to the Wordpress setup site we simply need to access it with our Portenta X8s unique id and port. So for example `http://<uuid>.local:<port>`, where you would substitute the `<uuid>` with your Portenta X8s unique id and the port chosen for the wordpress container with `<port>`. The `<uuid>` can be found on the setup page that is showed in the [Getting started tutorial](https://docs.arduino.cc/tutorials/portenta-x8/out-of-the-box), you can also see it in the terminal when running `adb`. Or you can go to `http://192.168.7.1:8000` if you use Windows and Linux, on MacOS use `http://192.168.8.1:8000`.
99
+
To connect to the Wordpress setup site we simply need to access it with our Portenta X8s unique id and port. So for example `http://<uuid>.local:<port>`, where you would substitute the `<uuid>` with your Portenta X8s unique id and the port chosen for the Wordpress container with `<port>`. The `<uuid>` can be found on the setup page that is showed in the [Getting started tutorial](https://docs.arduino.cc/tutorials/portenta-x8/out-of-the-box), you can also see it in the terminal when running `adb`. Or you can go to `http://192.168.7.1:8000` if you use Windows and Linux, on MacOS use `http://192.168.8.1:8000`.
100
100
101
101
When you connect you should get some feedback in the terminal. Text will begin printing in the terminal, showing you information about the connection that has just been established. Like shown in the image below.
102
102
103
103

104
104
105
105
Now you should see a webpage like on the next image in your browser.
You are now free to go through the Wordpress set up process and configure it however you like.
110
110
111
111
## Conclusion
112
112
113
-
In this tutorial we went through how to install and run a wordpress and database container on the Portenta X8. We then accessed the Wordpress site on our X8 through our web browser. So now you can setup your own Wordpress site on your X8 device and access it from another device.
113
+
In this tutorial we went through how to install and run a Wordpress and database container on the Portenta X8. We then accessed the Wordpress site on our X8 through our web browser. So now you can setup your own Wordpress site on your X8 device and access it from another device.
114
114
115
115
116
116
## Troubleshooting
117
117
118
-
- If the containers aren't installing or running correctly check if there are any other containers currently running on the same ports as the ones used by the wordpress container. You can check this with ``docker ps -a``.
118
+
- If the containers aren't installing or running correctly check if there are any other containers currently running on the same ports as the ones used by the Wordpress container. You can check this with ``docker ps -a``.
119
119
- If there is any issue running docker commands, make sure you are using ``sudo`` before the commands.
120
120
- If you can't connect to the site when everything is running you can double check the X8s ip address. Run the command `ip s a` in the adb shell. This will display the X8s ip address via usb and wifi. Try connecting via those ip addresses if all else fails.
0 commit comments