mirror of
https://github.com/louislam/dockge.git
synced 2025-02-25 13:05:55 +00:00
Create the env file only if not empty
This commit is contained in:
parent
0df3fee3f4
commit
8053e9940e
1 changed files with 4 additions and 1 deletions
|
@ -167,9 +167,12 @@ export class Stack {
|
||||||
|
|
||||||
// Write or overwrite the compose.yaml
|
// Write or overwrite the compose.yaml
|
||||||
fs.writeFileSync(path.join(dir, this._composeFileName), this.composeYAML);
|
fs.writeFileSync(path.join(dir, this._composeFileName), this.composeYAML);
|
||||||
|
|
||||||
// Write or overwrite the .env
|
// Write or overwrite the .env
|
||||||
|
if (this.composeENV.trim() !== "") {
|
||||||
fs.writeFileSync(path.join(dir, ".env"), this.composeENV);
|
fs.writeFileSync(path.join(dir, ".env"), this.composeENV);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
async deploy(socket? : DockgeSocket) : Promise<number> {
|
async deploy(socket? : DockgeSocket) : Promise<number> {
|
||||||
const terminalName = getComposeTerminalName(this.name);
|
const terminalName = getComposeTerminalName(this.name);
|
||||||
|
|
Loading…
Add table
Reference in a new issue