-
Notifications
You must be signed in to change notification settings - Fork 202
/
esaas-playbook.yaml
77 lines (63 loc) · 2.07 KB
/
esaas-playbook.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# Ansible playbook for installing Ruby (via RVM) on empty Ubuntu box
# Used for configuring Codio stack for ESaaS course
---
- hosts: 127.0.0.1
become: true
tasks:
- name: Add nodesource repository
shell: curl -sL https://deb.nodesource.com/setup_10.x | bash -
- name: Add APT key
apt_key:
url: https://dl.yarnpkg.com/debian/pubkey.gpg
state: present
- name: Add APT repository
apt_repository:
repo: deb https://dl.yarnpkg.com/debian/ stable main
state: present
- apt: update_cache=yes
- apt: name=nodejs state=present
- apt: name=build-essential state=present
- apt: name=yarn state=present
- name: Install the dependencies required to install Ruby
apt:
name:
- autoconf
- bison
- libssl-dev
- libyaml-dev
- libreadline6-dev
- zlib1g-dev
- libncurses5-dev
- libffi-dev
- libgdbm5
- libgdbm-dev
- software-properties-common
- sqlite3
- libsqlite3-dev
state: present
- name: Add ppa brightbox ruby repository
apt_repository:
repo: ppa:brightbox/ruby-ng
state: present
- name: Update apt packages
become: true
apt:
update_cache: yes
- name: Install Ubuntu RVM package and Ruby 2.6.6
apt_repository:
repo: ppa:rael-gc/rvm
apt:
name:
- rvm
# then echo 'source "/etc/profile.d/rvm.sh"' >> ~/.bashrc
# then have to logout/login to run 'rvm install...'
- name: Install bundler
shell: gem install bundler
- name: Install Rails
shell: gem install rails -v 4.2.11.3 --no-document
- name: Install rubocop
shell: gem install rubocop --no-document
- name: Install rspec
shell: gem install rspec --no-document
- name: Install Heroku CLI
shell: curl https://cli-assets.heroku.com/install-ubuntu.sh | sh