LoginSignup
5
4

More than 5 years have passed since last update.

Docker compose + CentOS7でFailed to get D-Bus connection: Operation not permittedが出た場合の対処法

Posted at

CentOS7のコンテナ上にdocker execで入ってsystemctlを打ったらエラーになって焦った方の為に。

対処法

dokcer-compose.ymlに privileged:true を追加するだけでおkです。

docker-compose.yml
version: '2'
services:
  web:
    build: ./web
    ports:
      - "80:80"
    privileged: true

ローカル開発の為だけにdocker-compose使っているならおまじない的に privileged:true をつけても良いのでは、と個人的には思っています。

5
4
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
5
4