Module: ShipProjectStart
- Included in:
- Takeltau::ShipProject
- Defined in:
- lib/takeltau/ship/project/start.rb
Overview
tau ship project start
Instance Method Summary collapse
-
#ship_project_start(project, mute: false) ⇒ Object
Start a takelship.
Instance Method Details
#ship_project_start(project, mute: false) ⇒ Object
Start a takelship
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 |
# File 'lib/takeltau/ship/project/start.rb', line 6 def ship_project_start(project, mute: false) return false unless _ship_project_start_matrjoschka? takelship = _ship_info_lib_get_takelshipinfo unless takelship log.debug 'Unable to gather takelship info' return false end project = _ship_info_lib_get_project project, takelship return false unless _ship_project_start_valid_project? takelship, project ports = _ship_ports_lib_get_ports(takelship, project) return false if _ship_project_start_already_sailing? project, ports log.debug 'Writing port configuration to takelage.yml' _ship_ports_lib_write_ports(ports, project) log.debug "Starting takelship project \"#{project}\"" args = project == 'teamcity' ? '--volume /opt/buildagent:/opt/buildagent' : '' ship_status = _ship_container_lib_docker_privileged ports, project, args: args return false unless _ship_container_lib_started?(ship_status, mute) project say _ship_project_start_print_ports ports true end |