0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

dhcp 管理の Raspberry PI で docker を動作させ始めて出てきた問題。マシンの default route が docker-compose 作成のブリッジ側を向いていて通信できなくなっていた。症状としては https://www.reddit.com/r/docker/comments/7haaik/how_to_prevent_docker_from_creating_default/ の人と同じ。

対処法として挙げられていたのは、dhcp 管理をやめて static 割り当てにすること。

別解で対応したので、そのメモ。

docker は docker-compose で起動させていたので、docker-compose 上では次のように default network を作る。

docker-compose.yml
# これより上は省略
networks:
  default:
    driver_opts:
      com.docker.network.bridge.name: tsdb0

dhcpcd でそのインターフェースを対象から外す。

/etc/dhcpcd.conf
denyinterfaces tsdb0
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?