Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

replication not working when port changed

オープン
#293 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
活発
技術スタック
docker
領域
databases, devops

調査の方向性

まず、ポートマッピング 5988:5984 を介してローカルインスタンスからのレプリケーションを再現し、次にレプリケーションの追加に使用される _utils メソッドと、Docker イメージがどのようにポートを公開しているかを調べます。ブラウザーから見えるローカルデータベースの URL と、コンテナ内から到達可能な URL を比較します。変更後のホストポートで D から S へのレプリケーションが成功すれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Hi,

I just found a problem when changing the port number: It seems to break replikation.

The case:

Running several instances of docker hub's couchdb:latest (with podman)

  • one on the server machine S

  • one on the developer machine D

task: replicate a database D -> S

But since port 5984 on D is sometimes needed for testing and developing couchdb instances, the port of the instance running on D has been moved by telling podman to use a portmapping 5988:5984

Thus, a browser running on D will find it at http://localhost:5988/_utils

Replication local database (on D) to remote database (on S) doesn't work then.

Reason, as far as I do understand the logs: The _utils' method to add a replication (from: local) uses the given URL to find the local cadatabase, i.e. it tries to contact the local database as http://localhost:5988/ , but inside the container, it resides on 5984.

In order to make this work, a mapping of 5988:5988 would be neeed. Unfortunately, the docker image does not take a variable to change the port number.

regards

主要言語
Dockerfile
スター
289
フォーク
146
平均マージ
30分
マージ済み PR(30日)
1

環境構築

  • Dockerfile・Docker Compose ファイルなし
  • プルリクエストのテンプレートあり
  • コントリビューションガイドなし

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

apache/couchdb-docker のほかの issue

apache/couchdb-docker の issue をすべて見る

似ている issue

Databases の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。