Skip to content

Instantly share code, notes, and snippets.

@sedlund
Last active October 26, 2018 09:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sedlund/e93ab5aa6390e57b2806dcec4fdaf091 to your computer and use it in GitHub Desktop.
Save sedlund/e93ab5aa6390e57b2806dcec4fdaf091 to your computer and use it in GitHub Desktop.
openwrt bootstrap ansible
---
# vim:ft=ansible
- hosts: openwrt
gather_facts: False
roles:
- { role: lefant.openwrt-uci }
- { role: openwrt }
pre_tasks:
- name: Install python for Ansible
raw: sh -c "test -f /usr/bin/python || opkg update && opkg install python"
register: output
changed_when: output.stdout
tags: pretask
- name: Install essential bootstrap packages
package: name={{ item }} state=present
with_items:
# required for some ansible functionality
- openssh-sftp-server
# much faster then dropbear ssh client
- openssh-client
tags: packages
- name: Gathering Facts
setup:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment