Skip to content

Commit 9544bdd

Browse files
committed
Add comments in function
Signed-off-by: Kirtan Gajjar <[email protected]>
1 parent 510ab3e commit 9544bdd

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

php/class-ee-docker.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,13 @@ public static function docker_compose_up( $dir, $services = [] ) {
171171
return false;
172172
}
173173

174+
/**
175+
* Function to check if a network exists
176+
*
177+
* @param string $network Name/ID of network to check
178+
*
179+
* @return bool Network exists or not
180+
*/
174181
public static function docker_network_exists( string $network ) {
175182
return EE::exec( "docker network inspect $network" );
176183
}

php/site-utils.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,11 @@ function init_checks() {
109109
}
110110
}
111111

112-
112+
/**
113+
* Generates global docker-compose.yml at EE_CONF_ROOT
114+
*
115+
* @param Filesystem $fs Filesystem object to write file
116+
*/
113117
function generate_global_docker_compose_yml( Filesystem $fs ) {
114118
$img_versions = EE\Utils\get_image_versions();
115119

@@ -142,6 +146,7 @@ function generate_global_docker_compose_yml( Filesystem $fs ) {
142146
],
143147
],
144148
];
149+
145150
$contents = EE\Utils\mustache_render( EE_ROOT . '/templates/global_docker_compose.yml.mustache', $data );
146151
$fs->dumpFile( EE_CONF_ROOT . '/docker-compose.yml', $contents );
147152
}

0 commit comments

Comments
 (0)