eap70-mysql-persistent-s2i.json 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807
  1. {
  2. "kind": "Template",
  3. "apiVersion": "v1",
  4. "metadata": {
  5. "annotations": {
  6. "description": "Application template for EAP 7 MySQL applications with persistent storage built using S2I.",
  7. "iconClass": "icon-jboss",
  8. "tags": "eap,mysql,javaee,java,database,jboss,xpaas",
  9. "version": "1.3.2"
  10. },
  11. "name": "eap70-mysql-persistent-s2i"
  12. },
  13. "labels": {
  14. "template": "eap70-mysql-persistent-s2i",
  15. "xpaas": "1.3.2"
  16. },
  17. "parameters": [
  18. {
  19. "description": "The name for the application.",
  20. "name": "APPLICATION_NAME",
  21. "value": "eap-app",
  22. "required": true
  23. },
  24. {
  25. "description": "Custom hostname for http service route. Leave blank for default hostname, e.g.: <application-name>-<project>.<default-domain-suffix>",
  26. "name": "HOSTNAME_HTTP",
  27. "value": "",
  28. "required": false
  29. },
  30. {
  31. "description": "Custom hostname for https service route. Leave blank for default hostname, e.g.: secure-<application-name>-<project>.<default-domain-suffix>",
  32. "name": "HOSTNAME_HTTPS",
  33. "value": "",
  34. "required": false
  35. },
  36. {
  37. "description": "Git source URI for application",
  38. "name": "SOURCE_REPOSITORY_URL",
  39. "value": "https://github.com/jboss-openshift/openshift-quickstarts",
  40. "required": true
  41. },
  42. {
  43. "description": "Git branch/tag reference",
  44. "name": "SOURCE_REPOSITORY_REF",
  45. "value": "1.3",
  46. "required": false
  47. },
  48. {
  49. "description": "Path within Git project to build; empty for root project directory.",
  50. "name": "CONTEXT_DIR",
  51. "value": "todolist/todolist-jdbc",
  52. "required": false
  53. },
  54. {
  55. "description": "Database JNDI name used by application to resolve the datasource, e.g. java:/jboss/datasources/mysql",
  56. "name": "DB_JNDI",
  57. "value": "java:jboss/datasources/TodoListDS",
  58. "required": false
  59. },
  60. {
  61. "description": "Database name",
  62. "name": "DB_DATABASE",
  63. "value": "root",
  64. "required": true
  65. },
  66. {
  67. "description": "Size of persistent storage for database volume.",
  68. "name": "VOLUME_CAPACITY",
  69. "value": "512Mi",
  70. "required": true
  71. },
  72. {
  73. "description": "Queue names",
  74. "name": "MQ_QUEUES",
  75. "value": "",
  76. "required": false
  77. },
  78. {
  79. "description": "Topic names",
  80. "name": "MQ_TOPICS",
  81. "value": "",
  82. "required": false
  83. },
  84. {
  85. "description": "The name of the service account to use for the deployment. The service account should be configured to allow useage of the secret(s) specified by HTTPS_SECRET and JGROUPS_ENCRYPT_SECRET.",
  86. "name": "SERVICE_ACCOUNT_NAME",
  87. "value": "eap7-service-account",
  88. "required": true
  89. },
  90. {
  91. "description": "The name of the secret containing the keystore file",
  92. "name": "HTTPS_SECRET",
  93. "value": "eap7-app-secret",
  94. "required": false
  95. },
  96. {
  97. "description": "The name of the keystore file within the secret",
  98. "name": "HTTPS_KEYSTORE",
  99. "value": "keystore.jks",
  100. "required": false
  101. },
  102. {
  103. "description": "The type of the keystore file (JKS or JCEKS)",
  104. "name": "HTTPS_KEYSTORE_TYPE",
  105. "value": "",
  106. "required": false
  107. },
  108. {
  109. "description": "The name associated with the server certificate",
  110. "name": "HTTPS_NAME",
  111. "value": "",
  112. "required": false
  113. },
  114. {
  115. "description": "The password for the keystore and certificate",
  116. "name": "HTTPS_PASSWORD",
  117. "value": "",
  118. "required": false
  119. },
  120. {
  121. "description": "Sets xa-pool/min-pool-size for the configured datasource.",
  122. "name": "DB_MIN_POOL_SIZE",
  123. "required": false
  124. },
  125. {
  126. "description": "Sets xa-pool/max-pool-size for the configured datasource.",
  127. "name": "DB_MAX_POOL_SIZE",
  128. "required": false
  129. },
  130. {
  131. "description": "Sets transaction-isolation for the configured datasource.",
  132. "name": "DB_TX_ISOLATION",
  133. "required": false
  134. },
  135. {
  136. "description": "Sets how the table names are stored and compared.",
  137. "name": "MYSQL_LOWER_CASE_TABLE_NAMES",
  138. "required": false
  139. },
  140. {
  141. "description": "The maximum permitted number of simultaneous client connections.",
  142. "name": "MYSQL_MAX_CONNECTIONS",
  143. "required": false
  144. },
  145. {
  146. "description": "The minimum length of the word to be included in a FULLTEXT index.",
  147. "name": "MYSQL_FT_MIN_WORD_LEN",
  148. "required": false
  149. },
  150. {
  151. "description": "The maximum length of the word to be included in a FULLTEXT index.",
  152. "name": "MYSQL_FT_MAX_WORD_LEN",
  153. "required": false
  154. },
  155. {
  156. "description": "Controls the innodb_use_native_aio setting value if the native AIO is broken.",
  157. "name": "MYSQL_AIO",
  158. "required": false
  159. },
  160. {
  161. "description": "A-MQ cluster admin password",
  162. "name": "MQ_CLUSTER_PASSWORD",
  163. "from": "[a-zA-Z0-9]{8}",
  164. "generate": "expression",
  165. "required": true
  166. },
  167. {
  168. "description": "Database user name",
  169. "name": "DB_USERNAME",
  170. "from": "user[a-zA-Z0-9]{3}",
  171. "generate": "expression",
  172. "required": true
  173. },
  174. {
  175. "description": "Database user password",
  176. "name": "DB_PASSWORD",
  177. "from": "[a-zA-Z0-9]{8}",
  178. "generate": "expression",
  179. "required": true
  180. },
  181. {
  182. "description": "GitHub trigger secret",
  183. "name": "GITHUB_WEBHOOK_SECRET",
  184. "from": "[a-zA-Z0-9]{8}",
  185. "generate": "expression",
  186. "required": true
  187. },
  188. {
  189. "description": "Generic build trigger secret",
  190. "name": "GENERIC_WEBHOOK_SECRET",
  191. "from": "[a-zA-Z0-9]{8}",
  192. "generate": "expression",
  193. "required": true
  194. },
  195. {
  196. "description": "Namespace in which the ImageStreams for Red Hat Middleware images are installed. These ImageStreams are normally installed in the openshift namespace. You should only need to modify this if you've installed the ImageStreams in a different namespace/project.",
  197. "name": "IMAGE_STREAM_NAMESPACE",
  198. "value": "openshift",
  199. "required": true
  200. },
  201. {
  202. "description": "The name of the secret containing the keystore file",
  203. "name": "JGROUPS_ENCRYPT_SECRET",
  204. "value": "eap7-app-secret",
  205. "required": false
  206. },
  207. {
  208. "description": "The name of the keystore file within the secret",
  209. "name": "JGROUPS_ENCRYPT_KEYSTORE",
  210. "value": "jgroups.jceks",
  211. "required": false
  212. },
  213. {
  214. "description": "The name associated with the server certificate",
  215. "name": "JGROUPS_ENCRYPT_NAME",
  216. "value": "",
  217. "required": false
  218. },
  219. {
  220. "description": "The password for the keystore and certificate",
  221. "name": "JGROUPS_ENCRYPT_PASSWORD",
  222. "value": "",
  223. "required": false
  224. },
  225. {
  226. "description": "JGroups cluster password",
  227. "name": "JGROUPS_CLUSTER_PASSWORD",
  228. "from": "[a-zA-Z0-9]{8}",
  229. "generate": "expression",
  230. "required": true
  231. },
  232. {
  233. "description": "Controls whether exploded deployment content should be automatically deployed",
  234. "name": "AUTO_DEPLOY_EXPLODED",
  235. "value": "false",
  236. "required": false
  237. }
  238. ],
  239. "objects": [
  240. {
  241. "kind": "Service",
  242. "apiVersion": "v1",
  243. "spec": {
  244. "ports": [
  245. {
  246. "port": 8080,
  247. "targetPort": 8080
  248. }
  249. ],
  250. "selector": {
  251. "deploymentConfig": "${APPLICATION_NAME}"
  252. }
  253. },
  254. "metadata": {
  255. "name": "${APPLICATION_NAME}",
  256. "labels": {
  257. "application": "${APPLICATION_NAME}"
  258. },
  259. "annotations": {
  260. "description": "The web server's http port."
  261. }
  262. }
  263. },
  264. {
  265. "kind": "Service",
  266. "apiVersion": "v1",
  267. "spec": {
  268. "ports": [
  269. {
  270. "port": 8443,
  271. "targetPort": 8443
  272. }
  273. ],
  274. "selector": {
  275. "deploymentConfig": "${APPLICATION_NAME}"
  276. }
  277. },
  278. "metadata": {
  279. "name": "secure-${APPLICATION_NAME}",
  280. "labels": {
  281. "application": "${APPLICATION_NAME}"
  282. },
  283. "annotations": {
  284. "description": "The web server's https port."
  285. }
  286. }
  287. },
  288. {
  289. "kind": "Service",
  290. "apiVersion": "v1",
  291. "spec": {
  292. "ports": [
  293. {
  294. "port": 3306,
  295. "targetPort": 3306
  296. }
  297. ],
  298. "selector": {
  299. "deploymentConfig": "${APPLICATION_NAME}-mysql"
  300. }
  301. },
  302. "metadata": {
  303. "name": "${APPLICATION_NAME}-mysql",
  304. "labels": {
  305. "application": "${APPLICATION_NAME}"
  306. },
  307. "annotations": {
  308. "description": "The database server's port."
  309. }
  310. }
  311. },
  312. {
  313. "kind": "Route",
  314. "apiVersion": "v1",
  315. "id": "${APPLICATION_NAME}-http",
  316. "metadata": {
  317. "name": "${APPLICATION_NAME}",
  318. "labels": {
  319. "application": "${APPLICATION_NAME}"
  320. },
  321. "annotations": {
  322. "description": "Route for application's http service."
  323. }
  324. },
  325. "spec": {
  326. "host": "${HOSTNAME_HTTP}",
  327. "to": {
  328. "name": "${APPLICATION_NAME}"
  329. }
  330. }
  331. },
  332. {
  333. "kind": "Route",
  334. "apiVersion": "v1",
  335. "id": "${APPLICATION_NAME}-https",
  336. "metadata": {
  337. "name": "secure-${APPLICATION_NAME}",
  338. "labels": {
  339. "application": "${APPLICATION_NAME}"
  340. },
  341. "annotations": {
  342. "description": "Route for application's https service."
  343. }
  344. },
  345. "spec": {
  346. "host": "${HOSTNAME_HTTPS}",
  347. "to": {
  348. "name": "secure-${APPLICATION_NAME}"
  349. },
  350. "tls": {
  351. "termination": "passthrough"
  352. }
  353. }
  354. },
  355. {
  356. "kind": "ImageStream",
  357. "apiVersion": "v1",
  358. "metadata": {
  359. "name": "${APPLICATION_NAME}",
  360. "labels": {
  361. "application": "${APPLICATION_NAME}"
  362. }
  363. }
  364. },
  365. {
  366. "kind": "BuildConfig",
  367. "apiVersion": "v1",
  368. "metadata": {
  369. "name": "${APPLICATION_NAME}",
  370. "labels": {
  371. "application": "${APPLICATION_NAME}"
  372. }
  373. },
  374. "spec": {
  375. "source": {
  376. "type": "Git",
  377. "git": {
  378. "uri": "${SOURCE_REPOSITORY_URL}",
  379. "ref": "${SOURCE_REPOSITORY_REF}"
  380. },
  381. "contextDir": "${CONTEXT_DIR}"
  382. },
  383. "strategy": {
  384. "type": "Source",
  385. "sourceStrategy": {
  386. "forcePull": true,
  387. "from": {
  388. "kind": "ImageStreamTag",
  389. "namespace": "${IMAGE_STREAM_NAMESPACE}",
  390. "name": "jboss-eap70-openshift:1.4"
  391. }
  392. }
  393. },
  394. "output": {
  395. "to": {
  396. "kind": "ImageStreamTag",
  397. "name": "${APPLICATION_NAME}:latest"
  398. }
  399. },
  400. "triggers": [
  401. {
  402. "type": "GitHub",
  403. "github": {
  404. "secret": "${GITHUB_WEBHOOK_SECRET}"
  405. }
  406. },
  407. {
  408. "type": "Generic",
  409. "generic": {
  410. "secret": "${GENERIC_WEBHOOK_SECRET}"
  411. }
  412. },
  413. {
  414. "type": "ImageChange",
  415. "imageChange": {}
  416. },
  417. {
  418. "type": "ConfigChange"
  419. }
  420. ]
  421. }
  422. },
  423. {
  424. "kind": "DeploymentConfig",
  425. "apiVersion": "v1",
  426. "metadata": {
  427. "name": "${APPLICATION_NAME}",
  428. "labels": {
  429. "application": "${APPLICATION_NAME}"
  430. }
  431. },
  432. "spec": {
  433. "strategy": {
  434. "type": "Recreate"
  435. },
  436. "triggers": [
  437. {
  438. "type": "ImageChange",
  439. "imageChangeParams": {
  440. "automatic": true,
  441. "containerNames": [
  442. "${APPLICATION_NAME}"
  443. ],
  444. "from": {
  445. "kind": "ImageStreamTag",
  446. "name": "${APPLICATION_NAME}:latest"
  447. }
  448. }
  449. },
  450. {
  451. "type": "ConfigChange"
  452. }
  453. ],
  454. "replicas": 1,
  455. "selector": {
  456. "deploymentConfig": "${APPLICATION_NAME}"
  457. },
  458. "template": {
  459. "metadata": {
  460. "name": "${APPLICATION_NAME}",
  461. "labels": {
  462. "deploymentConfig": "${APPLICATION_NAME}",
  463. "application": "${APPLICATION_NAME}"
  464. }
  465. },
  466. "spec": {
  467. "serviceAccountName": "${SERVICE_ACCOUNT_NAME}",
  468. "terminationGracePeriodSeconds": 75,
  469. "containers": [
  470. {
  471. "name": "${APPLICATION_NAME}",
  472. "image": "${APPLICATION_NAME}",
  473. "imagePullPolicy": "Always",
  474. "volumeMounts": [
  475. {
  476. "name": "eap-keystore-volume",
  477. "mountPath": "/etc/eap-secret-volume",
  478. "readOnly": true
  479. },
  480. {
  481. "name": "eap-jgroups-keystore-volume",
  482. "mountPath": "/etc/jgroups-encrypt-secret-volume",
  483. "readOnly": true
  484. }
  485. ],
  486. "lifecycle": {
  487. "preStop": {
  488. "exec": {
  489. "command": [
  490. "/opt/eap/bin/jboss-cli.sh",
  491. "-c",
  492. ":shutdown(timeout=60)"
  493. ]
  494. }
  495. }
  496. },
  497. "livenessProbe": {
  498. "exec": {
  499. "command": [
  500. "/bin/bash",
  501. "-c",
  502. "/opt/eap/bin/livenessProbe.sh"
  503. ]
  504. }
  505. },
  506. "readinessProbe": {
  507. "exec": {
  508. "command": [
  509. "/bin/bash",
  510. "-c",
  511. "/opt/eap/bin/readinessProbe.sh"
  512. ]
  513. }
  514. },
  515. "ports": [
  516. {
  517. "name": "jolokia",
  518. "containerPort": 8778,
  519. "protocol": "TCP"
  520. },
  521. {
  522. "name": "http",
  523. "containerPort": 8080,
  524. "protocol": "TCP"
  525. },
  526. {
  527. "name": "https",
  528. "containerPort": 8443,
  529. "protocol": "TCP"
  530. },
  531. {
  532. "name": "ping",
  533. "containerPort": 8888,
  534. "protocol": "TCP"
  535. }
  536. ],
  537. "env": [
  538. {
  539. "name": "DB_SERVICE_PREFIX_MAPPING",
  540. "value": "${APPLICATION_NAME}-mysql=DB"
  541. },
  542. {
  543. "name": "DB_JNDI",
  544. "value": "${DB_JNDI}"
  545. },
  546. {
  547. "name": "DB_USERNAME",
  548. "value": "${DB_USERNAME}"
  549. },
  550. {
  551. "name": "DB_PASSWORD",
  552. "value": "${DB_PASSWORD}"
  553. },
  554. {
  555. "name": "DB_DATABASE",
  556. "value": "${DB_DATABASE}"
  557. },
  558. {
  559. "name": "TX_DATABASE_PREFIX_MAPPING",
  560. "value": "${APPLICATION_NAME}-mysql=DB"
  561. },
  562. {
  563. "name": "DB_MIN_POOL_SIZE",
  564. "value": "${DB_MIN_POOL_SIZE}"
  565. },
  566. {
  567. "name": "DB_MAX_POOL_SIZE",
  568. "value": "${DB_MAX_POOL_SIZE}"
  569. },
  570. {
  571. "name": "DB_TX_ISOLATION",
  572. "value": "${DB_TX_ISOLATION}"
  573. },
  574. {
  575. "name": "OPENSHIFT_KUBE_PING_LABELS",
  576. "value": "application=${APPLICATION_NAME}"
  577. },
  578. {
  579. "name": "OPENSHIFT_KUBE_PING_NAMESPACE",
  580. "valueFrom": {
  581. "fieldRef": {
  582. "fieldPath": "metadata.namespace"
  583. }
  584. }
  585. },
  586. {
  587. "name": "HTTPS_KEYSTORE_DIR",
  588. "value": "/etc/eap-secret-volume"
  589. },
  590. {
  591. "name": "HTTPS_KEYSTORE",
  592. "value": "${HTTPS_KEYSTORE}"
  593. },
  594. {
  595. "name": "HTTPS_KEYSTORE_TYPE",
  596. "value": "${HTTPS_KEYSTORE_TYPE}"
  597. },
  598. {
  599. "name": "HTTPS_NAME",
  600. "value": "${HTTPS_NAME}"
  601. },
  602. {
  603. "name": "HTTPS_PASSWORD",
  604. "value": "${HTTPS_PASSWORD}"
  605. },
  606. {
  607. "name": "MQ_CLUSTER_PASSWORD",
  608. "value": "${MQ_CLUSTER_PASSWORD}"
  609. },
  610. {
  611. "name": "MQ_QUEUES",
  612. "value": "${MQ_QUEUES}"
  613. },
  614. {
  615. "name": "MQ_TOPICS",
  616. "value": "${MQ_TOPICS}"
  617. },
  618. {
  619. "name": "JGROUPS_ENCRYPT_SECRET",
  620. "value": "${JGROUPS_ENCRYPT_SECRET}"
  621. },
  622. {
  623. "name": "JGROUPS_ENCRYPT_KEYSTORE_DIR",
  624. "value": "/etc/jgroups-encrypt-secret-volume"
  625. },
  626. {
  627. "name": "JGROUPS_ENCRYPT_KEYSTORE",
  628. "value": "${JGROUPS_ENCRYPT_KEYSTORE}"
  629. },
  630. {
  631. "name": "JGROUPS_ENCRYPT_NAME",
  632. "value": "${JGROUPS_ENCRYPT_NAME}"
  633. },
  634. {
  635. "name": "JGROUPS_ENCRYPT_PASSWORD",
  636. "value": "${JGROUPS_ENCRYPT_PASSWORD}"
  637. },
  638. {
  639. "name": "JGROUPS_CLUSTER_PASSWORD",
  640. "value": "${JGROUPS_CLUSTER_PASSWORD}"
  641. },
  642. {
  643. "name": "AUTO_DEPLOY_EXPLODED",
  644. "value": "${AUTO_DEPLOY_EXPLODED}"
  645. },
  646. {
  647. "name": "DEFAULT_JOB_REPOSITORY",
  648. "value": "${APPLICATION_NAME}-mysql"
  649. },
  650. {
  651. "name": "TIMER_SERVICE_DATA_STORE",
  652. "value": "${APPLICATION_NAME}-mysql"
  653. }
  654. ]
  655. }
  656. ],
  657. "volumes": [
  658. {
  659. "name": "eap-keystore-volume",
  660. "secret": {
  661. "secretName": "${HTTPS_SECRET}"
  662. }
  663. },
  664. {
  665. "name": "eap-jgroups-keystore-volume",
  666. "secret": {
  667. "secretName": "${JGROUPS_ENCRYPT_SECRET}"
  668. }
  669. }
  670. ]
  671. }
  672. }
  673. }
  674. },
  675. {
  676. "kind": "DeploymentConfig",
  677. "apiVersion": "v1",
  678. "metadata": {
  679. "name": "${APPLICATION_NAME}-mysql",
  680. "labels": {
  681. "application": "${APPLICATION_NAME}"
  682. }
  683. },
  684. "spec": {
  685. "strategy": {
  686. "type": "Recreate"
  687. },
  688. "triggers": [
  689. {
  690. "type": "ImageChange",
  691. "imageChangeParams": {
  692. "automatic": true,
  693. "containerNames": [
  694. "${APPLICATION_NAME}-mysql"
  695. ],
  696. "from": {
  697. "kind": "ImageStreamTag",
  698. "namespace": "${IMAGE_STREAM_NAMESPACE}",
  699. "name": "mysql:latest"
  700. }
  701. }
  702. },
  703. {
  704. "type": "ConfigChange"
  705. }
  706. ],
  707. "replicas": 1,
  708. "selector": {
  709. "deploymentConfig": "${APPLICATION_NAME}-mysql"
  710. },
  711. "template": {
  712. "metadata": {
  713. "name": "${APPLICATION_NAME}-mysql",
  714. "labels": {
  715. "deploymentConfig": "${APPLICATION_NAME}-mysql",
  716. "application": "${APPLICATION_NAME}"
  717. }
  718. },
  719. "spec": {
  720. "terminationGracePeriodSeconds": 60,
  721. "containers": [
  722. {
  723. "name": "${APPLICATION_NAME}-mysql",
  724. "image": "mysql",
  725. "imagePullPolicy": "Always",
  726. "ports": [
  727. {
  728. "containerPort": 3306,
  729. "protocol": "TCP"
  730. }
  731. ],
  732. "volumeMounts": [
  733. {
  734. "mountPath": "/var/lib/mysql/data",
  735. "name": "${APPLICATION_NAME}-mysql-pvol"
  736. }
  737. ],
  738. "env": [
  739. {
  740. "name": "MYSQL_USER",
  741. "value": "${DB_USERNAME}"
  742. },
  743. {
  744. "name": "MYSQL_PASSWORD",
  745. "value": "${DB_PASSWORD}"
  746. },
  747. {
  748. "name": "MYSQL_DATABASE",
  749. "value": "${DB_DATABASE}"
  750. },
  751. {
  752. "name": "MYSQL_LOWER_CASE_TABLE_NAMES",
  753. "value": "${MYSQL_LOWER_CASE_TABLE_NAMES}"
  754. },
  755. {
  756. "name": "MYSQL_MAX_CONNECTIONS",
  757. "value": "${MYSQL_MAX_CONNECTIONS}"
  758. },
  759. {
  760. "name": "MYSQL_FT_MIN_WORD_LEN",
  761. "value": "${MYSQL_FT_MIN_WORD_LEN}"
  762. },
  763. {
  764. "name": "MYSQL_FT_MAX_WORD_LEN",
  765. "value": "${MYSQL_FT_MAX_WORD_LEN}"
  766. },
  767. {
  768. "name": "MYSQL_AIO",
  769. "value": "${MYSQL_AIO}"
  770. }
  771. ]
  772. }
  773. ],
  774. "volumes": [
  775. {
  776. "name": "${APPLICATION_NAME}-mysql-pvol",
  777. "persistentVolumeClaim": {
  778. "claimName": "${APPLICATION_NAME}-mysql-claim"
  779. }
  780. }
  781. ]
  782. }
  783. }
  784. }
  785. },
  786. {
  787. "apiVersion": "v1",
  788. "kind": "PersistentVolumeClaim",
  789. "metadata": {
  790. "name": "${APPLICATION_NAME}-mysql-claim",
  791. "labels": {
  792. "application": "${APPLICATION_NAME}"
  793. }
  794. },
  795. "spec": {
  796. "accessModes": [
  797. "ReadWriteOnce"
  798. ],
  799. "resources": {
  800. "requests": {
  801. "storage": "${VOLUME_CAPACITY}"
  802. }
  803. }
  804. }
  805. }
  806. ]
  807. }