Commit 10b76394 authored by 智勇's avatar 智勇

调整restart latest时间

parent f1e9e808
......@@ -2,8 +2,6 @@ const Router = require('koa-router')
const qs = require('querystring')
const { getAllNamespace, createNamespace } = require('./../kubeService/service')
// const newNsKey = ''
const router = new Router();
module.exports = router
......@@ -18,7 +16,6 @@ router.get('/get_namespace_for_jenkins', async (ctx) => {
ctx.body = ret.join('\n')
})
router.get('/info', async (ctx) => {
const data = await getAllNamespace(ctx.client)
const ns = data.namespaces.find(item => item.name === qs.unescape(ctx.request.query.namespace))
......
......@@ -40,7 +40,7 @@ const deploy = async (cluster) => {
summary[namespace.name].latestArray.push(svc.serviceName)
await serviceRestart(client.clientInfo, namespace.name, svc.podName)
}
await sleep(5 * 1000)
await sleep(60 * 1000)
}
// 把master更新部署成lastet
if (~svc.image.search(':master-')) {
......@@ -62,7 +62,7 @@ const deploy = async (cluster) => {
data.resources = resources
await deployUpdate(client.clusterInfo, client.clientInfo, data)
summary[namespace.name].masterArray.push(svc.serviceName)
await sleep(5 * 1000)
await sleep(60 * 1000)
}
}
......@@ -86,7 +86,7 @@ const deploy = async (cluster) => {
module.exports = () => {
// schedule.scheduleJob('*/2 * * * *', async () => {
schedule.scheduleJob('0 1 * * *', async () => {
schedule.scheduleJob('0 8 * * *', async () => {
try {
await deploy('qa')
} catch (e) {
......
......@@ -18,7 +18,7 @@ spec:
spec:
containers:
- name: grafana
image: ccr.ccs.tencentyun.com/test1245/grafana:latest
image: grafana/grafana
ports:
- containerPort: 3000
protocol: TCP
......@@ -26,7 +26,7 @@ spec:
- mountPath: /etc/ssl/certs
name: ca-certificates
readOnly: true
- mountPath: /var
- mountPath: /var/lib/grafana
name: grafana-storage
env:
- name: INFLUXDB_HOST
......@@ -53,5 +53,3 @@ spec:
path: /etc/ssl/certs
- name: grafana-storage
emptyDir: {}
......@@ -2,7 +2,7 @@ kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: prometheus
namespace: kebe
namespace: monitor
spec:
# storageClassName: cbs-3
accessModes:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment