k2hr3-api 1.0.33 → 1.0.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ChangeLog +13 -0
- package/bin/run.sh +4 -2
- package/lib/openstackapiv3.js +1 -0
- package/package.json +14 -14
- package/tests/auto_control_subprocess.sh +8 -4
package/ChangeLog
CHANGED
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
k2hr3-api (1.0.35) unstable; urgency=low
|
|
2
|
+
|
|
3
|
+
* Fixed bugs about defunct processes and mis-coding - #121
|
|
4
|
+
* Changed supported NodeJS/OS version and fixed code - #120
|
|
5
|
+
|
|
6
|
+
-- Takeshi Nakatani <ggtakec@gmail.com> Fri, 06 Dec 2024 16:16:54 +0900
|
|
7
|
+
|
|
8
|
+
k2hr3-api (1.0.34) unstable; urgency=low
|
|
9
|
+
|
|
10
|
+
* Updated github actions tools and dependencies - #118
|
|
11
|
+
|
|
12
|
+
-- Takeshi Nakatani <ggtakec@gmail.com> Wed, 13 Mar 2024 20:17:16 +0900
|
|
13
|
+
|
|
1
14
|
k2hr3-api (1.0.33) unstable; urgency=low
|
|
2
15
|
|
|
3
16
|
* Updated versions of dependent packages - #116
|
package/bin/run.sh
CHANGED
|
@@ -153,7 +153,8 @@ stop_old_process()
|
|
|
153
153
|
# If processes are running yet, try to kill it.
|
|
154
154
|
#
|
|
155
155
|
for _ONE_PID in ${ALL_CHILD_PIDS}; do
|
|
156
|
-
|
|
156
|
+
# shellcheck disable=SC2009
|
|
157
|
+
if ! ps -ax | grep -v grep | grep -v defunct | grep -q "${_ONE_PID}"; then
|
|
157
158
|
kill -KILL "${_ONE_PID}" >/dev/null 2>&1
|
|
158
159
|
fi
|
|
159
160
|
done
|
|
@@ -163,7 +164,8 @@ stop_old_process()
|
|
|
163
164
|
# Result
|
|
164
165
|
#
|
|
165
166
|
for _ONE_PID in ${ALL_CHILD_PIDS}; do
|
|
166
|
-
|
|
167
|
+
# shellcheck disable=SC2009
|
|
168
|
+
if ! ps -ax | grep -v grep | grep -v defunct | grep -q "${_ONE_PID}"; then
|
|
167
169
|
echo "[ERROR] Could not stop old processes."
|
|
168
170
|
return 1
|
|
169
171
|
fi
|
package/lib/openstackapiv3.js
CHANGED
|
@@ -221,6 +221,7 @@ function rawGetUserUnscopedTokenV3(uname, passwd, callback)
|
|
|
221
221
|
resobj.region = keystone_ep.region.toLowerCase();
|
|
222
222
|
resobj.token_seed = JSON.stringify({ publisher: 'OPENSTACKV3' });
|
|
223
223
|
_callback(null, resobj);
|
|
224
|
+
return;
|
|
224
225
|
});
|
|
225
226
|
});
|
|
226
227
|
req.on('error', function(exception) {
|
package/package.json
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "k2hr3-api",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.35",
|
|
4
4
|
"dependencies": {
|
|
5
|
-
"@kubernetes/client-node": "^0.
|
|
6
|
-
"body-parser": "^1.20.
|
|
7
|
-
"config": "^3.3.
|
|
8
|
-
"cookie-parser": "~1.4.
|
|
5
|
+
"@kubernetes/client-node": "^0.22.3",
|
|
6
|
+
"body-parser": "^1.20.3",
|
|
7
|
+
"config": "^3.3.12",
|
|
8
|
+
"cookie-parser": "~1.4.7",
|
|
9
9
|
"dateformat": "^4.6.3",
|
|
10
|
-
"debug": "~4.3.
|
|
11
|
-
"express": "^4.
|
|
12
|
-
"jose": "^5.
|
|
13
|
-
"k2hdkc": "^1.0.
|
|
10
|
+
"debug": "~4.3.7",
|
|
11
|
+
"express": "^4.21.2",
|
|
12
|
+
"jose": "^5.9.6",
|
|
13
|
+
"k2hdkc": "^1.0.11",
|
|
14
14
|
"morgan": "~1.10.0",
|
|
15
|
-
"rotating-file-stream": "^3.
|
|
15
|
+
"rotating-file-stream": "^3.2.5"
|
|
16
16
|
},
|
|
17
17
|
"bin": {
|
|
18
18
|
"k2hr3-api": "./bin/www",
|
|
@@ -28,11 +28,11 @@
|
|
|
28
28
|
"test": "test"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
|
-
"chai": "^4.
|
|
31
|
+
"chai": "^4.5.0",
|
|
32
32
|
"chai-http": "^4.4.0",
|
|
33
|
-
"eslint": "^8.
|
|
34
|
-
"mocha": "^
|
|
35
|
-
"nyc": "^
|
|
33
|
+
"eslint": "^8.57.1",
|
|
34
|
+
"mocha": "^11.0.1",
|
|
35
|
+
"nyc": "^17.1.0"
|
|
36
36
|
},
|
|
37
37
|
"scripts": {
|
|
38
38
|
"help": "echo 'command list:\n npm run start\n npm run start:prod\n npm run start:production\n npm run start:prod:dbg\n npm run start:prod:debug\n npm run start:prod:debug:break\n npm run start:prod:debug:nobreak\n npm run start:dev\n npm run start:develop\n npm run start:dev:dbg\n npm run start:dev:debug\n npm run start:dev:debug:break\n npm run start:dev:debug:nobreak\n npm run start:watcher:prod\n npm run start:watcher:production\n npm run start:watcher:dev\n npm run start:watcher:develop\n npm run start:watcher:dbg\n npm run start:watcher:debug\n npm run start:watcher:debug:break\n npm run start:watcher:debug:nobreak\n npm run start:watcher:oneshot:prod\n npm run start:watcher:oneshot:production\n npm run start:watcher:oneshot:dev\n npm run start:watcher:oneshot:develop\n npm run start:watcher:oneshot:dbg\n npm run start:watcher:oneshot:debug\n npm run start:watcher:oneshot:debug:break\n npm run start:watcher:oneshot:debug:nobreak\n npm run stop\n npm run stop:watcher\n npm run test\n npm run test:lint\n npm run test:cover\n npm run test:auto:all{:dbg}\n npm run test:auto:version{:dbg}\n npm run test:auto:usertokens{:dbg}\n npm run test:auto:list{:dbg}\n npm run test:auto:resource{:dbg}\n npm run test:auto:policy{:dbg}\n npm run test:auto:role{:dbg}\n npm run test:auto:tenant{:dbg}\n npm run test:auto:service{:dbg}\n npm run test:auto:acr{:dbg}\n npm run test:auto:userdata{:dbg}\n npm run test:auto:extdata{:dbg}\n npm run test:auto:watcher{:dbg}\n npm run test:auto:templengine\n npm run test:auto:templengine:async\n npm run test:manual:apis:version_get\n npm run test:manual:apis:usertoken_postput\n npm run test:manual:apis:usertoken_gethead\n npm run test:manual:apis:policy_postput\n npm run test:manual:apis:policy_gethead\n npm run test:manual:apis:policy_delete\n npm run test:manual:apis:resource_postput\n npm run test:manual:apis:resource_gethead\n npm run test:manual:apis:resource_delete\n npm run test:manual:apis:role_postput\n npm run test:manual:apis:role_gethead\n npm run test:manual:apis:role_delete\n npm run test:manual:apis:tenant_postput\n npm run test:manual:apis:tenant_gethead\n npm run test:manual:apis:tenant_delete\n npm run test:manual:apis:service_postput\n npm run test:manual:apis:service_gethead\n npm run test:manual:apis:service_delete\n npm run test:manual:apis:acr_postput\n npm run test:manual:apis:acr_get\n npm run test:manual:apis:acr_delete\n npm run test:manual:apis:list_gethead\n npm run test:manual:apis:userdata_get\n npm run test:manual:apis:extdata_get\n npm run test:manual:apis:allusertenant_get\n npm run test:manual:apis:k2hr3keys_get\n npm run test:manual:load:k2hdkcdata:auto\n npm run test:manual:load:k2hdkcdata:local\n npm run test:manual:templengine\n npm run test:manual:templengine:async\n'",
|
|
@@ -173,7 +173,8 @@ if [ "${EXEC_MODE}" = "start" ]; then
|
|
|
173
173
|
sleep "${RUN_INTERVAL}"
|
|
174
174
|
fi
|
|
175
175
|
|
|
176
|
-
|
|
176
|
+
# shellcheck disable=SC2009
|
|
177
|
+
if ! ps -ax | grep -v grep | grep -v defunct | grep -q "${CHILD_PROCESS_PID}"; then
|
|
177
178
|
echo "[ERROR] Could not start child process : ${CHILD_PROCESS_CMD}"
|
|
178
179
|
exit 1
|
|
179
180
|
fi
|
|
@@ -189,7 +190,8 @@ else
|
|
|
189
190
|
|
|
190
191
|
CHILD_PROCESS_PID="$(tr -d '\n' < "${CHILD_PROCESS_PIDFILE}")"
|
|
191
192
|
|
|
192
|
-
|
|
193
|
+
# shellcheck disable=SC2009
|
|
194
|
+
if ! ps -ax | grep -v grep | grep -v defunct | grep -q "${CHILD_PROCESS_PID}"; then
|
|
193
195
|
#
|
|
194
196
|
# Try stop
|
|
195
197
|
#
|
|
@@ -200,7 +202,8 @@ else
|
|
|
200
202
|
sleep "${RUN_INTERVAL}"
|
|
201
203
|
fi
|
|
202
204
|
|
|
203
|
-
|
|
205
|
+
# shellcheck disable=SC2009
|
|
206
|
+
if ! ps -ax | grep -v grep | grep -v defunct | grep -q "${CHILD_PROCESS_PID}"; then
|
|
204
207
|
#
|
|
205
208
|
# Retry stop
|
|
206
209
|
#
|
|
@@ -211,7 +214,8 @@ else
|
|
|
211
214
|
sleep "${RUN_INTERVAL}"
|
|
212
215
|
fi
|
|
213
216
|
|
|
214
|
-
|
|
217
|
+
# shellcheck disable=SC2009
|
|
218
|
+
if ! ps -ax | grep -v grep | grep -v defunct | grep -q "${CHILD_PROCESS_PID}"; then
|
|
215
219
|
echo "[ERROR] Could not stop process : ${CHILD_PROCESS_NAME}"
|
|
216
220
|
exit 1
|
|
217
221
|
fi
|