Giter VIP home page Giter VIP logo

Comments (6)

nickjj avatar nickjj commented on July 20, 2024

Hi,

Does your playbook have become: true set? Check the example playbook in the README for details.

Also, have you tried running it against Ubuntu 18.04? 19.04 isn't officially supported.

from ansible-docker.

magick93 avatar magick93 commented on July 20, 2024

Does your playbook have become: true set?

Yes, it does.

from ansible-docker.

magick93 avatar magick93 commented on July 20, 2024

Also, have you tried running it against Ubuntu 18.04? 19.04 isn't officially supported.

I havent tried on 18:04. But, as its a permissions error, I'd be surprised if the issue is any different.

from ansible-docker.

nickjj avatar nickjj commented on July 20, 2024

I havent tried on 18:04. But, as its a permissions error, I'd be surprised if the issue is any different.

It's worth testing just to eliminate variables because I haven't ever heard of anyone else hitting this issue and I just used this role yesterday to install Docker on both an Ubuntu 18.04 and Debian Buster server and didn't run into this (or any) issues.

from ansible-docker.

nickjj avatar nickjj commented on July 20, 2024

I personally don't use the include_role pattern but try replacing:

  - include_role:
      name: nickjj.docker
    become: true
    vars:
      docker__version: "18.09"
      docker__daemon_json: "{ \"insecure-registries\": [\"172.30.0.0/16\"] }"

With this:

  - include_role:
      name: nickjj.docker
    vars:
      ansible_become: true
      docker__version: "18.09"
      docker__daemon_json: "{ \"insecure-registries\": [\"172.30.0.0/16\"] }"

That's based on: ansible/ansible#29159 (comment)

In other words, become: true isn't being set for the role with your above set up, which is why you're getting those permission errors.

You could also follow the README in this repo and make a new playbook called docker.yml like this:

---

# docker.yml

- name: Example
  hosts: "all"
  become: true

  roles:
    - role: "nickjj.docker"
      tags: ["docker"]

from ansible-docker.

magick93 avatar magick93 commented on July 20, 2024

Thanks

This solves the permissions issue:

  - include_role:
      name: nickjj.docker
    vars:
      ansible_become: true
      docker__version: "18.09"
      docker__daemon_json: "{ \"insecure-registries\": [\"172.30.0.0/16\"] }"

from ansible-docker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.