Class: DockerEngineRuby::Models::Service::Endpoint::Port
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- DockerEngineRuby::Models::Service::Endpoint::Port
- Defined in:
- lib/docker_engine_ruby/models/service.rb
Defined Under Namespace
Modules: Protocol, PublishMode
Instance Attribute Summary collapse
- #name ⇒ String?
- #protocol ⇒ Symbol, ...
-
#publish_mode ⇒ Symbol, ...
The mode in which port is published.
-
#published_port ⇒ Integer?
The port on the swarm hosts.
-
#target_port ⇒ Integer?
The port inside the container.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name: nil, protocol: nil, published_port: nil, publish_mode: nil, target_port: nil) ⇒ Object
constructor
Some parameter documentations has been truncated, see Port for more details.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(name: nil, protocol: nil, published_port: nil, publish_mode: nil, target_port: nil) ⇒ Object
Some parameter documentations has been truncated, see DockerEngineRuby::Models::Service::Endpoint::Port for more details.
122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 |
# File 'lib/docker_engine_ruby/models/service.rb', line 122 class Port < DockerEngineRuby::Internal::Type::BaseModel # @!attribute name # # @return [String, nil] optional :name, String, api_name: :Name # @!attribute protocol # # @return [Symbol, DockerEngineRuby::Models::Service::Endpoint::Port::Protocol, nil] optional :protocol, enum: -> { DockerEngineRuby::Service::Endpoint::Port::Protocol }, api_name: :Protocol # @!attribute published_port # The port on the swarm hosts. # # @return [Integer, nil] optional :published_port, Integer, api_name: :PublishedPort # @!attribute publish_mode # The mode in which port is published. # # <p><br /></p> # # - "ingress" makes the target port accessible on every node, regardless of # whether there is a task for the service running on that node or not. # - "host" bypasses the routing mesh and publish the port directly on the swarm # node where that service is running. # # @return [Symbol, DockerEngineRuby::Models::Service::Endpoint::Port::PublishMode, nil] optional :publish_mode, enum: -> { DockerEngineRuby::Service::Endpoint::Port::PublishMode }, api_name: :PublishMode # @!attribute target_port # The port inside the container. # # @return [Integer, nil] optional :target_port, Integer, api_name: :TargetPort # @!method initialize(name: nil, protocol: nil, published_port: nil, publish_mode: nil, target_port: nil) # Some parameter documentations has been truncated, see # {DockerEngineRuby::Models::Service::Endpoint::Port} for more details. # # @param name [String] # # @param protocol [Symbol, DockerEngineRuby::Models::Service::Endpoint::Port::Protocol] # # @param published_port [Integer] The port on the swarm hosts. # # @param publish_mode [Symbol, DockerEngineRuby::Models::Service::Endpoint::Port::PublishMode] The mode in which port is published. # # @param target_port [Integer] The port inside the container. # @see DockerEngineRuby::Models::Service::Endpoint::Port#protocol module Protocol extend DockerEngineRuby::Internal::Type::Enum TCP = :tcp UDP = :udp SCTP = :sctp # @!method self.values # @return [Array<Symbol>] end # The mode in which port is published. # # <p><br /></p> # # - "ingress" makes the target port accessible on every node, regardless of # whether there is a task for the service running on that node or not. # - "host" bypasses the routing mesh and publish the port directly on the swarm # node where that service is running. # # @see DockerEngineRuby::Models::Service::Endpoint::Port#publish_mode module PublishMode extend DockerEngineRuby::Internal::Type::Enum INGRESS = :ingress HOST = :host # @!method self.values # @return [Array<Symbol>] end end |
Instance Attribute Details
#name ⇒ String?
126 |
# File 'lib/docker_engine_ruby/models/service.rb', line 126 optional :name, String, api_name: :Name |
#protocol ⇒ Symbol, ...
131 132 133 134 135 |
# File 'lib/docker_engine_ruby/models/service.rb', line 131 optional :protocol, enum: -> { DockerEngineRuby::Service::Endpoint::Port::Protocol }, api_name: :Protocol |
#publish_mode ⇒ Symbol, ...
The mode in which port is published.
<p><br /></p>
-
“ingress” makes the target port accessible on every node, regardless of whether there is a task for the service running on that node or not.
-
“host” bypasses the routing mesh and publish the port directly on the swarm node where that service is running.
154 155 156 |
# File 'lib/docker_engine_ruby/models/service.rb', line 154 optional :publish_mode, enum: -> { DockerEngineRuby::Service::Endpoint::Port::PublishMode }, api_name: :PublishMode |
#published_port ⇒ Integer?
The port on the swarm hosts.
141 |
# File 'lib/docker_engine_ruby/models/service.rb', line 141 optional :published_port, Integer, api_name: :PublishedPort |
#target_port ⇒ Integer?
The port inside the container.
162 |
# File 'lib/docker_engine_ruby/models/service.rb', line 162 optional :target_port, Integer, api_name: :TargetPort |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/docker_engine_ruby/models/service.rb', line 186
|