google-chrome Failed to move to new namespace

后端 未结 2 2261
半阙折子戏
半阙折子戏 2021-02-19 07:41

Im trying to run google-chrome --headless inside a docker container as a non-root user to execute some tests. Everytime Im trying to start it, it throws following error:

2条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-02-19 08:27

    Although this doesn't answer your question, since it you can't set security-opt, this is still a good solution for other people with a similar problem finding the question.

    Download this chrome.json file, which contains a custom security profile.

    Use the security profile with --security-opt seccomp=path/to/chrome.json or with docker-compose:

    # docker-compose.yml
    version: '3'
    services:
      :
        #
        # the service configuration
        #
        security_opt:
          - seccomp=
    

    see https://stackoverflow.com/a/53975412/8678740

提交回复
热议问题