Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e3a66f017e | ||
|
|
9e544ad471 | ||
|
|
5f19aa527a | ||
|
|
bfd5bc5c26 | ||
|
|
2d0ec3accd |
@@ -182,7 +182,9 @@ class RunChecks(APIView):
|
|||||||
ret = {
|
ret = {
|
||||||
"agent": agent.pk,
|
"agent": agent.pk,
|
||||||
"check_interval": agent.check_interval,
|
"check_interval": agent.check_interval,
|
||||||
"checks": CheckRunnerGetSerializer(checks, many=True).data,
|
"checks": CheckRunnerGetSerializer(
|
||||||
|
checks, context={"agent": agent}, many=True
|
||||||
|
).data,
|
||||||
}
|
}
|
||||||
return Response(ret)
|
return Response(ret)
|
||||||
|
|
||||||
@@ -216,7 +218,9 @@ class CheckRunner(APIView):
|
|||||||
ret = {
|
ret = {
|
||||||
"agent": agent.pk,
|
"agent": agent.pk,
|
||||||
"check_interval": agent.check_run_interval(),
|
"check_interval": agent.check_run_interval(),
|
||||||
"checks": CheckRunnerGetSerializer(run_list, many=True).data,
|
"checks": CheckRunnerGetSerializer(
|
||||||
|
run_list, context={"agent": agent}, many=True
|
||||||
|
).data,
|
||||||
}
|
}
|
||||||
return Response(ret)
|
return Response(ret)
|
||||||
|
|
||||||
|
|||||||
@@ -159,8 +159,9 @@ class CheckRunnerGetSerializer(serializers.ModelSerializer):
|
|||||||
if obj.check_type != "script":
|
if obj.check_type != "script":
|
||||||
return []
|
return []
|
||||||
|
|
||||||
|
agent = self.context["agent"] if "agent" in self.context.keys() else obj.agent
|
||||||
return Script.parse_script_args(
|
return Script.parse_script_args(
|
||||||
agent=obj.agent, shell=obj.script.shell, args=obj.script_args
|
agent=agent, shell=obj.script.shell, args=obj.script_args
|
||||||
)
|
)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ LINUX_AGENT_SCRIPT = BASE_DIR / "core" / "agent_linux.sh"
|
|||||||
AUTH_USER_MODEL = "accounts.User"
|
AUTH_USER_MODEL = "accounts.User"
|
||||||
|
|
||||||
# latest release
|
# latest release
|
||||||
TRMM_VERSION = "0.13.2"
|
TRMM_VERSION = "0.13.3"
|
||||||
|
|
||||||
# bump this version everytime vue code is changed
|
# bump this version everytime vue code is changed
|
||||||
# to alert user they need to manually refresh their browser
|
# to alert user they need to manually refresh their browser
|
||||||
|
|||||||
@@ -74,13 +74,6 @@ EOF
|
|||||||
)"
|
)"
|
||||||
|
|
||||||
echo "${mesh_config}" > /home/node/app/meshcentral-data/config.json
|
echo "${mesh_config}" > /home/node/app/meshcentral-data/config.json
|
||||||
|
|
||||||
else
|
|
||||||
# replace persistent mesh configuration with new ports
|
|
||||||
sed -i 's/"Port": 443/"Port": 4443/' /home/node/app/meshcentral-data/config.json
|
|
||||||
sed -i 's/"RedirPort": 80/"RedirPort": 8080/' /home/node/app/meshcentral-data/config.json
|
|
||||||
sed -i "s/\"CertUrl\": \".*\"/\"CertUrl\": \"https:\/\/${NGINX_HOST_IP}:${NGINX_HOST_PORT}\"/" /home/node/app/meshcentral-data/config.json
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
node node_modules/meshcentral --createaccount ${MESH_USER} --pass ${MESH_PASS} --email example@example.com
|
node node_modules/meshcentral --createaccount ${MESH_USER} --pass ${MESH_PASS} --email example@example.com
|
||||||
|
|||||||
Reference in New Issue
Block a user