eap64-amq-persistent-s2i.json 39 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932
  1. {
  2. "kind": "Template",
  3. "apiVersion": "v1",
  4. "metadata": {
  5. "annotations": {
  6. "iconClass": "icon-eap",
  7. "tags": "eap,javaee,java,jboss",
  8. "version": "1.4.8",
  9. "openshift.io/display-name": "JBoss EAP 6.4 + A-MQ (with https)",
  10. "openshift.io/provider-display-name": "Red Hat, Inc.",
  11. "description": "An example EAP 6 A-MQ application. For more information about using this template, see https://github.com/jboss-openshift/application-templates.",
  12. "template.openshift.io/long-description": "This template defines resources needed to develop Red Hat Enterprise Application Server 6.4 based application, including a build configuration, application deployment configuration, using Red Hat JBoss A-MQ with persistence and secure communication using https.",
  13. "template.openshift.io/documentation-url": "https://access.redhat.com/documentation/en/red-hat-jboss-enterprise-application-platform/",
  14. "template.openshift.io/support-url": "https://access.redhat.com"
  15. },
  16. "name": "eap64-amq-persistent-s2i"
  17. },
  18. "labels": {
  19. "template": "eap64-amq-persistent-s2i",
  20. "xpaas": "1.4.8"
  21. },
  22. "message": "A new EAP 6 and A-MQ persistent based application with SSL support has been created in your project. The username/password for accessing the A-MQ service is ${MQ_USERNAME}/${MQ_PASSWORD}. Please be sure to create the following secrets: \"${HTTPS_SECRET}\" containing the ${HTTPS_KEYSTORE} file used for serving secure content; \"${JGROUPS_ENCRYPT_SECRET}\" containing the ${JGROUPS_ENCRYPT_KEYSTORE} file used for securing JGroups communications.",
  23. "parameters": [
  24. {
  25. "displayName": "Application Name",
  26. "description": "The name for the application.",
  27. "name": "APPLICATION_NAME",
  28. "value": "eap-app",
  29. "required": true
  30. },
  31. {
  32. "displayName": "Custom http Route Hostname",
  33. "description": "Custom hostname for http service route. Leave blank for default hostname, e.g.: <application-name>-<project>.<default-domain-suffix>",
  34. "name": "HOSTNAME_HTTP",
  35. "value": "",
  36. "required": false
  37. },
  38. {
  39. "displayName": "Custom https Route Hostname",
  40. "description": "Custom hostname for https service route. Leave blank for default hostname, e.g.: secure-<application-name>-<project>.<default-domain-suffix>",
  41. "name": "HOSTNAME_HTTPS",
  42. "value": "",
  43. "required": false
  44. },
  45. {
  46. "displayName": "Git Repository URL",
  47. "description": "Git source URI for application",
  48. "name": "SOURCE_REPOSITORY_URL",
  49. "value": "https://github.com/jboss-developer/jboss-eap-quickstarts.git",
  50. "required": true
  51. },
  52. {
  53. "displayName": "Git Reference",
  54. "description": "Git branch/tag reference",
  55. "name": "SOURCE_REPOSITORY_REF",
  56. "value": "6.4.x",
  57. "required": false
  58. },
  59. {
  60. "displayName": "Context Directory",
  61. "description": "Path within Git project to build; empty for root project directory.",
  62. "name": "CONTEXT_DIR",
  63. "value": "helloworld-mdb",
  64. "required": false
  65. },
  66. {
  67. "displayName": "A-MQ Volume Size",
  68. "description": "Size of the volume used by A-MQ for persisting messages.",
  69. "name": "VOLUME_CAPACITY",
  70. "value": "1Gi",
  71. "required": true
  72. },
  73. {
  74. "displayName": "JMS Connection Factory JNDI Name",
  75. "description": "JNDI name for connection factory used by applications to connect to the broker, e.g. java:/ConnectionFactory",
  76. "name": "MQ_JNDI",
  77. "value": "java:/ConnectionFactory",
  78. "required": false
  79. },
  80. {
  81. "displayName": "Split Data?",
  82. "description": "Split the data directory for each node in a mesh.",
  83. "name": "AMQ_SPLIT",
  84. "value": "false",
  85. "required": false
  86. },
  87. {
  88. "displayName": "A-MQ Protocols",
  89. "description": "Broker protocols to configure, separated by commas. Allowed values are: `openwire`, `amqp`, `stomp` and `mqtt`. Only `openwire` is supported by EAP.",
  90. "name": "MQ_PROTOCOL",
  91. "value": "openwire",
  92. "required": false
  93. },
  94. {
  95. "displayName": "Queues",
  96. "description": "Queue names, separated by commas. These queues will be automatically created when the broker starts. Also, they will be made accessible as JNDI resources in EAP.",
  97. "name": "MQ_QUEUES",
  98. "value": "HELLOWORLDMDBQueue",
  99. "required": false
  100. },
  101. {
  102. "displayName": "Topics",
  103. "description": "Topic names, separated by commas. These topics will be automatically created when the broker starts. Also, they will be made accessible as JNDI resources in EAP.",
  104. "name": "MQ_TOPICS",
  105. "value": "HELLOWORLDMDBTopic",
  106. "required": false
  107. },
  108. {
  109. "displayName": "A-MQ Serializable Packages",
  110. "description": "List of packages that are allowed to be serialized for use in ObjectMessage, separated by commas. If your app doesn't use ObjectMessages, leave this blank. This is a security enforcement. For the rationale, see http://activemq.apache.org/objectmessage.html",
  111. "name": "MQ_SERIALIZABLE_PACKAGES",
  112. "value": "",
  113. "required": false
  114. },
  115. {
  116. "displayName": "Server Keystore Secret Name",
  117. "description": "The name of the secret containing the keystore file",
  118. "name": "HTTPS_SECRET",
  119. "value": "eap-app-secret",
  120. "required": false
  121. },
  122. {
  123. "displayName": "Server Keystore Filename",
  124. "description": "The name of the keystore file within the secret",
  125. "name": "HTTPS_KEYSTORE",
  126. "value": "keystore.jks",
  127. "required": false
  128. },
  129. {
  130. "displayName": "Server Keystore Type",
  131. "description": "The type of the keystore file (JKS or JCEKS)",
  132. "name": "HTTPS_KEYSTORE_TYPE",
  133. "value": "",
  134. "required": false
  135. },
  136. {
  137. "displayName": "Server Certificate Name",
  138. "description": "The name associated with the server certificate",
  139. "name": "HTTPS_NAME",
  140. "value": "",
  141. "required": false
  142. },
  143. {
  144. "displayName": "Server Keystore Password",
  145. "description": "The password for the keystore and certificate",
  146. "name": "HTTPS_PASSWORD",
  147. "value": "",
  148. "required": false
  149. },
  150. {
  151. "displayName": "A-MQ Username",
  152. "description": "User name for standard broker user. It is required for connecting to the broker. If left empty, it will be generated.",
  153. "name": "MQ_USERNAME",
  154. "from": "user[a-zA-Z0-9]{3}",
  155. "generate": "expression",
  156. "required": false
  157. },
  158. {
  159. "displayName": "A-MQ Password",
  160. "description": "Password for standard broker user. It is required for connecting to the broker. If left empty, it will be generated.",
  161. "name": "MQ_PASSWORD",
  162. "from": "[a-zA-Z0-9]{8}",
  163. "generate": "expression",
  164. "required": false
  165. },
  166. {
  167. "displayName": "A-MQ Mesh Discovery Type",
  168. "description": "The discovery agent type to use for discovering mesh endpoints. 'dns' will use OpenShift's DNS service to resolve endpoints. 'kube' will use Kubernetes REST API to resolve service endpoints. If using 'kube' the service account for the pod must have the 'view' role, which can be added via 'oc policy add-role-to-user view system:serviceaccount:<namespace>:default' where <namespace> is the project namespace.",
  169. "name": "AMQ_MESH_DISCOVERY_TYPE",
  170. "value": "dns",
  171. "required": false
  172. },
  173. {
  174. "displayName": "A-MQ Storage Limit",
  175. "description": "The A-MQ storage usage limit",
  176. "name": "AMQ_STORAGE_USAGE_LIMIT",
  177. "value": "100 gb",
  178. "required": false
  179. },
  180. {
  181. "displayName": "Github Webhook Secret",
  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. "displayName": "Generic Webhook Secret",
  190. "description": "Generic build trigger secret",
  191. "name": "GENERIC_WEBHOOK_SECRET",
  192. "from": "[a-zA-Z0-9]{8}",
  193. "generate": "expression",
  194. "required": true
  195. },
  196. {
  197. "displayName": "ImageStream Namespace",
  198. "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.",
  199. "name": "IMAGE_STREAM_NAMESPACE",
  200. "value": "openshift",
  201. "required": true
  202. },
  203. {
  204. "displayName": "JGroups Secret Name",
  205. "description": "The name of the secret containing the keystore file",
  206. "name": "JGROUPS_ENCRYPT_SECRET",
  207. "value": "eap-app-secret",
  208. "required": false
  209. },
  210. {
  211. "displayName": "JGroups Keystore Filename",
  212. "description": "The name of the keystore file within the secret",
  213. "name": "JGROUPS_ENCRYPT_KEYSTORE",
  214. "value": "jgroups.jceks",
  215. "required": false
  216. },
  217. {
  218. "displayName": "JGroups Certificate Name",
  219. "description": "The name associated with the server certificate",
  220. "name": "JGROUPS_ENCRYPT_NAME",
  221. "value": "",
  222. "required": false
  223. },
  224. {
  225. "displayName": "JGroups Keystore Password",
  226. "description": "The password for the keystore and certificate",
  227. "name": "JGROUPS_ENCRYPT_PASSWORD",
  228. "value": "",
  229. "required": false
  230. },
  231. {
  232. "displayName": "JGroups Cluster Password",
  233. "description": "JGroups cluster password",
  234. "name": "JGROUPS_CLUSTER_PASSWORD",
  235. "from": "[a-zA-Z0-9]{8}",
  236. "generate": "expression",
  237. "required": true
  238. },
  239. {
  240. "displayName": "Deploy Exploded Archives",
  241. "description": "Controls whether exploded deployment content should be automatically deployed",
  242. "name": "AUTO_DEPLOY_EXPLODED",
  243. "value": "false",
  244. "required": false
  245. },
  246. {
  247. "displayName": "Maven mirror URL",
  248. "description": "Maven mirror to use for S2I builds",
  249. "name": "MAVEN_MIRROR_URL",
  250. "value": "",
  251. "required": false
  252. },
  253. {
  254. "description": "List of directories from which archives will be copied into the deployment folder. If unspecified, all archives in /target will be copied.",
  255. "name": "ARTIFACT_DIR",
  256. "value": "",
  257. "required": false
  258. },
  259. {
  260. "description": "Container memory limit",
  261. "name": "MEMORY_LIMIT",
  262. "value": "1Gi",
  263. "required": false
  264. }
  265. ],
  266. "objects": [
  267. {
  268. "kind": "Service",
  269. "apiVersion": "v1",
  270. "spec": {
  271. "ports": [
  272. {
  273. "port": 8080,
  274. "targetPort": 8080
  275. }
  276. ],
  277. "selector": {
  278. "deploymentConfig": "${APPLICATION_NAME}"
  279. }
  280. },
  281. "metadata": {
  282. "name": "${APPLICATION_NAME}",
  283. "labels": {
  284. "application": "${APPLICATION_NAME}"
  285. },
  286. "annotations": {
  287. "description": "The web server's HTTP port.",
  288. "service.alpha.openshift.io/dependencies": "[{\"name\": \"${APPLICATION_NAME}-amq-tcp\", \"kind\": \"Service\"}]"
  289. }
  290. }
  291. },
  292. {
  293. "kind": "Service",
  294. "apiVersion": "v1",
  295. "spec": {
  296. "ports": [
  297. {
  298. "port": 8443,
  299. "targetPort": 8443
  300. }
  301. ],
  302. "selector": {
  303. "deploymentConfig": "${APPLICATION_NAME}"
  304. }
  305. },
  306. "metadata": {
  307. "name": "secure-${APPLICATION_NAME}",
  308. "labels": {
  309. "application": "${APPLICATION_NAME}"
  310. },
  311. "annotations": {
  312. "description": "The web server's HTTPS port.",
  313. "service.alpha.openshift.io/dependencies": "[{\"name\": \"${APPLICATION_NAME}-amq-tcp\", \"kind\": \"Service\"}]"
  314. }
  315. }
  316. },
  317. {
  318. "kind": "Service",
  319. "apiVersion": "v1",
  320. "spec": {
  321. "clusterIP": "None",
  322. "ports": [
  323. {
  324. "name": "ping",
  325. "port": 8888
  326. }
  327. ],
  328. "selector": {
  329. "deploymentConfig": "${APPLICATION_NAME}"
  330. }
  331. },
  332. "metadata": {
  333. "name": "${APPLICATION_NAME}-ping",
  334. "labels": {
  335. "application": "${APPLICATION_NAME}"
  336. },
  337. "annotations": {
  338. "service.alpha.kubernetes.io/tolerate-unready-endpoints": "true",
  339. "description": "The JGroups ping port for clustering."
  340. }
  341. }
  342. },
  343. {
  344. "kind": "Service",
  345. "apiVersion": "v1",
  346. "spec": {
  347. "ports": [
  348. {
  349. "port": 61616,
  350. "targetPort": 61616
  351. }
  352. ],
  353. "selector": {
  354. "deploymentConfig": "${APPLICATION_NAME}-amq"
  355. }
  356. },
  357. "metadata": {
  358. "name": "${APPLICATION_NAME}-amq-tcp",
  359. "labels": {
  360. "application": "${APPLICATION_NAME}"
  361. },
  362. "annotations": {
  363. "description": "The broker's OpenWire port."
  364. }
  365. }
  366. },
  367. {
  368. "kind": "Service",
  369. "apiVersion": "v1",
  370. "spec": {
  371. "clusterIP": "None",
  372. "ports": [
  373. {
  374. "name": "mesh",
  375. "port": 61616
  376. }
  377. ],
  378. "selector": {
  379. "deploymentConfig": "${APPLICATION_NAME}-amq"
  380. }
  381. },
  382. "metadata": {
  383. "name": "${APPLICATION_NAME}-amq-mesh",
  384. "labels": {
  385. "application": "${APPLICATION_NAME}"
  386. },
  387. "annotations": {
  388. "service.alpha.kubernetes.io/tolerate-unready-endpoints": "true",
  389. "description": "Supports node discovery for mesh formation."
  390. }
  391. }
  392. },
  393. {
  394. "kind": "Route",
  395. "apiVersion": "v1",
  396. "id": "${APPLICATION_NAME}-http",
  397. "metadata": {
  398. "name": "${APPLICATION_NAME}",
  399. "labels": {
  400. "application": "${APPLICATION_NAME}"
  401. },
  402. "annotations": {
  403. "description": "Route for application's HTTP service."
  404. }
  405. },
  406. "spec": {
  407. "host": "${HOSTNAME_HTTP}",
  408. "to": {
  409. "name": "${APPLICATION_NAME}"
  410. }
  411. }
  412. },
  413. {
  414. "kind": "Route",
  415. "apiVersion": "v1",
  416. "id": "${APPLICATION_NAME}-https",
  417. "metadata": {
  418. "name": "secure-${APPLICATION_NAME}",
  419. "labels": {
  420. "application": "${APPLICATION_NAME}"
  421. },
  422. "annotations": {
  423. "description": "Route for application's HTTPS service."
  424. }
  425. },
  426. "spec": {
  427. "host": "${HOSTNAME_HTTPS}",
  428. "to": {
  429. "name": "secure-${APPLICATION_NAME}"
  430. },
  431. "tls": {
  432. "termination": "passthrough"
  433. }
  434. }
  435. },
  436. {
  437. "kind": "ImageStream",
  438. "apiVersion": "v1",
  439. "metadata": {
  440. "name": "${APPLICATION_NAME}",
  441. "labels": {
  442. "application": "${APPLICATION_NAME}"
  443. }
  444. }
  445. },
  446. {
  447. "kind": "BuildConfig",
  448. "apiVersion": "v1",
  449. "metadata": {
  450. "name": "${APPLICATION_NAME}",
  451. "labels": {
  452. "application": "${APPLICATION_NAME}"
  453. }
  454. },
  455. "spec": {
  456. "source": {
  457. "type": "Git",
  458. "git": {
  459. "uri": "${SOURCE_REPOSITORY_URL}",
  460. "ref": "${SOURCE_REPOSITORY_REF}"
  461. },
  462. "contextDir": "${CONTEXT_DIR}"
  463. },
  464. "strategy": {
  465. "type": "Source",
  466. "sourceStrategy": {
  467. "env": [
  468. {
  469. "name": "MAVEN_MIRROR_URL",
  470. "value": "${MAVEN_MIRROR_URL}"
  471. },
  472. {
  473. "name": "ARTIFACT_DIR",
  474. "value": "${ARTIFACT_DIR}"
  475. }
  476. ],
  477. "forcePull": true,
  478. "from": {
  479. "kind": "ImageStreamTag",
  480. "namespace": "${IMAGE_STREAM_NAMESPACE}",
  481. "name": "jboss-eap64-openshift:1.7"
  482. }
  483. }
  484. },
  485. "output": {
  486. "to": {
  487. "kind": "ImageStreamTag",
  488. "name": "${APPLICATION_NAME}:latest"
  489. }
  490. },
  491. "triggers": [
  492. {
  493. "type": "GitHub",
  494. "github": {
  495. "secret": "${GITHUB_WEBHOOK_SECRET}"
  496. }
  497. },
  498. {
  499. "type": "Generic",
  500. "generic": {
  501. "secret": "${GENERIC_WEBHOOK_SECRET}"
  502. }
  503. },
  504. {
  505. "type": "ImageChange",
  506. "imageChange": {}
  507. },
  508. {
  509. "type": "ConfigChange"
  510. }
  511. ]
  512. }
  513. },
  514. {
  515. "kind": "DeploymentConfig",
  516. "apiVersion": "v1",
  517. "metadata": {
  518. "name": "${APPLICATION_NAME}",
  519. "labels": {
  520. "application": "${APPLICATION_NAME}"
  521. }
  522. },
  523. "spec": {
  524. "strategy": {
  525. "type": "Recreate"
  526. },
  527. "triggers": [
  528. {
  529. "type": "ImageChange",
  530. "imageChangeParams": {
  531. "automatic": true,
  532. "containerNames": [
  533. "${APPLICATION_NAME}"
  534. ],
  535. "from": {
  536. "kind": "ImageStreamTag",
  537. "name": "${APPLICATION_NAME}:latest"
  538. }
  539. }
  540. },
  541. {
  542. "type": "ConfigChange"
  543. }
  544. ],
  545. "replicas": 1,
  546. "selector": {
  547. "deploymentConfig": "${APPLICATION_NAME}"
  548. },
  549. "template": {
  550. "metadata": {
  551. "name": "${APPLICATION_NAME}",
  552. "labels": {
  553. "deploymentConfig": "${APPLICATION_NAME}",
  554. "application": "${APPLICATION_NAME}"
  555. }
  556. },
  557. "spec": {
  558. "terminationGracePeriodSeconds": 60,
  559. "containers": [
  560. {
  561. "name": "${APPLICATION_NAME}",
  562. "image": "${APPLICATION_NAME}",
  563. "imagePullPolicy": "Always",
  564. "resources": {
  565. "limits": {
  566. "memory": "${MEMORY_LIMIT}"
  567. }
  568. },
  569. "volumeMounts": [
  570. {
  571. "name": "eap-keystore-volume",
  572. "mountPath": "/etc/eap-secret-volume",
  573. "readOnly": true
  574. },
  575. {
  576. "name": "eap-jgroups-keystore-volume",
  577. "mountPath": "/etc/jgroups-encrypt-secret-volume",
  578. "readOnly": true
  579. }
  580. ],
  581. "livenessProbe": {
  582. "exec": {
  583. "command": [
  584. "/bin/bash",
  585. "-c",
  586. "/opt/eap/bin/livenessProbe.sh"
  587. ]
  588. },
  589. "initialDelaySeconds": 60
  590. },
  591. "readinessProbe": {
  592. "exec": {
  593. "command": [
  594. "/bin/bash",
  595. "-c",
  596. "/opt/eap/bin/readinessProbe.sh"
  597. ]
  598. }
  599. },
  600. "ports": [
  601. {
  602. "name": "jolokia",
  603. "containerPort": 8778,
  604. "protocol": "TCP"
  605. },
  606. {
  607. "name": "http",
  608. "containerPort": 8080,
  609. "protocol": "TCP"
  610. },
  611. {
  612. "name": "https",
  613. "containerPort": 8443,
  614. "protocol": "TCP"
  615. },
  616. {
  617. "name": "ping",
  618. "containerPort": 8888,
  619. "protocol": "TCP"
  620. }
  621. ],
  622. "env": [
  623. {
  624. "name": "MQ_SERVICE_PREFIX_MAPPING",
  625. "value": "${APPLICATION_NAME}-amq=MQ"
  626. },
  627. {
  628. "name": "MQ_JNDI",
  629. "value": "${MQ_JNDI}"
  630. },
  631. {
  632. "name": "MQ_USERNAME",
  633. "value": "${MQ_USERNAME}"
  634. },
  635. {
  636. "name": "MQ_PASSWORD",
  637. "value": "${MQ_PASSWORD}"
  638. },
  639. {
  640. "name": "MQ_PROTOCOL",
  641. "value": "tcp"
  642. },
  643. {
  644. "name": "MQ_QUEUES",
  645. "value": "${MQ_QUEUES}"
  646. },
  647. {
  648. "name": "MQ_TOPICS",
  649. "value": "${MQ_TOPICS}"
  650. },
  651. {
  652. "name": "MQ_SERIALIZABLE_PACKAGES",
  653. "value": "${MQ_SERIALIZABLE_PACKAGES}"
  654. },
  655. {
  656. "name": "JGROUPS_PING_PROTOCOL",
  657. "value": "openshift.DNS_PING"
  658. },
  659. {
  660. "name": "OPENSHIFT_DNS_PING_SERVICE_NAME",
  661. "value": "${APPLICATION_NAME}-ping"
  662. },
  663. {
  664. "name": "OPENSHIFT_DNS_PING_SERVICE_PORT",
  665. "value": "8888"
  666. },
  667. {
  668. "name": "HTTPS_KEYSTORE_DIR",
  669. "value": "/etc/eap-secret-volume"
  670. },
  671. {
  672. "name": "HTTPS_KEYSTORE",
  673. "value": "${HTTPS_KEYSTORE}"
  674. },
  675. {
  676. "name": "HTTPS_KEYSTORE_TYPE",
  677. "value": "${HTTPS_KEYSTORE_TYPE}"
  678. },
  679. {
  680. "name": "HTTPS_NAME",
  681. "value": "${HTTPS_NAME}"
  682. },
  683. {
  684. "name": "HTTPS_PASSWORD",
  685. "value": "${HTTPS_PASSWORD}"
  686. },
  687. {
  688. "name": "JGROUPS_ENCRYPT_SECRET",
  689. "value": "${JGROUPS_ENCRYPT_SECRET}"
  690. },
  691. {
  692. "name": "JGROUPS_ENCRYPT_KEYSTORE_DIR",
  693. "value": "/etc/jgroups-encrypt-secret-volume"
  694. },
  695. {
  696. "name": "JGROUPS_ENCRYPT_KEYSTORE",
  697. "value": "${JGROUPS_ENCRYPT_KEYSTORE}"
  698. },
  699. {
  700. "name": "JGROUPS_ENCRYPT_NAME",
  701. "value": "${JGROUPS_ENCRYPT_NAME}"
  702. },
  703. {
  704. "name": "JGROUPS_ENCRYPT_PASSWORD",
  705. "value": "${JGROUPS_ENCRYPT_PASSWORD}"
  706. },
  707. {
  708. "name": "JGROUPS_CLUSTER_PASSWORD",
  709. "value": "${JGROUPS_CLUSTER_PASSWORD}"
  710. },
  711. {
  712. "name": "AUTO_DEPLOY_EXPLODED",
  713. "value": "${AUTO_DEPLOY_EXPLODED}"
  714. }
  715. ]
  716. }
  717. ],
  718. "volumes": [
  719. {
  720. "name": "eap-keystore-volume",
  721. "secret": {
  722. "secretName": "${HTTPS_SECRET}"
  723. }
  724. },
  725. {
  726. "name": "eap-jgroups-keystore-volume",
  727. "secret": {
  728. "secretName": "${JGROUPS_ENCRYPT_SECRET}"
  729. }
  730. }
  731. ]
  732. }
  733. }
  734. }
  735. },
  736. {
  737. "kind": "DeploymentConfig",
  738. "apiVersion": "v1",
  739. "metadata": {
  740. "name": "${APPLICATION_NAME}-amq",
  741. "labels": {
  742. "application": "${APPLICATION_NAME}"
  743. }
  744. },
  745. "spec": {
  746. "strategy": {
  747. "type": "Rolling",
  748. "rollingParams": {
  749. "maxSurge": 0
  750. }
  751. },
  752. "triggers": [
  753. {
  754. "type": "ImageChange",
  755. "imageChangeParams": {
  756. "automatic": true,
  757. "containerNames": [
  758. "${APPLICATION_NAME}-amq"
  759. ],
  760. "from": {
  761. "kind": "ImageStreamTag",
  762. "namespace": "${IMAGE_STREAM_NAMESPACE}",
  763. "name": "jboss-amq-62:1.7"
  764. }
  765. }
  766. },
  767. {
  768. "type": "ConfigChange"
  769. }
  770. ],
  771. "replicas": 1,
  772. "selector": {
  773. "deploymentConfig": "${APPLICATION_NAME}-amq"
  774. },
  775. "template": {
  776. "metadata": {
  777. "name": "${APPLICATION_NAME}-amq",
  778. "labels": {
  779. "deploymentConfig": "${APPLICATION_NAME}-amq",
  780. "application": "${APPLICATION_NAME}"
  781. }
  782. },
  783. "spec": {
  784. "terminationGracePeriodSeconds": 60,
  785. "containers": [
  786. {
  787. "name": "${APPLICATION_NAME}-amq",
  788. "image": "jboss-amq-62",
  789. "imagePullPolicy": "Always",
  790. "readinessProbe": {
  791. "exec": {
  792. "command": [
  793. "/bin/bash",
  794. "-c",
  795. "/opt/amq/bin/readinessProbe.sh"
  796. ]
  797. }
  798. },
  799. "ports": [
  800. {
  801. "name": "jolokia",
  802. "containerPort": 8778,
  803. "protocol": "TCP"
  804. },
  805. {
  806. "name": "amqp",
  807. "containerPort": 5672,
  808. "protocol": "TCP"
  809. },
  810. {
  811. "name": "amqp-ssl",
  812. "containerPort": 5671,
  813. "protocol": "TCP"
  814. },
  815. {
  816. "name": "mqtt",
  817. "containerPort": 1883,
  818. "protocol": "TCP"
  819. },
  820. {
  821. "name": "stomp",
  822. "containerPort": 61613,
  823. "protocol": "TCP"
  824. },
  825. {
  826. "name": "stomp-ssl",
  827. "containerPort": 61612,
  828. "protocol": "TCP"
  829. },
  830. {
  831. "name": "tcp",
  832. "containerPort": 61616,
  833. "protocol": "TCP"
  834. },
  835. {
  836. "name": "tcp-ssl",
  837. "containerPort": 61617,
  838. "protocol": "TCP"
  839. }
  840. ],
  841. "volumeMounts": [
  842. {
  843. "mountPath": "/opt/amq/data/kahadb",
  844. "name": "${APPLICATION_NAME}-amq-pvol"
  845. }
  846. ],
  847. "env": [
  848. {
  849. "name": "AMQ_USER",
  850. "value": "${MQ_USERNAME}"
  851. },
  852. {
  853. "name": "AMQ_PASSWORD",
  854. "value": "${MQ_PASSWORD}"
  855. },
  856. {
  857. "name": "AMQ_TRANSPORTS",
  858. "value": "${MQ_PROTOCOL}"
  859. },
  860. {
  861. "name": "AMQ_QUEUES",
  862. "value": "${MQ_QUEUES}"
  863. },
  864. {
  865. "name": "AMQ_TOPICS",
  866. "value": "${MQ_TOPICS}"
  867. },
  868. {
  869. "name": "MQ_SERIALIZABLE_PACKAGES",
  870. "value": "${MQ_SERIALIZABLE_PACKAGES}"
  871. },
  872. {
  873. "name": "AMQ_SPLIT",
  874. "value": "${AMQ_SPLIT}"
  875. },
  876. {
  877. "name": "AMQ_MESH_DISCOVERY_TYPE",
  878. "value": "${AMQ_MESH_DISCOVERY_TYPE}"
  879. },
  880. {
  881. "name": "AMQ_MESH_SERVICE_NAME",
  882. "value": "${APPLICATION_NAME}-amq-mesh"
  883. },
  884. {
  885. "name": "AMQ_MESH_SERVICE_NAMESPACE",
  886. "valueFrom": {
  887. "fieldRef": {
  888. "fieldPath": "metadata.namespace"
  889. }
  890. }
  891. },
  892. {
  893. "name": "AMQ_STORAGE_USAGE_LIMIT",
  894. "value": "${AMQ_STORAGE_USAGE_LIMIT}"
  895. }
  896. ]
  897. }
  898. ],
  899. "volumes": [
  900. {
  901. "name": "${APPLICATION_NAME}-amq-pvol",
  902. "persistentVolumeClaim": {
  903. "claimName": "${APPLICATION_NAME}-amq-claim"
  904. }
  905. }
  906. ]
  907. }
  908. }
  909. }
  910. },
  911. {
  912. "apiVersion": "v1",
  913. "kind": "PersistentVolumeClaim",
  914. "metadata": {
  915. "name": "${APPLICATION_NAME}-amq-claim",
  916. "labels": {
  917. "application": "${APPLICATION_NAME}"
  918. }
  919. },
  920. "spec": {
  921. "accessModes": [
  922. "ReadWriteOnce"
  923. ],
  924. "resources": {
  925. "requests": {
  926. "storage": "${VOLUME_CAPACITY}"
  927. }
  928. }
  929. }
  930. }
  931. ]
  932. }