Skip to content

ripple-unmaintained/ripple-rest-ansible

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ripple-rest-ansible

This role installs and configures a ripple-rest server. The user can modify the configuration parameters to more closely match their production environment. Any number of servers and environments (e.g., production, staging) can be added with separate configurations.

Requirements

This role requires Ansible 1.4 or higher and requires Ubuntu (currently tested on Trusty64).

Default Configurations

Configurations are defined at the role level and inventory level. For specifying configurations that are different across hosts or groups (e.g., production vs. staging) it is recommended to define these as group variables and reference them in the individual roles.

Default configurations for can be found in the group_vars/all/main.yml. These variables are available at the role level.

Playbook Roles

Common

The tasks in this role are generic and required in any environment and platform.

NGINX

NGINX is configured as a reverse-proxy in front of the ripple-rest node process.

SSL Certificates

NGINX is configured to terminate SSL connections and requires valid SSL certificates. SSL settings can be found in group_vars/all/main.yml.

# group_vars/all/main.yml
rest:
    server:
      listen: 443
      server_name: "{{ rest.url_base }}"
      ssl: "on"
      ssl_certificate: "/etc/nginx/ssl/server.crt"
      ssl_certificate_key: "/etc/nginx/ssl/server.key"
      ssl_protocols: "TLSv1 TLSv1.1 TLSv1.2"
      ssl_ciphers: "ECDHE-RSA-AES256-SHA:DHE-RSA-AES256-SHA:DHE-DSS-AES256-SHA:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA"

SSL certificates should be purchased and managed on the server outside of Ansible.

NodeJS

NodeJS is installed using the Ansible role published by NodeSource

Ripple-Rest

The Ripple-Rest role follows closely the configuration instructions for deployment in the Ripple developer portal. For understanding how the playbook specifies the Ripple-Rest version to deploy, see Running the Playbook.

Inventory

When working with multiple environments, it is best practice to keep the inventory files separate. For managing dynamic inventory (e.g., AWS) see the Ansible documentation.

Running the Playbook

Provisioning and starting a server is simply:

$ ansible_playbook ripple-rest.yml -i staging.yml

where staging.yml is a hosts file for the staging servers.

See group_vars/all/main.yml for the default release version

By default, the ripple-rest.yml playbook will update code on the server. To disable this, simply pass update=false on the command-line.

Provisioning without updating

$ ansible_playbook ripple-rest.yml -i staging.yml --extra-vars "update=false"

Specifying a version

To specify a version to deploy, use the version variable:

$ ansible_playbook ripple-rest.yml -i staging.yml --extra-vars "version=master"

The version can be the full 40-character SHA-1 hash, the literal string HEAD, a branch name, or a tag name for the ripple-rest repository. See http://docs.ansible.com/git_module.html#examples

Testing and Developmnt

Testing requires Vagrant and VirtualBox.

After installing these, just run vagrant up from the root of this project.

$ vagrant up

See Vagrant-Ansible documentation for more configuration options.

About

Ansible playbook to configure a ripple-rest server

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages