ä¿¡é Œãšåžæã«ã€ããŠèããããšããããªããããããããŒã¿ããŒã¹ç®¡çã·ã¹ãã ã§è¡ã£ãã»ã©ã®çµéšã¯ãªãã£ãã§ãããã ãŸããæ¬åœã«ãããã¯ããŒã¿ããŒã¹ã§ãïŒ ååã«ã¯å®å šãªæå³ãå«ãŸããŸã-ããŒã¿ãä¿åãããå Žæãã¡ã€ã³ã¿ã¹ã¯ã¯STORAGEã§ãã ãããŠãæãæ²ããããšã¯ããã€ãã®ããã«ããããã®ä¿¡å¿µã¯ãã補åãäžã®ãã®ãããª1ã€ã®æ»ãã DBã®æ®éªžã«åãããŠããŸãã
ãããŠäœããã¹ããïŒ -ããªããå°ããŸãã ãµãŒããŒã«ã¯äœããããã€ããªãã§ãã ãããè¿ä¿¡ããŸãã å°ãªããšãäžæçã«ãããã確å®ãã€è¿ éã«ãããèªäœã修埩ã§ãããã®ã¯ãããŸããïŒ
ãã®èšäºã§ã¯ããã¥ãŒãã³ã°ã®çµéšã«ã€ããŠã話ããŸãã ã»ãŒ Googleã®å¥ã®ãã§ãŒã«ãªãŒããŒãœãªã¥ãŒã·ã§ã³å
ã®äžæ»
ã®Postgresqlã¯ã©ã¹ã¿ãŒ-KubernetesïŒå¥åk8sïŒ
å 容
ãã®èšäºã¯äºæ³ä»¥äžã«æ²èŒããããããã³ãŒãã«ã¯å€ãã®ãªã³ã¯ããããäž»ã«ç§ãã¡ã話ããŠããã³ã³ããã¹ãã®ã³ãŒããžã®ãªã³ã¯ããããŸãã
ããã«ãããã«çµæã«ãžã£ã³ãããããã«ããã£ãã¡ãªäººãå«ãç®æ¬¡ãåå°ããŸãã
- ææŠãã
- ã°ãŒã°ã«ãœãªã¥ãŒã·ã§ã³
- çµ±åããã³ã¢ã»ã³ããªãœãªã¥ãŒã·ã§ã³
- çµæ
- 䜿çšãããããã¥ã¡ã³ããšè³æ
ææŠãã
ã»ãšãã©ãã¹ãŠã®ã¢ããªã±ãŒã·ã§ã³ã«ããŒã¿ã¹ãã¬ãŒãžãå¿ èŠã§ãã ãŸãããããã¯ãŒã¯ãŸãã¯ç©çãµãŒããŒäžã®éå¢ã«èãããã®ã¹ãã¬ãŒãžãæã€ããšã¯ãæèœãªã¢ãŒããã¯ãã«ãšã£ãŠè¯ãå£èª¿ã§ãã å¥ã®åŽé¢ã¯ã競åãã倧èŠæš¡ãªãµãŒãã¹èŠæ±ã§ãã£ãŠããµãŒãã¹ã®é«å¯çšæ§ã§ããããã¯ãå¿ èŠã«å¿ããŠç°¡åã«ã¹ã±ãŒãªã³ã°ã§ããããšãæå³ããŸãã
解決ãã¹ãåé¡ãçºçããåèšïŒ
- ç©ççã«åæ£ããããµãŒãã¹
- ãã©ã³ã¹èª¿æŽ
- æ°ããããŒãã®è¿œå ã«ããç¡å¶éã®ã¹ã±ãŒãªã³ã°
- éä¿¡ããŒãã®é害ãç Žå£ãæ倱ããã®èªåå埩
- åäžé害ç¹ã®æ¬ åŠ
èè ã®å®æç信念ã®ç¹ç°æ§ã«ããè¿œå ã®ãã€ã³ãïŒ
- Postgres ïŒç¡æã§å©çšå¯èœãªæãåŠè¡çã§äžè²«æ§ã®ããRDBMSãœãªã¥ãŒã·ã§ã³ïŒ
- Dockerããã±ãŒãž
- Kubernetesã€ã³ãã©ã¹ãã©ã¯ãã£ã®èª¬æ
å³ã§ã¯ã次ã®ããã«ãªããŸãã
master (primary node1) --\ |- slave1 (node2) ---\ / balancer \ | |- slave2 (node3) ----|---| |----client |- slave3 (node4) ---/ \ balancer / |- slave4 (node5) --/
å ¥åã®å¯Ÿè±¡ïŒ
- ããå€ãã®èªã¿åãèŠæ±ïŒæžã蟌ã¿ã«å¯ŸããŠïŒ
- å¹³åããæ倧2åã®ããŒã¯ã§ã®ç·åœ¢è² è·å¢å
ã°ãŒã°ã«ãœãªã¥ãŒã·ã§ã³
ITã®åé¡ã解決ããå°é家ã§ããç§ã¯ãéåçãªèããæ±ããããšã«ããŸããããpostgres cluster kubernetesãã¯ãã¿ã®æããpostgres cluster Dockerãã¯ãã¿ã®æããpostgres clusterãã¯ç§ãã¡ãæŠããªããã°ãªããªãã£ãããã€ãã®éžæè¢ã§ãã
æ°åã害ããã®ã¯ãæ£æ°ãªDockerã¢ã»ã³ããªã®æ¬ åŠãšã¯ã©ã¹ã¿ãªã³ã°ã®ãªãã·ã§ã³ã®èª¬æã§ããã Kubernetesã¯èšããŸã§ããããŸããã ãšããã§ãMysqlã«ã¯å€ãã®ãªãã·ã§ã³ã¯ãããŸããã§ãããããŸã ãããŸããã å°ãªããšãGaleraã®å ¬åŒk8sãªããžããªïŒ Mysql ã¯ã©ã¹ã¿ãŒïŒã®äŸãæ°ã«å ¥ã£ã
ã°ãŒã°ã«ã¯ãåé¡ã¯èªåã§æåã¢ãŒãã§è§£æ±ºããªããã°ãªããªãããšãæããã«ããŸãã...ãããããå°ãªããšãæ£ãã°ã£ããã³ããšèšäºã®å©ããåããŠãç§ã¯æ¯ãåããŸããã
æªã決å®ãšåãå ¥ããããªã決å®
ãã®æ®µèœã®ãã¹ãŠã®ãã€ã³ãã¯äž»èŠ³çã§ãããããªãåäžã§ãããå®è¡å¯èœã§ããããšã«ããã«æ³šæããŸãã ããããç§ã®çµéšãšæ¬èœã«é Œã£ãŠãããããæã€å¿ èŠããããŸããã
誰ããïŒäœããã®çç±ã§ïŒæ®éçãªè§£æ±ºçãäœæãããšãããã®ãããªãã®ã¯ããã°ããé ããç¶æããã®ãé£ããããã«æããŸãã åãããšãPgpoolã§ãèµ·ãããŸãããPgpoolã¯ã»ãšãã©ãã¹ãŠãå®è¡ã§ããŸãã
- ãã©ã³ã¹èª¿æŽ
- æ¥ç¶ã®ããã¯ãä¿åããŠãããŒã¿ããŒã¹ãžã®æ¥ç¶ãšã¢ã¯ã»ã¹é床ãæé©åãã
- ããŸããŸãªã¬ããªã±ãŒã·ã§ã³ãªãã·ã§ã³ ïŒã¹ããªãŒã ãã¹ããŒïŒã®ãµããŒã
- èšé²çšã®ãã©ã€ããªãµãŒããŒã®èªåæ€åº ãããã¯ã¯ã©ã¹ã¿ãŒå ã®ããŒã«ãåç·šæãããšãã«éèŠã§ãã
- ãã§ãŒã«ãªãŒããŒ/ãã§ãŒã«ããã¯ããµããŒã
- ãã¹ã¿ãŒãã¹ã¿ãŒè€è£œ
- åäžé害ç¹ãæ ¹çµ¶ããããã®è€æ°ã®PgpoolããŒãã®èª¿æŽãããäœæ¥ã
ç§ã¯æåã®4ã€ã®ãã€ã³ããæçšã§ãããšæããä»ã®äººã®åé¡ãç解ããæ€èšããäžã§ããã決ããŸããã
- Pgpool2ã®ãªã«ããªã§ã¯ã次ã®ãŠã£ã¶ãŒãã決å®ããããã®ã·ã¹ãã ã¯æäŸãããŸããããã¹ãŠã®ããžãã¯ã¯ããã§ã€ã«ãªãŒããŒ/ãã§ã€ã«ããã¯ã³ãã³ãã§èª¬æããå¿ èŠããããŸã
- ãã¹ã¿ãã¹ã¿ã¬ããªã±ãŒã·ã§ã³ã䜿çšããèšé²æéã¯ãããŒãã®æ°ã«é¢ä¿ãªãããªãã·ã§ã³ãªãã§2åã«ççž®ãããŸã...ãŸããå°ãªããšãçŽç·çã«ã¯å¢å ããŸãã
- ã«ã¹ã±ãŒãã¯ã©ã¹ã¿ã®æ§ç¯æ¹æ³ïŒ1ã€ã®ã¹ã¬ãŒããåã®ã¹ã¬ãŒãããèªã¿åãå ŽåïŒ-ãŸã£ããæ確ã§ã¯ãããŸãã
- ãã¡ãããPgpoolããã®å åŒã«ã€ããŠç¥ã£ãŠãããé£æ¥ããŒãã§åé¡ãçºçããå Žåã«ããã«ã¢ã¯ãã£ããªã³ã¯ã«ãªãããšãã§ããã®ã¯è¯ãããšã§ãããKubernetesã¯ãã®åé¡ã解決ããŸããããã«ãããäžè¬çã«ãã€ã³ã¹ããŒã«ãããŠãããã¹ãŠã®ãµãŒãã¹ã«å¯ŸããŠåãåäœãä¿èšŒãããŸã
å®éã«ããã§ã«æ £ã芪ããã§ããŠããã«äœ¿çšã§ããStreaming Replicationã®çµæãèªãã§æ¯èŒããã®ã§ãElephantsã«ã€ããŠããèããªãããšã決ããã®ã¯ç°¡åã§ããã
ãããŠãä»ã®ãã¹ãŠã«ã€ããŠããããžã§ã¯ãã®ãµã€ãã®æåã®ããŒãžã§ãå ·äœçãªã·ã¹ãã èŠä»¶ããªãéããpostgres 9.0+ã§ã¯ãSlonyã¯å¿ èŠãªããšæžããŠããŸãã
- éšåè€è£œ
- ä»ã®ãœãªã¥ãŒã·ã§ã³ãšã®çµ±åïŒããã³ãã£ã¹ããšãã«ã«ããïŒ
- è¿œå ã®ã¬ããªã±ãŒã·ã§ã³åäœ
äžè¬çã«ãSlonyã¯ã±ãŒãã§ã¯ãªãããã«æããŸã...å°ãªããšãããã3ã€ã®ç¹å®ã®ã¿ã¹ã¯ãæã£ãŠããªããã°ã
çæ³çãªåæ¹åã¬ããªã±ãŒã·ã§ã³ã¢ãããŒãã®ãªãã·ã§ã³ãæ€èšããæ€èšããçµæã被害è
ã¯äžéšã®ã¢ããªã±ãŒã·ã§ã³ã®å¯¿åœãšäºææ§ããªãããšãå€æããŸããã é床ã¯èšããŸã§ããªãããã©ã³ã¶ã¯ã·ã§ã³ãšè€éãªã¯ãšãªïŒ SELECT FOR UPDATE
ãªã©ïŒã®æäœã«ã¯å¶éããããŸãã
ç§ã¯ãã®åé¡ã«é¢ããŠããã»ã©æŽç·ŽãããŠããªãå¯èœæ§ããããŸãããç§ãèŠããã®ã¯ãã®èããæ®ãã®ã«ååã§ããã ãããŠãé ãæ©ãŸããšãæžã蟌ã¿æäœã匷åãããã·ã¹ãã ã§ã¯ããªã¬ãŒã·ã§ãã«ããŒã¿ããŒã¹ã§ã¯ãªãããŸã£ããç°ãªããã¯ãããžãŒãå¿
èŠã§ããããã«æããŸããã
çµ±åããã³ã¢ã»ã³ããªãœãªã¥ãŒã·ã§ã³
äŸã§ã¯ããœãªã¥ãŒã·ã§ã³ãåºæ¬çã«ã©ã®ããã«èŠããã¹ãããã³ãŒãã§ã¯ã©ã®ããã«ãªã£ãŠãããã«ã€ããŠèª¬æããŸãã ã¯ã©ã¹ã¿ãŒãäœæããããã«ãååãšããŠKubernetesïŒdocker-composeã®äŸããããŸãïŒãDockerãçšæããå¿ èŠã¯ãããŸããã ãã®ãšããCPMïŒã³ããŒ-貌ãä»ã-å€æŽïŒãœãªã¥ãŒã·ã§ã³ãšããŠã§ã¯ãªããã¹ãããããã€ã³ã¹ããŒã«ããããã®ã¬ã€ããšããŠã説æãããŠãããã¹ãŠã®ãã®ã圹ç«ã¡ãŸãã
ãã¹ã¿ãŒãšã¹ã¬ãŒãã®ä»£ããã«ãã©ã€ããªãšã¹ã¿ã³ãã€
Postgresqlã®ååãããã¹ã¿ãŒããšãã¹ã¬ãŒãããšããçšèªãæåŠããã®ã¯ãªãã§ããïŒ..ããŒããééã£ãŠããå¯èœæ§ããããŸããã骚æãã®æ£ããã®ããã«å¥Žé·å¶åºŠãæªããšèšãããŠããŸãã ããã§ããã
æåã«è¡ãããšã¯ããã©ã€ããªãµãŒããŒããªã³ã«ãã次ã«æåã®ã¹ã¿ã³ãã€ã¬ã€ã€ãŒããªã³ã«ãããã®åŸ2çªç®ã®ã¬ã€ã€ãŒããªã³ã«ããããšã§ã-ã¿ã¹ã¯ã«å¿ãããã¹ãŠã ãããããã¹ããªãŒãã³ã°ã¬ããªã±ãŒã·ã§ã³ãæå¹ã«ããããã®æ§æã䜿çšããŠããã©ã€ããª/ã¹ã¿ã³ãã€ã¢ãŒãã§éåžžã®PostgresqlãµãŒããŒãæå¹ã«ããç°¡åãªæé ãååŸããŸãã
wal_level = hot_standby max_wal_senders = 5 wal_keep_segments = 5001 hot_standby = on
ã³ã¡ã³ãå ã®ãã¹ãŠã®ãã©ã¡ãŒã¿ãŒã«ã¯ç°¡åãªèª¬æããããŸãããç°¡åã«èšããšããã®æ§æã¯ãµãŒããŒãã¯ã©ã¹ã¿ãŒã®äžéšã§ããããšããµãŒããŒã«èªèããããããä»ã®ã¯ã©ã€ã¢ã³ãã«WALãã°ã®èªã¿åããèš±å¯ããå¿ èŠããããŸãã ããã«ããªã«ããªäžã«ãªã¯ãšã¹ããèš±å¯ããŸãã ãã®çš®ã®ã¬ããªã±ãŒã·ã§ã³ã埮調æŽããæ¹æ³ã®åªãã説æã¯ã Postgresql Wikiã«ãããŸãã
ã¯ã©ã¹ã¿ãŒã®æåã®ãµãŒããŒãåãåã£ããããã«ããã©ã€ããªãã©ãã«ããããç¥ã£ãŠããã¹ã¿ã³ããŒããªã³ã«ããããšãã§ããŸãã
ããã§ã®ç§ã®ã¿ã¹ã¯ã¯ãã¢ãŒãã«å¿ããŠãäœåã«å«ãŸãããŠãããŒãµã«Docker Imageã€ã¡ãŒãžãçµã¿ç«ãŠãããšã«ãªããŸãããããã¯æ¬¡ã®ãããªãã®ã§ãã
- ãã©ã€ããªã®å Žå ïŒ
- Repmgrãæ§æããŸãïŒããã«ã€ããŠã¯å°ãåŸã§ïŒ
- ã¢ããªã±ãŒã·ã§ã³ã®ããŒã¿ããŒã¹ãšãŠãŒã¶ãŒãäœæããŸã
- ã¬ããªã±ãŒã·ã§ã³ãç£èŠããã³ãµããŒãããããŒã¿ããŒã¹ãšãŠãŒã¶ãŒãäœæããŸã
- æ§æïŒ
postgresql.conf
ïŒãæŽæ°ããå€éšïŒpg_hba.conf
ïŒãããŠãŒã¶ãŒãžã®ã¢ã¯ã»ã¹ãéããŸã - ããã¯ã°ã©ãŠã³ãã§PostgresqlãµãŒãã¹ãéå§ããŸã
- Repmgrã«ãã¹ã¿ãŒãšããŠç»é²
-
repmgrd
èµ·åãrepmgrd
-ã¬ããªã±ãŒã·ã§ã³ãç£èŠããããã®Repmgrããã®ããŒã¢ã³ïŒè©³çŽ°ã¯åŸã»ã©ïŒ
- ã¹ã¿ã³ãã€ã®å Žå ïŒ
- Repmgrã䜿çšããŠãã©ã€ããªãµãŒããŒãè€è£œããŸãïŒãã¹ãŠã®æ§æã§ã
$PGDATA
ãã£ã¬ã¯ããªãã³ããŒããã ãã§ãïŒ - Repmgrãæ§æããŸã
- ããã¯ã°ã©ãŠã³ãã§PostgresqlãµãŒãã¹ãéå§ããŸã-ã¯ããŒã³äœæåŸããµãŒãã¹ã¯ã¹ã¿ã³ãã€ã§ããããã©ã€ããªã«å¿ å®ã«åŸãããšãæ£åžžã«èªèããŸã
- Repmgrã«ã¹ã¬ãŒããšããŠç»é²
-
repmgrd
éå§ãrepmgrd
- Repmgrã䜿çšããŠãã©ã€ããªãµãŒããŒãè€è£œããŸãïŒãã¹ãŠã®æ§æã§ã
ã·ãŒã±ã³ã¹ã¯ããããã¹ãŠã®æäœã«ãšã£ãŠéèŠã§ããããã sleep
ã³ãŒãã«è©°ã蟌ãŸããŸã ã ç§ã¯ç¥ã£ãŠããŸã-è¯ãã¯ãããŸãããããã¹ãŠã®ã³ã³ãããäžåºŠã«èµ·åããå¿
èŠãããå ŽåïŒäŸãã°ã docker-compose up
ïŒã«ENVå€æ°ã䜿çšããŠé
延ãèšå®ãããšäŸ¿å©ã§ã
ãã®ã€ã¡ãŒãžã®ãã¹ãŠã®å€æ°ã¯ã docker-compose
ãã¡ã€ã«ã§èª¬æãããŠããŸã ã
ã¹ã¿ã³ãã€ãµãŒãã¹ã®ç¬¬1å±€ãšç¬¬2å±€ã®å®å šãªéãã¯ã2çªç®ã®ãã¹ã¿ãŒã®å Žåããã©ã€ããªã§ã¯ãªãã第1å±€ã®ãµãŒãã¹ã§ãããšããããšã§ãã 2çªç®ã®ãšã·ã¥ãã³ã¯ãæåã®ãšã·ã§ãã³ã®åŸã«é ããŠéå§ããå¿ èŠãããããšãå¿ããªãã§ãã ããã
ã¹ããªãããã¬ã€ã³ãšã¯ã©ã¹ã¿ãŒå ã®æ°ãããªãŒããŒã®éžåº
ã¹ããªãããã¬ã€ã³ -ã¯ã©ã¹ã¿ãŒã®ç°ãªãã»ã°ã¡ã³ããæ°ãããã¹ã¿ãŒãäœæ/éžæããåé¡ã解決ãããšèããããšãã§ããç¶æ³ã
ããã¯1ã€ã§ããã Repmgrã解決ã«åœ¹ç«ã£ãå¯äžã®åé¡ããã¯ã»ã©é ããã®ã§ãã
æ¬è³ªçã«ãããã¯æ¬¡ã®ããšãã§ãããããŒãžã£ãŒã§ãã
- ãã¹ã¿ãŒ ïŒãã¹ã¿ãŒ-Repmgrã®èŠ³ç¹ããïŒãè€è£œããçãŸãå€ãã£ãã¹ã¬ãŒãã«èªåçã«æ³šå ¥ããŸãã
- ãã¹ã¿ãŒã®æ»ã§ã¯ã©ã¹ã¿ãŒãèãããã®ãæäŒã£ãŠãã ããã
- èªåã¢ãŒããŸãã¯æåã¢ãŒãã§ã¯ãRepmgrã¯æ°ãããã¹ã¿ãŒãéžæãããã¹ãŠã®ã¹ã¬ãŒããµãŒãã¹ãåæ§æããŠæ°ãããªãŒããŒã«åŸãããšãã§ããŸã ã
- ã¯ã©ã¹ã¿ãŒããããŒããåé€ãã
- ã¯ã©ã¹ã¿ãŒã®ç¶æ ãç£èŠãã
- ã¯ã©ã¹ã¿ãŒå ã®ã€ãã³ãã® ã³ãã³ããå®è¡ãã
ãã®å Žåã repmgrd
ã¯ãã³ã³ããå
ã®ã¡ã€ã³ããã»ã¹ã«ãã£ãŠèµ·åãããã¯ã©ã¹ã¿ãŒã®æŽåæ§ãç£èŠããŸãã ãã¹ã¿ãŒãµãŒããŒãžã®ã¢ã¯ã»ã¹ã倱ãããç¶æ³ã§ã¯ãRepmgrã¯çŸåšã®ã¯ã©ã¹ã¿ãŒæ§é ãåæãã次ã®ãã¹ã¿ãŒã«ãªããŠãŒã¶ãŒã決å®ããããšããŸãã åœç¶ãRepmgrã¯ãã¹ããªãããã¬ã€ã³ç¶æ
ãäœæãããå¯äžã®æ£ãããã¹ã¿ãŒãéžæããã®ã«ååãªã»ã©è³¢ãã§ãã
Pgpool-II- æ³³ã æ¥ç¶ã®ããŒã«
ã·ã¹ãã ã®æåŸã®éšåã¯Pgpoolã§ãã æªãå€æã«é¢ããã»ã¯ã·ã§ã³ã§æžããããã«ããµãŒãã¹ã¯ãŸã ãã®ä»äºãããŠããŸãïŒ
- ã¯ã©ã¹ã¿ãŒã®ãã¹ãŠã®ãã©ã€ãã«éã§è² è·ãåæ£ããŸã
- æ¥ç¶èšè¿°åãä¿åããŠãããŒã¿ããŒã¹ã®ã¢ã¯ã»ã¹é床ãæé©åããŸã
- ç§ãã¡ã®å Žåãã¹ããªãŒãã³ã°ã¬ããªã±ãŒã·ã§ã³-ãã¹ã¿ãŒãèªåçã«æ€åºããæžã蟌ã¿èŠæ±ã«äœ¿çšããŸãã
çµæãšããŠãããªãã·ã³ãã«ãªDocker ImageãååŸããŸãããããã¯ãèµ·åæã«ãPgpoolãä»ããŠmd5æ¿èªãæž¡ãããšãã§ããããŒããšãŠãŒã¶ãŒã®ã»ããã§åäœããããã«æ§æãããŸãïŒ ããã¯ç°¡åã§ã¯ãããŸãã ïŒ
åäžé害ç¹ãåãé€ãããã«ã¿ã¹ã¯ãé »ç¹ã«çºçããŸãããã®å Žåããã®ãã€ã³ãã¯pgpoolãµãŒãã¹ã§ããããã¹ãŠã®èŠæ±ããããã·ããããŒã¿ã«ã¢ã¯ã»ã¹ããæ¹æ³ã§æã匱ããªã³ã¯ã«ãªãå¯èœæ§ããããŸãã
幞ããªããšã«ããã®å Žåãk8sã¯åé¡ã解決ããå¿
èŠãªæ°ã®ãµãŒãã¹ã¬ããªã±ãŒã·ã§ã³ãäœæã§ããããã«ããŸãã
Kubernetesã®äŸã§ã¯ãæ®å¿µãªããããã§ã¯ãããŸãããã Replication ControllerãDeploymentã®ä»çµã¿ã«ç²ŸéããŠããå Žåã¯ãäžèšãç°¡åã«è¡ãããšãã§ããŸãã
çµæ
ãã®èšäºã¯ãåé¡ã解決ããããã®ã¹ã¯ãªããã®æ¹å®ã§ã¯ãªãããã®åé¡ã解決ããããã®æ§é ã®èª¬æã§ãã ã€ãŸãããœãªã¥ãŒã·ã§ã³ãããæ·±ãç解ããŠæé©åããã«ã¯ãå°ãªããšãgithubã®README.mdã®ã³ãŒããèªãå¿ èŠããããŸãããã®ã³ãŒãã¯ãã¹ããããã€ã¹ãããã§ã docker -composeããã³Kubernetesã®ã¯ã©ã¹ã¿ãŒãéå§ããæ¹æ³ã现ããæ瀺ããŸãã ãã¹ãŠã®ããšã«å ããŠãããã«åãçµã¿ãããšæã£ãŠãã人ã®ããã«ãç§ã¯ä»®æ³ã®æŽå©ã®æã貞ãæºåãã§ããŠããŸãã
- GitHubã®ãœãŒã¹ãšããã¥ã¡ã³ã
- ãµã³ãã«ã®ã¯ã©ã¹ã¿ãŒå¯Ÿå¿Postgresqlã®Dockerã€ã¡ãŒãž
- ENVå€æ°ãä»ããæ§æãæã€Pgpoolã®Dockerã€ã¡ãŒãž
䜿çšããããã¥ã¡ã³ããšè³æ
PSïŒ
çºè¡šãããè³æãæçšã§ãããå€ãå§ãŸãåã«å°ãããžãã£ãã«ãªãããšãé¡ã£ãŠããŸãïŒ å¹žéãšæ°åãåå;ïŒ