aptible-api 1.9.7 → 1.10.0

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: eb9550bb31833e244746c3d55142e9f3893940632ef4756770076819643a5c59
4
- data.tar.gz: 5bd8cb47704d4ed64bc432051e8e64cd2b9fdcca5e08cc97ad404aafe49f3f2d
3
+ metadata.gz: 451d4c1dda3a83ffea21ffbaf33d2385ef2ef8448633dcf283f75e517b1d8a03
4
+ data.tar.gz: b96ca05454acffa9e91c7376763741472a921c15d7f78bb1a25714966c9bda04
5
5
  SHA512:
6
- metadata.gz: c493b1c6fb262a02b85d828b191cdb31839fdefff269b1c53a530bcd622508a2fc0d9e7408aa5a5ca7955428525153f99a448aa0a333ed9ad06948465bdd96af
7
- data.tar.gz: 6311480e1c9f6663344bd9b53d17f7c7c74a83c6e719683914c237223947dadb54c949a890fee463af831d20532559838aa6eedf5d0a2273bbb1c91dad7b64ad
6
+ metadata.gz: d5a9b9f0ae9c6e879f599a82196b4bf8a086a3766e1cbcdfe2333d34d005f5997373bf13d36244886108faa23fb15fd336a7f140d390bce501477a52c40d9bfe
7
+ data.tar.gz: 64af4b64434d12c06606caed8becbb5b9c5081c14603f24cfd200fc54f09e8e9237a4bbd192121f084e40d08649c8abf1c8ce03040f94bf4ad5379b17e6b6577
@@ -8,6 +8,8 @@ on:
8
8
  branches:
9
9
  - master
10
10
 
11
+ permissions: {}
12
+
11
13
  jobs:
12
14
  test:
13
15
  name: Run tests on Ruby ${{ matrix.RUBY_VERSION }}
@@ -19,9 +21,11 @@ jobs:
19
21
  steps:
20
22
  - name: Check out code
21
23
  uses: actions/checkout@v4
24
+ with:
25
+ persist-credentials: false
22
26
 
23
27
  - name: Install Ruby
24
- uses: ruby/setup-ruby@v1
28
+ uses: ruby/setup-ruby@d5126b9b3579e429dd52e51e68624dda2e05be25 # v1.267.0
25
29
  with:
26
30
  ruby-version: ${{ matrix.RUBY_VERSION }}
27
31
  bundler: 1.17.3
@@ -0,0 +1,26 @@
1
+ name: zizmor
2
+
3
+ on:
4
+ pull_request:
5
+ branches:
6
+ - master
7
+ push:
8
+ branches:
9
+ - master
10
+
11
+ permissions: {}
12
+
13
+ jobs:
14
+ zizmor:
15
+ name: zizmor
16
+ runs-on: ubuntu-latest
17
+ permissions:
18
+ security-events: write
19
+ steps:
20
+ - name: Checkout repository
21
+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
22
+ with:
23
+ persist-credentials: false
24
+
25
+ - name: Run zizmor
26
+ uses: zizmorcore/zizmor-action@e673c3917a1aef3c65c972347ed84ccd013ecda4 # v0.2.0
@@ -3,12 +3,14 @@ module Aptible
3
3
  class App < Resource
4
4
  belongs_to :account
5
5
  belongs_to :current_configuration
6
+ belongs_to :current_setting
6
7
  has_one :last_code_scan_result
7
8
  has_one :current_deployment
8
9
  embeds_one :current_image
9
10
  embeds_one :last_operation
10
11
  embeds_one :last_deploy_operation
11
12
  has_many :configurations
13
+ has_many :settings
12
14
  has_many :images
13
15
  has_many :operations
14
16
  has_many :vhosts
@@ -4,6 +4,7 @@ module Aptible
4
4
  belongs_to :account
5
5
  belongs_to :database_image
6
6
  belongs_to :current_configuration
7
+ belongs_to :current_setting
7
8
  belongs_to :restored_from_backup
8
9
  embeds_one :last_operation
9
10
  embeds_one :disk
@@ -13,6 +14,7 @@ module Aptible
13
14
  has_many :backups
14
15
  has_many :dependents
15
16
  has_many :configurations
17
+ has_many :settings
16
18
  has_many :aws_instances
17
19
  embeds_many :database_credentials
18
20
 
@@ -0,0 +1,31 @@
1
+ module Aptible
2
+ module Api
3
+ class ExternalAwsAccount < Resource
4
+ has_many :external_aws_resources
5
+
6
+ field :id
7
+ field :organization_id
8
+ field :aws_account_id
9
+ field :account_name
10
+ field :aws_region_primary
11
+ field :discovery_enabled, type: Aptible::Resource::Boolean
12
+ field :discovery_frequency
13
+ field :last_discovery_at, type: Time
14
+ field :status
15
+ field :deleted_at, type: Time
16
+ field :created_at, type: Time
17
+ field :updated_at, type: Time
18
+
19
+ def organization_url
20
+ links['organization'].href
21
+ end
22
+
23
+ def organization
24
+ return @organization if @organization
25
+
26
+ auth = Aptible::Auth::Organization.new(token: token, headers: headers)
27
+ @organization = auth.find_by_url(organization_url)
28
+ end
29
+ end
30
+ end
31
+ end
@@ -0,0 +1,22 @@
1
+ module Aptible
2
+ module Api
3
+ class ExternalAwsResource < Resource
4
+ belongs_to :external_aws_account
5
+
6
+ field :id
7
+ field :resource_type
8
+ field :resource_arn
9
+ field :resource_id
10
+ field :resource_name
11
+ field :region
12
+ field :metadata
13
+ field :tags
14
+ field :discovered_at, type: Time
15
+ field :last_synced_at, type: Time
16
+ field :sync_status
17
+ field :deleted_at, type: Time
18
+ field :created_at, type: Time
19
+ field :updated_at, type: Time
20
+ end
21
+ end
22
+ end
@@ -23,6 +23,8 @@ module Aptible
23
23
  field :certificate
24
24
  field :private_key
25
25
  field :env
26
+ field :settings
27
+ field :sensitive_settings
26
28
  field :container_size
27
29
  field :container_count
28
30
  field :disk_size
@@ -37,6 +37,7 @@ require 'aptible/api/release'
37
37
  require 'aptible/api/release_alteration'
38
38
  require 'aptible/api/service'
39
39
  require 'aptible/api/service_sizing_policy'
40
+ require 'aptible/api/settings'
40
41
  require 'aptible/api/source'
41
42
  require 'aptible/api/vhost'
42
43
  require 'aptible/api/ssh_portal_connection'
@@ -56,3 +57,5 @@ require 'aptible/api/persistent_disk'
56
57
  require 'aptible/api/disk_attachment'
57
58
  require 'aptible/api/maintenance'
58
59
  require 'aptible/api/vpn_tunnel'
60
+ require 'aptible/api/external_aws_account'
61
+ require 'aptible/api/external_aws_resource'
@@ -5,10 +5,12 @@ module Aptible
5
5
  belongs_to :app
6
6
  belongs_to :database
7
7
  belongs_to :current_release
8
+ belongs_to :current_setting
8
9
  has_many :vhosts
9
10
  has_many :operations
10
11
  has_many :releases
11
12
  has_many :disk_attachments
13
+ has_many :settings
12
14
  has_one :service_sizing_policy
13
15
 
14
16
  field :id
@@ -0,0 +1,12 @@
1
+ module Aptible
2
+ module Api
3
+ class Setting < Resource
4
+ belongs_to :resource
5
+
6
+ field :id
7
+ field :keys
8
+ field :sensitive_keys
9
+ field :created_at, type: Time
10
+ end
11
+ end
12
+ end
@@ -1,5 +1,5 @@
1
1
  module Aptible
2
2
  module Api
3
- VERSION = '1.9.7'.freeze
3
+ VERSION = '1.10.0'.freeze
4
4
  end
5
5
  end
@@ -3,7 +3,9 @@ module Aptible
3
3
  class Vhost < Resource
4
4
  belongs_to :service
5
5
  belongs_to :certificate
6
+ belongs_to :current_setting
6
7
  has_many :operations
8
+ has_many :settings
7
9
 
8
10
  field :id
9
11
  field :virtual_domain
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aptible-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.7
4
+ version: 1.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Frank Macreery
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-10-16 00:00:00.000000000 Z
11
+ date: 2025-11-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aptible-auth
@@ -187,6 +187,7 @@ extra_rdoc_files: []
187
187
  files:
188
188
  - ".github/CODEOWNERS"
189
189
  - ".github/workflows/ci.yml"
190
+ - ".github/workflows/zizmor.yaml"
190
191
  - ".gitignore"
191
192
  - ".rspec"
192
193
  - Gemfile
@@ -218,6 +219,8 @@ files:
218
219
  - lib/aptible/api/disk_attachment.rb
219
220
  - lib/aptible/api/ephemeral_container.rb
220
221
  - lib/aptible/api/ephemeral_session.rb
222
+ - lib/aptible/api/external_aws_account.rb
223
+ - lib/aptible/api/external_aws_resource.rb
221
224
  - lib/aptible/api/image.rb
222
225
  - lib/aptible/api/instance_layer_membership.rb
223
226
  - lib/aptible/api/log_drain.rb
@@ -235,6 +238,7 @@ files:
235
238
  - lib/aptible/api/service.rb
236
239
  - lib/aptible/api/service_definition.rb
237
240
  - lib/aptible/api/service_sizing_policy.rb
241
+ - lib/aptible/api/settings.rb
238
242
  - lib/aptible/api/source.rb
239
243
  - lib/aptible/api/ssh_portal_connection.rb
240
244
  - lib/aptible/api/stack.rb