ruby-pulumi-sdk 0.0.1

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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 5d8aa1e11cc28156577553df6c4333149c48cd9fd5aef1ba850c3299ba379d73
4
+ data.tar.gz: 34b166357011cf19148c7973a32fc7433bdcd2ef956f57c54712a09ad2aa2654
5
+ SHA512:
6
+ metadata.gz: a25fabd035dba3e17768d2690df6dcf3204b448e8385f28856ddb2673a752498ce8a58992c19e4fecabbaf553bb10ce17d9b3096e13f1b7fc527199f5901c68d
7
+ data.tar.gz: 9ec145d673cfe3a67f4cfe9e7925010db80d1351ea26ba97b695711a8a93e51dddb028f5485d92cea3c55af3c40d5f65c490ac449e34264e8fab89ea78000d20
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2026 Petris Fernandes
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,39 @@
1
+ # Ruby::Pulumi::Sdk
2
+
3
+ TODO: Delete this and the text below, and describe your gem
4
+
5
+ Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/ruby/pulumi/sdk`. To experiment with that code, run `bin/console` for an interactive prompt.
6
+
7
+ ## Installation
8
+
9
+ TODO: Replace `UPDATE_WITH_YOUR_GEM_NAME_IMMEDIATELY_AFTER_RELEASE_TO_RUBYGEMS_ORG` with your gem name right after releasing it to RubyGems.org. Please do not do it earlier due to security reasons. Alternatively, replace this section with instructions to install your gem from git if you don't plan to release to RubyGems.org.
10
+
11
+ Install the gem and add to the application's Gemfile by executing:
12
+
13
+ ```bash
14
+ bundle add UPDATE_WITH_YOUR_GEM_NAME_IMMEDIATELY_AFTER_RELEASE_TO_RUBYGEMS_ORG
15
+ ```
16
+
17
+ If bundler is not being used to manage dependencies, install the gem by executing:
18
+
19
+ ```bash
20
+ gem install UPDATE_WITH_YOUR_GEM_NAME_IMMEDIATELY_AFTER_RELEASE_TO_RUBYGEMS_ORG
21
+ ```
22
+
23
+ ## Usage
24
+
25
+ TODO: Write usage instructions here
26
+
27
+ ## Development
28
+
29
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
30
+
31
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
32
+
33
+ ## Contributing
34
+
35
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/ruby-pulumi-sdk.
36
+
37
+ ## License
38
+
39
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
data/Rakefile ADDED
@@ -0,0 +1,8 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "bundler/gem_tasks"
4
+ require "rspec/core/rake_task"
5
+
6
+ RSpec::Core::RakeTask.new(:spec)
7
+
8
+ task default: :spec
@@ -0,0 +1,11 @@
1
+ module Pulumi
2
+ module Aws
3
+ module S3
4
+ class Bucket < ::Pulumi::Resource
5
+ def initialize(name, props: {}, opts: {})
6
+ super("aws:s3/bucket:Bucket", name, custom: true, props: props)
7
+ end
8
+ end
9
+ end
10
+ end
11
+ end
@@ -0,0 +1,4 @@
1
+ module Aws
2
+ module S3
3
+ end
4
+ end
@@ -0,0 +1,23 @@
1
+ require_relative 'runtime'
2
+
3
+ module Pulumi
4
+ class Resource
5
+ attr_reader :urn
6
+
7
+ def initialize(type, name, custom: false, parent: nil, props: {}, opts: {})
8
+ monitor = Runtime.monitor
9
+ raise 'Monitor not initialized' unless monitor
10
+
11
+ response = monitor.register_resource(
12
+ Pulumirpc::RegisterResourceRequest.new(
13
+ type: type,
14
+ name: name,
15
+ custom: custom,
16
+ parent: parent&.urn.to_s
17
+ )
18
+ )
19
+
20
+ @urn = response.urn
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,7 @@
1
+ module Pulumi
2
+ module Runtime
3
+ class << self
4
+ attr_accessor :monitor
5
+ end
6
+ end
7
+ end
data/lib/pulumi.rb ADDED
@@ -0,0 +1 @@
1
+ require_relative './aws/s3/bucket'
@@ -0,0 +1,8 @@
1
+ module Ruby
2
+ module Pulumi
3
+ module Sdk
4
+ VERSION: String
5
+ # See the writing guide of rbs: https://github.com/ruby/rbs#guides
6
+ end
7
+ end
8
+ end
metadata ADDED
@@ -0,0 +1,50 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: ruby-pulumi-sdk
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Petris Fernandes
8
+ bindir: exe
9
+ cert_chain: []
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
+ dependencies: []
12
+ email:
13
+ - petrisrf@gmail.com
14
+ executables: []
15
+ extensions: []
16
+ extra_rdoc_files: []
17
+ files:
18
+ - LICENSE.txt
19
+ - README.md
20
+ - Rakefile
21
+ - lib/pulumi.rb
22
+ - lib/pulumi/aws/s3.rb
23
+ - lib/pulumi/aws/s3/bucket.rb
24
+ - lib/pulumi/resource.rb
25
+ - lib/pulumi/runtime.rb
26
+ - sig/ruby/pulumi/sdk.rbs
27
+ homepage: https://github.com/petrenkorf/ruby-pulumi-sdk
28
+ licenses:
29
+ - MIT
30
+ metadata:
31
+ homepage_uri: https://github.com/petrenkorf/ruby-pulumi-sdk
32
+ source_code_uri: https://github.com/petrenkorf/ruby-pulumi-sdk
33
+ rdoc_options: []
34
+ require_paths:
35
+ - lib
36
+ required_ruby_version: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: 3.2.0
41
+ required_rubygems_version: !ruby/object:Gem::Requirement
42
+ requirements:
43
+ - - ">="
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
46
+ requirements: []
47
+ rubygems_version: 3.6.9
48
+ specification_version: 4
49
+ summary: Ruby SDK for Pulumi
50
+ test_files: []