Class: DockerComposeDeploy::Actions::DockerCompose::File
- Inherits:
-
Object
- Object
- DockerComposeDeploy::Actions::DockerCompose::File
- Defined in:
- lib/docker_compose_deploy/actions/docker_compose/file.rb
Instance Attribute Summary collapse
-
#path ⇒ Object
readonly
Returns the value of attribute path.
Instance Method Summary collapse
-
#initialize(path = "./docker-compose.yml") ⇒ File
constructor
A new instance of File.
- #services ⇒ Object
Constructor Details
#initialize(path = "./docker-compose.yml") ⇒ File
8 9 10 |
# File 'lib/docker_compose_deploy/actions/docker_compose/file.rb', line 8 def initialize(path="./docker-compose.yml") @path = path end |
Instance Attribute Details
#path ⇒ Object (readonly)
Returns the value of attribute path.
7 8 9 |
# File 'lib/docker_compose_deploy/actions/docker_compose/file.rb', line 7 def path @path end |
Instance Method Details
#services ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/docker_compose_deploy/actions/docker_compose/file.rb', line 12 def services if !hash["services"] raise "This is build to work with version 2 or 3 of docker-compose. It requires the 'services' top level key." end hash["services"].keys end |