Q:

Ansible Recursive Directory Copy

Ansible version: 2.2.1.0
I'm having trouble copying the contents of a directory to a destination host in Ansible. My role directory structure looks like this:
roles/server/
├── defaults
│   └── main.yml
├── files
│   ├── Common-x86_64.repo
│   ├── docker-ce-stable.repo
|
├── handlers
│   └── main.yml
├── meta
│   └── main.yml
├── README.md
├── tasks
│   ├── main.yml
│   └── packages.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
    └── main.yml

There are a lot (about 12 more) repos in the files directory, I've omitted most for the sake of keeping it short. I'm running this code in packages.yml
- name: 1. Setup Repos
     file:
       src: files/
       dest: /etc/yum.repos.d/
       owner: root
       group: root
       mode: 0644

Even though the task is completing without error, nothing is copying into /etc/yum.repos.d/ on the target machine:
ls /etc/yum.repos.d/
CentOS-Base.repo       CentOS-Media.repo    CentOS-fasttrack.repo
CentOS-CR.repo         CentOS-Sources.repo
CentOS-Debuginfo.repo  CentOS-Vault.repo

I read on the documentation page that ending a source directory with a / causes the contents to be copied recursively. What am I doing wrong?

A:

file module is not for copying the files, but for setting attributes of files on the target.
copy module is for copying.

