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: docs/Containers/MariaDB.md
+11-11Lines changed: 11 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -39,10 +39,10 @@ You only get the opportunity to change the `MQSL_` prefixed environment variable
39
39
$ docker-compose rm --force --stop -v mariadb
40
40
$ sudo rm -rf ./volumes/mariadb
41
41
```
42
-
42
+
43
43
* Edit `docker-compose.yml` and change the variables.
44
44
* Bring up the container:
45
-
45
+
46
46
```
47
47
$ docker-compose up -d mariadb
48
48
```
@@ -79,11 +79,11 @@ The agent is invoked 30 seconds after the container starts, and every 30 seconds
79
79
```
80
80
81
81
2. If that command succeeds, the agent compares the response returned by the command with the expected response:
82
-
82
+
83
83
```
84
84
mysqld is alive
85
85
```
86
-
86
+
87
87
3. If the command returned the expected response, the agent tests the responsiveness of the TCP port the `mysqld` daemon should be listening on (see [customising health-check](#healthCheckCustom)).
88
88
89
89
4. If all of those steps succeed, the agent concludes that MariaDB is functioning properly and returns "healthy".
You can customise the operation of the health-check agent by editing the `mariadb` service definition in your *Compose* file:
@@ -131,16 +131,16 @@ You can customise the operation of the health-check agent by editing the `mariad
131
131
environment:
132
132
- MYSQL_TCP_PORT=12345
133
133
```
134
-
134
+
135
135
Notes:
136
-
136
+
137
137
* The `MYSQL_TCP_PORT` variable is [defined by MariaDB](https://mariadb.com/kb/en/mariadb-environment-variables/), not IOTstack, so changing this variable affects more than just the health-check agent.
138
138
* If you are running "old menu", this change should be made in the file:
139
139
140
140
```
141
141
~/IOTstack/services/mariadb/mariadb.env
142
142
```
143
-
143
+
144
144
2. The `mysqladmin ping` command relies on the root password supplied via the `MYSQL_ROOT_PASSWORD` environment variable in the *Compose* file. The command will not succeed if the root password is not correct, and the agent will return "unhealthy".
145
145
146
146
3. If the health-check agent misbehaves in your environment, or if you simply don't want it to be active, you can disable all health-checking for the container by adding the following lines to its service definition:
@@ -151,14 +151,14 @@ You can customise the operation of the health-check agent by editing the `mariad
151
151
```
152
152
153
153
Note:
154
-
155
-
* The mere presence of a `healthcheck:` clause in the `mariadb` service definition overrides the supplied agent. In other words, the following can't be used to re-enable the supplied agent:
154
+
155
+
* The mere presence of a `healthcheck:` clause in the `mariadb` service definition overrides the supplied agent. In other words, the following can't be used to re-enable the supplied agent:
0 commit comments