Class: Wellcar::Templates::DockerCompose

Inherits:
Base
  • Object
show all
Defined in:
lib/wellcar/templates/docker_compose.rb

Constant Summary collapse

INIT_TEMPLATE =
"docker-compose-init.yml.erb"

Instance Method Summary collapse

Methods inherited from Base

#exist?, #render, #write

Constructor Details

#initialize(app_name, repo_account, template_name = "docker-compose.yml.erb") ⇒ DockerCompose

Returns a new instance of DockerCompose.



8
9
10
11
12
13
14
15
# File 'lib/wellcar/templates/docker_compose.rb', line 8

def initialize(app_name, , template_name="docker-compose.yml.erb")
  super "docker-compose.yml"
  with_attributes app_name: app_name,
    template_name: template_name,
    repo_account: ,
    registry_url: "docker.pkg.github.com"
  with_template template_name
end

Instance Method Details

#image_pathObject



17
18
19
# File 'lib/wellcar/templates/docker_compose.rb', line 17

def image_path
  [registry_url, , app_name, "web"].join "/"
end