# Diving into Trellis, Running a fresh unchanged config

**URL:** https://discourse.roots.io/t/diving-into-trellis-running-a-fresh-unchanged-config/5935
**Category:** trellis
**Created:** 2016-02-14T16:12:22Z
**Posts:** 7
**Showing post:** 7 of 7

## Post 7 by @fullyint — 2016-02-16T18:21:17Z

> [@daadir](#):
>
> Where should one look for include playbooks to use or learn from?

The Nginx includes feature is for including conf files into your site’s Nginx conf [here](https://github.com/roots/trellis/blob/904587996849cc8397e7eb289de9701e8c59c362/roles/wordpress-setup/templates/wordpress-site.conf.j2#L58). I’m not aware of examples out there. I’ve used it once to include some redirects. I created a list variable like this in `group_vars/all/main.yml`:

```
redirects:
  - from: slugtoredirect
    to: http://othersite.com/newslug/
  - from: anotherslug
    to: http://someothersite.com/anotherslug
```

Then I created this template in `roles/wordpress-setup/templates/includes.d/example.com/redirects.conf.j2`:

```
# {{ ansible_managed }}

{% for item in redirects | default([]) %}
  location ~* /{{ item.from }}/? {
    return 301 {{ item.to }};
  }

{% endfor %}
```

You’ll be able to figure out anything you need with the example above, the [Nginx docs](https://roots.io/trellis/docs/nginx-includes/), the [Jinja templating docs](http://jinja.pocoo.org/docs/dev/templates/), [Ansible docs](http://docs.ansible.com/ansible/index.html), and google. Enjoy.

---

_[View the full topic](https://discourse.roots.io/t/diving-into-trellis-running-a-fresh-unchanged-config/5935)._
