We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents d1f0d8a + 914f9ae commit 0bef9eaCopy full SHA for 0bef9ea
content/ja/examples/application/mysql/mysql-statefulset.yaml
@@ -22,7 +22,7 @@ spec:
22
- |
23
set -ex
24
# Generate mysql server-id from pod ordinal index.
25
- [[ `hostname` =~ -([0-9]+)$ ]] || exit 1
+ [[ $HOSTNAME =~ -([0-9]+)$ ]] || exit 1
26
ordinal=${BASH_REMATCH[1]}
27
echo [mysqld] > /mnt/conf.d/server-id.cnf
28
# Add an offset to avoid reserved server-id=0 value.
0 commit comments