prun-ops 0.3.3 → 0.3.5

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 206bf28d664f34f2b4a8a445208f153cf8a3d0997035e511686edc419b4ed843
4
- data.tar.gz: a35e887797566338c0b4b333854d5612356520de96b6a54254512cad20498a23
3
+ metadata.gz: 145e410dcfe0a24a95369c569ba2102ad5607398ae5e2d7b866399f92493124f
4
+ data.tar.gz: 0a46a994d803bd288f99926fa34fc3a58a89dc767fd6c299a2237545f39f224e
5
5
  SHA512:
6
- metadata.gz: 814f97e9446729737268609f01cd86d7454be4f3bfab7c7f8f9396279d1560a81f038f2a24163cbd092262d209cdd8e075a1b65a255aa6f10d1ddb833124c9df
7
- data.tar.gz: 38656a3d1bb311a2efdd76c48ffa6ae8f132a15dbd75bb8d4142c07b0a46badca136fa0bb8126bc67421f5dbc6051a3ff2afac2cf1a1563dc7878f62e7376ca4
6
+ metadata.gz: ca74205ba5ece155dfce6f1f63db16307989528c867f6352d7031299d9e09dc141a405195eb8ee8c96492bb71535b769a2a15cb095920e089437193452b93a49
7
+ data.tar.gz: 4216109a63c9a4cf43f6f6a0c2a3ab1e67459197b7c0f35fd70ceb57f9cb2e312aa94fc6be8f6c58b51b671e976d2916b61bf2bf4f21480a8b49f26457bf7d05
@@ -13,8 +13,8 @@ namespace :nginx do
13
13
  on roles(:web, :api) do |host|
14
14
  run_locally do
15
15
  run_in host, <<-EOBLOCK
16
- sudo snap install --classic certbot
17
- sudo ln -s /snap/bin/certbot /usr/bin/certbot
16
+ sudo apt update
17
+ sudo apt install certbot python3-certbot-nginx -y
18
18
  sudo certbot --nginx -m admin@#{host.hostname} --non-interactive --agree-tos --domains #{host.hostname}
19
19
  EOBLOCK
20
20
  end
@@ -23,6 +23,10 @@ namespace :nginx do
23
23
 
24
24
  task :ssl do
25
25
  on roles(:web, :api) do |host|
26
+ execute <<-EOBLOCK
27
+ cd /etc/ssl/certs
28
+ openssl dhparam -out dhparam.pem 4096
29
+ EOBLOCK
26
30
  template 'vhost_ssl.conf', '/etc/nginx/conf.d/vhost.conf'
27
31
  invoke 'nginx:restart'
28
32
  end
@@ -16,17 +16,19 @@ namespace :ruby do
16
16
  sudo apt-get update
17
17
  #{apt_nointeractive} rvm
18
18
  sudo usermod -a -G rvm $USER
19
+ echo '[[ -s /usr/share/rvm/scripts/rvm ]] && source /usr/share/rvm/scripts/rvm' >> ~/.bashrc
19
20
  EOBLOCK
20
21
  end
21
22
  end
22
23
  task :install_rvm_project_version do
23
24
  ruby_version = File.read('.ruby-version').strip
25
+ ruby_version = ruby_version.start_with?('ruby-') ? ruby_version : "ruby-#{ruby_version}"
24
26
 
25
27
  on roles :all do
26
28
  execute <<-EOBLOCK
27
29
  source "/etc/profile.d/rvm.sh"
28
- rvm install ruby-#{ruby_version}
29
- rvm --default use ruby-#{ruby_version}
30
+ rvm install #{ruby_version}
31
+ rvm --default use #{ruby_version}
30
32
  EOBLOCK
31
33
  end
32
34
  end
@@ -1,3 +1,3 @@
1
1
  module PrunOps
2
- VERSION = "0.3.3"
2
+ VERSION = "0.3.5"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prun-ops
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.3.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan Lebrijo
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-07-19 00:00:00.000000000 Z
11
+ date: 2025-03-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -170,7 +170,7 @@ homepage: http://github.com/jlebrijo/prun-ops
170
170
  licenses:
171
171
  - MIT
172
172
  metadata: {}
173
- post_install_message:
173
+ post_install_message:
174
174
  rdoc_options: []
175
175
  require_paths:
176
176
  - lib
@@ -185,8 +185,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
185
185
  - !ruby/object:Gem::Version
186
186
  version: '0'
187
187
  requirements: []
188
- rubygems_version: 3.0.6
189
- signing_key:
188
+ rubygems_version: 3.0.9
189
+ signing_key:
190
190
  specification_version: 4
191
191
  summary: Encapsulates Deployment and Manteinance Operations commands needed for a
192
192
  Rails Application.