eap64-postgresql-persistent-s2i.json 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769
  1. {
  2. "kind": "Template",
  3. "apiVersion": "v1",
  4. "metadata": {
  5. "annotations": {
  6. "description": "Application template for EAP 6 PostgreSQL applications with persistent storage built using S2I.",
  7. "iconClass": "icon-jboss",
  8. "tags": "eap,postgresql,javaee,java,database,jboss,xpaas",
  9. "version": "1.3.2"
  10. },
  11. "name": "eap64-postgresql-persistent-s2i"
  12. },
  13. "labels": {
  14. "template": "eap64-postgresql-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.2",
  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/postgresql",
  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": "HORNETQ_QUEUES",
  75. "value": "",
  76. "required": false
  77. },
  78. {
  79. "description": "Topic names",
  80. "name": "HORNETQ_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": "eap-service-account",
  88. "required": true
  89. },
  90. {
  91. "description": "The name of the secret containing the keystore file",
  92. "name": "HTTPS_SECRET",
  93. "value": "eap-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": "The maximum number of client connections allowed. This also sets the maximum number of prepared transactions.",
  137. "name": "POSTGRESQL_MAX_CONNECTIONS",
  138. "required": false
  139. },
  140. {
  141. "description": "Configures how much memory is dedicated to PostgreSQL for caching data.",
  142. "name": "POSTGRESQL_SHARED_BUFFERS",
  143. "required": false
  144. },
  145. {
  146. "description": "HornetQ cluster admin password",
  147. "name": "HORNETQ_CLUSTER_PASSWORD",
  148. "from": "[a-zA-Z0-9]{8}",
  149. "generate": "expression",
  150. "required": true
  151. },
  152. {
  153. "description": "Database user name",
  154. "name": "DB_USERNAME",
  155. "from": "user[a-zA-Z0-9]{3}",
  156. "generate": "expression",
  157. "required": true
  158. },
  159. {
  160. "description": "Database user password",
  161. "name": "DB_PASSWORD",
  162. "from": "[a-zA-Z0-9]{8}",
  163. "generate": "expression",
  164. "required": true
  165. },
  166. {
  167. "description": "GitHub trigger secret",
  168. "name": "GITHUB_WEBHOOK_SECRET",
  169. "from": "[a-zA-Z0-9]{8}",
  170. "generate": "expression",
  171. "required": true
  172. },
  173. {
  174. "description": "Generic build trigger secret",
  175. "name": "GENERIC_WEBHOOK_SECRET",
  176. "from": "[a-zA-Z0-9]{8}",
  177. "generate": "expression",
  178. "required": true
  179. },
  180. {
  181. "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.",
  182. "name": "IMAGE_STREAM_NAMESPACE",
  183. "value": "openshift",
  184. "required": true
  185. },
  186. {
  187. "description": "The name of the secret containing the keystore file",
  188. "name": "JGROUPS_ENCRYPT_SECRET",
  189. "value": "eap-app-secret",
  190. "required": false
  191. },
  192. {
  193. "description": "The name of the keystore file within the secret",
  194. "name": "JGROUPS_ENCRYPT_KEYSTORE",
  195. "value": "jgroups.jceks",
  196. "required": false
  197. },
  198. {
  199. "description": "The name associated with the server certificate",
  200. "name": "JGROUPS_ENCRYPT_NAME",
  201. "value": "",
  202. "required": false
  203. },
  204. {
  205. "description": "The password for the keystore and certificate",
  206. "name": "JGROUPS_ENCRYPT_PASSWORD",
  207. "value": "",
  208. "required": false
  209. },
  210. {
  211. "description": "JGroups cluster password",
  212. "name": "JGROUPS_CLUSTER_PASSWORD",
  213. "from": "[a-zA-Z0-9]{8}",
  214. "generate": "expression",
  215. "required": true
  216. },
  217. {
  218. "description": "Controls whether exploded deployment content should be automatically deployed",
  219. "name": "AUTO_DEPLOY_EXPLODED",
  220. "value": "false",
  221. "required": false
  222. }
  223. ],
  224. "objects": [
  225. {
  226. "kind": "Service",
  227. "apiVersion": "v1",
  228. "spec": {
  229. "ports": [
  230. {
  231. "port": 8080,
  232. "targetPort": 8080
  233. }
  234. ],
  235. "selector": {
  236. "deploymentConfig": "${APPLICATION_NAME}"
  237. }
  238. },
  239. "metadata": {
  240. "name": "${APPLICATION_NAME}",
  241. "labels": {
  242. "application": "${APPLICATION_NAME}"
  243. },
  244. "annotations": {
  245. "description": "The web server's http port."
  246. }
  247. }
  248. },
  249. {
  250. "kind": "Service",
  251. "apiVersion": "v1",
  252. "spec": {
  253. "ports": [
  254. {
  255. "port": 8443,
  256. "targetPort": 8443
  257. }
  258. ],
  259. "selector": {
  260. "deploymentConfig": "${APPLICATION_NAME}"
  261. }
  262. },
  263. "metadata": {
  264. "name": "secure-${APPLICATION_NAME}",
  265. "labels": {
  266. "application": "${APPLICATION_NAME}"
  267. },
  268. "annotations": {
  269. "description": "The web server's https port."
  270. }
  271. }
  272. },
  273. {
  274. "kind": "Service",
  275. "apiVersion": "v1",
  276. "spec": {
  277. "ports": [
  278. {
  279. "port": 5432,
  280. "targetPort": 5432
  281. }
  282. ],
  283. "selector": {
  284. "deploymentConfig": "${APPLICATION_NAME}-postgresql"
  285. }
  286. },
  287. "metadata": {
  288. "name": "${APPLICATION_NAME}-postgresql",
  289. "labels": {
  290. "application": "${APPLICATION_NAME}"
  291. },
  292. "annotations": {
  293. "description": "The database server's port."
  294. }
  295. }
  296. },
  297. {
  298. "kind": "Route",
  299. "apiVersion": "v1",
  300. "id": "${APPLICATION_NAME}-http",
  301. "metadata": {
  302. "name": "${APPLICATION_NAME}",
  303. "labels": {
  304. "application": "${APPLICATION_NAME}"
  305. },
  306. "annotations": {
  307. "description": "Route for application's http service."
  308. }
  309. },
  310. "spec": {
  311. "host": "${HOSTNAME_HTTP}",
  312. "to": {
  313. "name": "${APPLICATION_NAME}"
  314. }
  315. }
  316. },
  317. {
  318. "kind": "Route",
  319. "apiVersion": "v1",
  320. "id": "${APPLICATION_NAME}-https",
  321. "metadata": {
  322. "name": "secure-${APPLICATION_NAME}",
  323. "labels": {
  324. "application": "${APPLICATION_NAME}"
  325. },
  326. "annotations": {
  327. "description": "Route for application's https service."
  328. }
  329. },
  330. "spec": {
  331. "host": "${HOSTNAME_HTTPS}",
  332. "to": {
  333. "name": "secure-${APPLICATION_NAME}"
  334. },
  335. "tls": {
  336. "termination": "passthrough"
  337. }
  338. }
  339. },
  340. {
  341. "kind": "ImageStream",
  342. "apiVersion": "v1",
  343. "metadata": {
  344. "name": "${APPLICATION_NAME}",
  345. "labels": {
  346. "application": "${APPLICATION_NAME}"
  347. }
  348. }
  349. },
  350. {
  351. "kind": "BuildConfig",
  352. "apiVersion": "v1",
  353. "metadata": {
  354. "name": "${APPLICATION_NAME}",
  355. "labels": {
  356. "application": "${APPLICATION_NAME}"
  357. }
  358. },
  359. "spec": {
  360. "source": {
  361. "type": "Git",
  362. "git": {
  363. "uri": "${SOURCE_REPOSITORY_URL}",
  364. "ref": "${SOURCE_REPOSITORY_REF}"
  365. },
  366. "contextDir": "${CONTEXT_DIR}"
  367. },
  368. "strategy": {
  369. "type": "Source",
  370. "sourceStrategy": {
  371. "forcePull": true,
  372. "from": {
  373. "kind": "ImageStreamTag",
  374. "namespace": "${IMAGE_STREAM_NAMESPACE}",
  375. "name": "jboss-eap64-openshift:1.4"
  376. }
  377. }
  378. },
  379. "output": {
  380. "to": {
  381. "kind": "ImageStreamTag",
  382. "name": "${APPLICATION_NAME}:latest"
  383. }
  384. },
  385. "triggers": [
  386. {
  387. "type": "GitHub",
  388. "github": {
  389. "secret": "${GITHUB_WEBHOOK_SECRET}"
  390. }
  391. },
  392. {
  393. "type": "Generic",
  394. "generic": {
  395. "secret": "${GENERIC_WEBHOOK_SECRET}"
  396. }
  397. },
  398. {
  399. "type": "ImageChange",
  400. "imageChange": {}
  401. },
  402. {
  403. "type": "ConfigChange"
  404. }
  405. ]
  406. }
  407. },
  408. {
  409. "kind": "DeploymentConfig",
  410. "apiVersion": "v1",
  411. "metadata": {
  412. "name": "${APPLICATION_NAME}",
  413. "labels": {
  414. "application": "${APPLICATION_NAME}"
  415. }
  416. },
  417. "spec": {
  418. "strategy": {
  419. "type": "Recreate"
  420. },
  421. "triggers": [
  422. {
  423. "type": "ImageChange",
  424. "imageChangeParams": {
  425. "automatic": true,
  426. "containerNames": [
  427. "${APPLICATION_NAME}"
  428. ],
  429. "from": {
  430. "kind": "ImageStreamTag",
  431. "name": "${APPLICATION_NAME}:latest"
  432. }
  433. }
  434. },
  435. {
  436. "type": "ConfigChange"
  437. }
  438. ],
  439. "replicas": 1,
  440. "selector": {
  441. "deploymentConfig": "${APPLICATION_NAME}"
  442. },
  443. "template": {
  444. "metadata": {
  445. "name": "${APPLICATION_NAME}",
  446. "labels": {
  447. "deploymentConfig": "${APPLICATION_NAME}",
  448. "application": "${APPLICATION_NAME}"
  449. }
  450. },
  451. "spec": {
  452. "serviceAccountName": "${SERVICE_ACCOUNT_NAME}",
  453. "terminationGracePeriodSeconds": 60,
  454. "containers": [
  455. {
  456. "name": "${APPLICATION_NAME}",
  457. "image": "${APPLICATION_NAME}",
  458. "imagePullPolicy": "Always",
  459. "volumeMounts": [
  460. {
  461. "name": "eap-keystore-volume",
  462. "mountPath": "/etc/eap-secret-volume",
  463. "readOnly": true
  464. },
  465. {
  466. "name": "eap-jgroups-keystore-volume",
  467. "mountPath": "/etc/jgroups-encrypt-secret-volume",
  468. "readOnly": true
  469. }
  470. ],
  471. "livenessProbe": {
  472. "exec": {
  473. "command": [
  474. "/bin/bash",
  475. "-c",
  476. "/opt/eap/bin/livenessProbe.sh"
  477. ]
  478. }
  479. },
  480. "readinessProbe": {
  481. "exec": {
  482. "command": [
  483. "/bin/bash",
  484. "-c",
  485. "/opt/eap/bin/readinessProbe.sh"
  486. ]
  487. }
  488. },
  489. "ports": [
  490. {
  491. "name": "jolokia",
  492. "containerPort": 8778,
  493. "protocol": "TCP"
  494. },
  495. {
  496. "name": "http",
  497. "containerPort": 8080,
  498. "protocol": "TCP"
  499. },
  500. {
  501. "name": "https",
  502. "containerPort": 8443,
  503. "protocol": "TCP"
  504. },
  505. {
  506. "name": "ping",
  507. "containerPort": 8888,
  508. "protocol": "TCP"
  509. }
  510. ],
  511. "env": [
  512. {
  513. "name": "DB_SERVICE_PREFIX_MAPPING",
  514. "value": "${APPLICATION_NAME}-postgresql=DB"
  515. },
  516. {
  517. "name": "DB_JNDI",
  518. "value": "${DB_JNDI}"
  519. },
  520. {
  521. "name": "DB_USERNAME",
  522. "value": "${DB_USERNAME}"
  523. },
  524. {
  525. "name": "DB_PASSWORD",
  526. "value": "${DB_PASSWORD}"
  527. },
  528. {
  529. "name": "DB_DATABASE",
  530. "value": "${DB_DATABASE}"
  531. },
  532. {
  533. "name": "TX_DATABASE_PREFIX_MAPPING",
  534. "value": "${APPLICATION_NAME}-postgresql=DB"
  535. },
  536. {
  537. "name": "DB_MIN_POOL_SIZE",
  538. "value": "${DB_MIN_POOL_SIZE}"
  539. },
  540. {
  541. "name": "DB_MAX_POOL_SIZE",
  542. "value": "${DB_MAX_POOL_SIZE}"
  543. },
  544. {
  545. "name": "DB_TX_ISOLATION",
  546. "value": "${DB_TX_ISOLATION}"
  547. },
  548. {
  549. "name": "OPENSHIFT_KUBE_PING_LABELS",
  550. "value": "application=${APPLICATION_NAME}"
  551. },
  552. {
  553. "name": "OPENSHIFT_KUBE_PING_NAMESPACE",
  554. "valueFrom": {
  555. "fieldRef": {
  556. "fieldPath": "metadata.namespace"
  557. }
  558. }
  559. },
  560. {
  561. "name": "HTTPS_KEYSTORE_DIR",
  562. "value": "/etc/eap-secret-volume"
  563. },
  564. {
  565. "name": "HTTPS_KEYSTORE",
  566. "value": "${HTTPS_KEYSTORE}"
  567. },
  568. {
  569. "name": "HTTPS_KEYSTORE_TYPE",
  570. "value": "${HTTPS_KEYSTORE_TYPE}"
  571. },
  572. {
  573. "name": "HTTPS_NAME",
  574. "value": "${HTTPS_NAME}"
  575. },
  576. {
  577. "name": "HTTPS_PASSWORD",
  578. "value": "${HTTPS_PASSWORD}"
  579. },
  580. {
  581. "name": "HORNETQ_CLUSTER_PASSWORD",
  582. "value": "${HORNETQ_CLUSTER_PASSWORD}"
  583. },
  584. {
  585. "name": "HORNETQ_QUEUES",
  586. "value": "${HORNETQ_QUEUES}"
  587. },
  588. {
  589. "name": "HORNETQ_TOPICS",
  590. "value": "${HORNETQ_TOPICS}"
  591. },
  592. {
  593. "name": "JGROUPS_ENCRYPT_SECRET",
  594. "value": "${JGROUPS_ENCRYPT_SECRET}"
  595. },
  596. {
  597. "name": "JGROUPS_ENCRYPT_KEYSTORE_DIR",
  598. "value": "/etc/jgroups-encrypt-secret-volume"
  599. },
  600. {
  601. "name": "JGROUPS_ENCRYPT_KEYSTORE",
  602. "value": "${JGROUPS_ENCRYPT_KEYSTORE}"
  603. },
  604. {
  605. "name": "JGROUPS_ENCRYPT_NAME",
  606. "value": "${JGROUPS_ENCRYPT_NAME}"
  607. },
  608. {
  609. "name": "JGROUPS_ENCRYPT_PASSWORD",
  610. "value": "${JGROUPS_ENCRYPT_PASSWORD}"
  611. },
  612. {
  613. "name": "JGROUPS_CLUSTER_PASSWORD",
  614. "value": "${JGROUPS_CLUSTER_PASSWORD}"
  615. },
  616. {
  617. "name": "TIMER_SERVICE_DATA_STORE",
  618. "value": "${APPLICATION_NAME}-postgresql"
  619. },
  620. {
  621. "name": "AUTO_DEPLOY_EXPLODED",
  622. "value": "${AUTO_DEPLOY_EXPLODED}"
  623. }
  624. ]
  625. }
  626. ],
  627. "volumes": [
  628. {
  629. "name": "eap-keystore-volume",
  630. "secret": {
  631. "secretName": "${HTTPS_SECRET}"
  632. }
  633. },
  634. {
  635. "name": "eap-jgroups-keystore-volume",
  636. "secret": {
  637. "secretName": "${JGROUPS_ENCRYPT_SECRET}"
  638. }
  639. }
  640. ]
  641. }
  642. }
  643. }
  644. },
  645. {
  646. "kind": "DeploymentConfig",
  647. "apiVersion": "v1",
  648. "metadata": {
  649. "name": "${APPLICATION_NAME}-postgresql",
  650. "labels": {
  651. "application": "${APPLICATION_NAME}"
  652. }
  653. },
  654. "spec": {
  655. "strategy": {
  656. "type": "Recreate"
  657. },
  658. "triggers": [
  659. {
  660. "type": "ImageChange",
  661. "imageChangeParams": {
  662. "automatic": true,
  663. "containerNames": [
  664. "${APPLICATION_NAME}-postgresql"
  665. ],
  666. "from": {
  667. "kind": "ImageStreamTag",
  668. "namespace": "${IMAGE_STREAM_NAMESPACE}",
  669. "name": "postgresql:latest"
  670. }
  671. }
  672. },
  673. {
  674. "type": "ConfigChange"
  675. }
  676. ],
  677. "replicas": 1,
  678. "selector": {
  679. "deploymentConfig": "${APPLICATION_NAME}-postgresql"
  680. },
  681. "template": {
  682. "metadata": {
  683. "name": "${APPLICATION_NAME}-postgresql",
  684. "labels": {
  685. "deploymentConfig": "${APPLICATION_NAME}-postgresql",
  686. "application": "${APPLICATION_NAME}"
  687. }
  688. },
  689. "spec": {
  690. "terminationGracePeriodSeconds": 60,
  691. "containers": [
  692. {
  693. "name": "${APPLICATION_NAME}-postgresql",
  694. "image": "postgresql",
  695. "imagePullPolicy": "Always",
  696. "ports": [
  697. {
  698. "containerPort": 5432,
  699. "protocol": "TCP"
  700. }
  701. ],
  702. "volumeMounts": [
  703. {
  704. "mountPath": "/var/lib/pgsql/data",
  705. "name": "${APPLICATION_NAME}-postgresql-pvol"
  706. }
  707. ],
  708. "env": [
  709. {
  710. "name": "POSTGRESQL_USER",
  711. "value": "${DB_USERNAME}"
  712. },
  713. {
  714. "name": "POSTGRESQL_PASSWORD",
  715. "value": "${DB_PASSWORD}"
  716. },
  717. {
  718. "name": "POSTGRESQL_DATABASE",
  719. "value": "${DB_DATABASE}"
  720. },
  721. {
  722. "name": "POSTGRESQL_MAX_CONNECTIONS",
  723. "value": "${POSTGRESQL_MAX_CONNECTIONS}"
  724. },
  725. {
  726. "name": "POSTGRESQL_MAX_PREPARED_TRANSACTIONS",
  727. "value": "${POSTGRESQL_MAX_CONNECTIONS}"
  728. },
  729. {
  730. "name": "POSTGRESQL_SHARED_BUFFERS",
  731. "value": "${POSTGRESQL_SHARED_BUFFERS}"
  732. }
  733. ]
  734. }
  735. ],
  736. "volumes": [
  737. {
  738. "name": "${APPLICATION_NAME}-postgresql-pvol",
  739. "persistentVolumeClaim": {
  740. "claimName": "${APPLICATION_NAME}-postgresql-claim"
  741. }
  742. }
  743. ]
  744. }
  745. }
  746. }
  747. },
  748. {
  749. "apiVersion": "v1",
  750. "kind": "PersistentVolumeClaim",
  751. "metadata": {
  752. "name": "${APPLICATION_NAME}-postgresql-claim",
  753. "labels": {
  754. "application": "${APPLICATION_NAME}"
  755. }
  756. },
  757. "spec": {
  758. "accessModes": [
  759. "ReadWriteOnce"
  760. ],
  761. "resources": {
  762. "requests": {
  763. "storage": "${VOLUME_CAPACITY}"
  764. }
  765. }
  766. }
  767. }
  768. ]
  769. }