Documentation

    PLEASE NOTE: This document applies to v1.0 version and not to the latest stable release v2.9

    Documentation for other releases can be found by using the version selector in the left bottom of any doc page.

    Roadmap

    The project Roadmap is defined in our Concept Map. You can find some more concrete examples below.

    These are just some ideas about the possibilities of rash.

    Lookups

    S3

    s3.rh:

    #!/bin/rash
    
    - name: file from s3
      template:
        content: "{{ lookup('s3', bucket='mybucket', object='config.json.j2')}}"
        dest: /myapp/config.json
        mode: 0400
    
    - name: launch docker CMD
      command: {{ input.args }}
      transfer_pid_1: yes
    

    vault

    vault.rh:

    #!/bin/rash
    
    - name: launch docker CMD
      command: {{ input.args }}
      transfer_pid_1: yes
      env:
        APP1_API_KEY: "{{ lookup('vault', env.VAULT_SECRET_PATH ) }}"
    

    etcd

    etcd.rh:

    #!/bin/rash
    
    - name: launch docker CMD
      command: {{ input.args }}
      transfer_pid_1: yes
      env:
        APP1_API_KEY: "{{ lookup('etcd', env.VAULT_SECRET_PATH ) }}"
    

    Modules

    Copy

    #!/bin/rash
    
    - copy:
        content: "{{ lookup('etcd', env.MYAPP_CONFIG_ETCD_PATH)}}"
        dest: /myapp/config.json
        mode: 0400
    

    S3

    s3.rh:

    #!/bin/rash
    
    - name: file from s3
      s3:
        bucket: mybucket
        object: "{{ env.MYBUNDLE_S3_PATH }}"
        dest: /myapp/i18n/bundle.json
        mode: 0400
    
    - name: launch docker CMD
      command: {{ input.args }}
      transfer_pid_1: yes
    

    Template

    #!/bin/rash
    
    - template:
        content: "{{ lookup('s3', env.MYAPP_CONFIG_J2_TEMPLATE_S3_PATH)}}"
        dest: /myapp/config.json
        mode: 0400
    

    Filters

    jmespath

    #!/bin/bash
    
    - name: get some data
      uri:
        url: https://api.example.com/v1/my_data
      register: my_data
    
    - set_vars:
        my_ips: "{{ my_data.json | json_query('[*].ipv4.address') }}"