Skip to content

Commit

Permalink
Fix local development environment
Browse files Browse the repository at this point in the history
  • Loading branch information
yeasy authored and zhuyuanmao committed Aug 12, 2023
2 parents efc6e3b + da7ac48 commit aa1014b
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 4 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -243,3 +243,6 @@ src/dashboard/functions
src/dashboard/lambda/mock/index.js
.config
.config.old

# Cello local storage
/opt/cello
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@ Environmental preparation:

If environment is prepared, then we can start cello service.

* Set local storage environment variable, e.g.

```bash
$ export CELLO_PATH=$(pwd)/opt/cello
```


* Start service locally

```bash
Expand Down
3 changes: 2 additions & 1 deletion src/api-engine/api/lib/agent/handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,5 @@ def get(self):
try:
return self._agent.get()
except Exception as e:
return False
LOG.error(e)
return False
4 changes: 2 additions & 2 deletions src/api-engine/api/routes/node/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -574,11 +574,11 @@ def destroy(self, request, pk=None):
LOG.info("Retry to stop/delete container %d time(s).", i + 1)
try:
response = agent.stop()
if response != True:
if response is not True:
LOG.error("Failed when agent stops/deletes container: %s", response)
continue
response = agent.delete()
if response != True:
if response is not True:
LOG.error("Failed when agent stops/deletes container: %s", response)
continue
res = True
Expand Down
5 changes: 4 additions & 1 deletion src/dashboard/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -141,5 +141,8 @@
"src/**/*.less",
"config/**/*.js*",
"scripts/**/*.js"
]
],
"resolutions": {
"mockjs/commander": "^8.2.0"
}
}

0 comments on commit aa1014b

Please sign in to comment.