subspace 2.5.2 → 2.5.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/README.md +15 -0
- data/ansible/roles/newrelic-infra/defaults/main.yml +2 -0
- data/ansible/roles/newrelic-infra/handlers/main.yml +5 -0
- data/ansible/roles/newrelic-infra/tasks/main.yml +33 -0
- data/ansible/roles/newrelic-infra/templates/logs.yml.j2 +5 -0
- data/ansible/roles/newrelic/tasks/main.yml +4 -0
- data/lib/subspace/cli.rb +5 -0
- data/lib/subspace/version.rb +1 -1
- metadata +6 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 2900b56b3f754ef7860f84bed2a542f1613d670d42de47deeb469ccae80f48ad
|
|
4
|
+
data.tar.gz: 13f7d5fc40033f6da6b639f4198072632adbcffb4f0c6a0646ea992641a6cbde
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e138515cdf107fa30c7668711ea40d26cc316b1ca23366eb63497d92ce96a178d543070c81d8d0617045699bed4250415b429ff709b8e1c2a5caf554f9b95152
|
|
7
|
+
data.tar.gz: e4420f8d057f1c8ee0376ba9a693a5170e81ab081651657eb9ac45b9bca6662430540d3701ff8ad83bdb6132126c0f3f1f611e276fa17eb5fe24c747ce22d6a2
|
data/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,10 @@ This project attempts to follow [semantic versioning](https://semver.org/)
|
|
|
10
10
|
* Not working on OSX - macs don't read from /etc/profile.d/
|
|
11
11
|
* Stops showing color if you `sudo su`
|
|
12
12
|
|
|
13
|
+
## 2.5.3
|
|
14
|
+
* Add a friendly error message if ansible is not installed
|
|
15
|
+
* Add new role to support New Relic One's infrastructure agent
|
|
16
|
+
|
|
13
17
|
## 2.5.2
|
|
14
18
|
* Always specify the letsencrypt cert_name so they are consistent
|
|
15
19
|
|
data/README.md
CHANGED
|
@@ -282,6 +282,21 @@ Installs logrotate and lets you configure logs for automatic rotation. Example
|
|
|
282
282
|
|
|
283
283
|
## newrelic
|
|
284
284
|
|
|
285
|
+
## newrelic-infra
|
|
286
|
+
This role will install the next-gen "Newrelic One" infrastructure agent which can perform a few different functions for newrelic. The previous "newrelic" role is deprecated.
|
|
287
|
+
|
|
288
|
+
Variables:
|
|
289
|
+
# Required, the newrelic license key you get after signing up.
|
|
290
|
+
newrelic_license: "longhashthingyougetfromnewrelichere"
|
|
291
|
+
# Optional - send logs to newrelic one's log aggregator.
|
|
292
|
+
newrelic_logs:
|
|
293
|
+
- name: rails-production
|
|
294
|
+
path: /u/apps/blah/shared/log/production.log
|
|
295
|
+
- name: nginx-error
|
|
296
|
+
path: /var/log/nginx/error.log
|
|
297
|
+
|
|
298
|
+
|
|
299
|
+
|
|
285
300
|
## nginx-rails
|
|
286
301
|
|
|
287
302
|
Configures nginx to look at localhost:9292 for the socket/backend connection. If you need to do fancy stuff you should simply override this role
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
- name: Add New Relic apt key
|
|
3
|
+
apt_key:
|
|
4
|
+
url: https://download.newrelic.com/infrastructure_agent/gpg/newrelic-infra.gpg
|
|
5
|
+
state: present
|
|
6
|
+
become: true
|
|
7
|
+
|
|
8
|
+
- name: create license key
|
|
9
|
+
copy:
|
|
10
|
+
dest: "/etc/newrelic-infra.yml"
|
|
11
|
+
content: |
|
|
12
|
+
license_key: {{newrelic_license}}
|
|
13
|
+
|
|
14
|
+
- name: Add New Relic apt repo
|
|
15
|
+
apt_repository:
|
|
16
|
+
repo: deb [arch=amd64] https://download.newrelic.com/infrastructure_agent/linux/apt focal main
|
|
17
|
+
state: present
|
|
18
|
+
become: true
|
|
19
|
+
|
|
20
|
+
- name: Install New Relic server agent
|
|
21
|
+
apt:
|
|
22
|
+
pkg: newrelic-infra
|
|
23
|
+
state: present
|
|
24
|
+
update_cache: true
|
|
25
|
+
become: true
|
|
26
|
+
|
|
27
|
+
- name: Configure application log forwarding if enabled
|
|
28
|
+
when: "{{ newrelic_logs|length }}"
|
|
29
|
+
become: true
|
|
30
|
+
template:
|
|
31
|
+
dest: "/etc/newrelic-infra/logging.d/subspace.yml"
|
|
32
|
+
src: logs.yml.j2
|
|
33
|
+
notify: Restart newrelic-infra
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
---
|
|
2
|
+
- name: "Deprecation notice"
|
|
3
|
+
ansible.builtin.debug:
|
|
4
|
+
msg: The 'newrelic' role in subspace is deprecated. Please migration to Newrelic One and the 'newrelic-infra' role
|
|
5
|
+
|
|
2
6
|
- name: Add New Relic apt repo
|
|
3
7
|
apt_repository:
|
|
4
8
|
repo: deb http://apt.newrelic.com/debian/ newrelic non-free
|
data/lib/subspace/cli.rb
CHANGED
|
@@ -24,6 +24,11 @@ class Subspace::Cli
|
|
|
24
24
|
program :version, Subspace::VERSION
|
|
25
25
|
program :description, 'Ansible-backed server provisioning tool for rails'
|
|
26
26
|
|
|
27
|
+
unless system("which ansible > /dev/null")
|
|
28
|
+
puts "*** Subspace depends on ansible being on your PATH. Please install it: https://docs.ansible.com/ansible/latest/installation_guide/intro_installation.html"
|
|
29
|
+
exit 1
|
|
30
|
+
end
|
|
31
|
+
|
|
27
32
|
command :init do |c|
|
|
28
33
|
c.syntax = 'subspace init [vars]'
|
|
29
34
|
c.summary = 'Run without options to initialize subspace.'
|
data/lib/subspace/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: subspace
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.5.
|
|
4
|
+
version: 2.5.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Brian Samson
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2021-02-
|
|
11
|
+
date: 2021-02-18 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|
|
@@ -173,6 +173,10 @@ files:
|
|
|
173
173
|
- ansible/roles/mysql/templates/mysql_database.yml
|
|
174
174
|
- ansible/roles/mysql2_gem/meta/main.yml
|
|
175
175
|
- ansible/roles/mysql2_gem/tasks/main.yml
|
|
176
|
+
- ansible/roles/newrelic-infra/defaults/main.yml
|
|
177
|
+
- ansible/roles/newrelic-infra/handlers/main.yml
|
|
178
|
+
- ansible/roles/newrelic-infra/tasks/main.yml
|
|
179
|
+
- ansible/roles/newrelic-infra/templates/logs.yml.j2
|
|
176
180
|
- ansible/roles/newrelic/handlers/main.yml
|
|
177
181
|
- ansible/roles/newrelic/tasks/main.yml
|
|
178
182
|
- ansible/roles/nginx-maintenance/tasks/main.yml
|