hi,

can ansible force a path to be a link even when it is a directory with 
files? currently i am deleting the directory before making it a link and it 
is not idempotent.

on the first run it deletes the directory. but it is also deleting and 
re-creating the link in every run after that.

for example of what i am trying to do:

    - name: remove existing link or directory
      file:
        path: /var/lib/mysql
        state: absent
    - name: link mysql to datastore
      file:
        src: /mnt/datastore/mysql
        dest: /var/lib/mysql
        state: link
        force: true

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/7b71927d-4dda-4b6c-a407-f2630f04b297%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to