diff --git a/LICENSE b/LICENSE index 306dbc509..672d21d48 100644 --- a/LICENSE +++ b/LICENSE @@ -19,3 +19,4 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + diff --git a/config.yaml b/config.yaml index cb3e7b4fc..a34ca8152 100644 --- a/config.yaml +++ b/config.yaml @@ -1,37 +1,54 @@ settings: - title: 'Status Page' - url: 'https://status-page.eidam.dev' # used for Slack messages + title: 'Cotpear Status Page' + url: 'https://status.cotpear.com' # used for Slack messages logo: logo-192x192.png # image in ./public/ folder daysInHistogram: 90 # number of days you want to display in histogram collectResponseTimes: true # collects avg response times from CRON locations - allmonitorsOperational: 'All Systems Operational' - notAllmonitorsOperational: 'Not All Systems Operational' - monitorLabelOperational: 'Operational' - monitorLabelNotOperational: 'Not Operational' - monitorLabelNoData: 'No data' - dayInHistogramNoData: 'No data' - dayInHistogramOperational: 'All good' - dayInHistogramNotOperational: ' incident(s)' # xx incident(s) recorded + allmonitorsOperational: '所有站點運作良好' + notAllmonitorsOperational: '部分站點運作有異' + monitorLabelOperational: '良好' + monitorLabelNotOperational: '有狀況' + monitorLabelNoData: '無資料' + dayInHistogramNoData: '無資料' + dayInHistogramOperational: '一切良好' + dayInHistogramNotOperational: ' 個事件' # xx incident(s) recorded monitors: - - id: workers-cloudflare-com # unique identifier - name: workers.cloudflare.com - description: 'You write code. They handle the rest.' # default=empty - url: 'https://workers.cloudflare.com/' # URL to fetch + - id: www-cotpear-com # unique identifier + name: 首頁 - https://www.cotpear.com + description: 'Cotpear 主頁' # default=empty + url: 'https://www.cotpear.com/' # URL to fetch method: GET # default=GET expectStatus: 200 # operational status, default=200 followRedirect: false # should fetch follow redirects, default=false - - - id: www-cloudflare-com - name: www.cloudflare.com - description: 'Built for anything connected to the Internet.' - url: 'https://www.cloudflare.com' + + - id: go-cotpear-com # unique identifier + name: 短連結服務 - go.cotpear.com + description: '短連結服務(非公用服務)' # default=empty + url: 'https://go.cotpear.com/status' # URL to fetch + method: GET # default=GET + expectStatus: 404 # operational status, default=200 + followRedirect: false # should fetch follow redirects, default=false + + - id: pwd-cotpear-com + name: 密碼管理器 - https://pwd.cotpear.com + description: 'Cotpear 密碼管理器' + url: 'https://pwd.cotpear.com' method: GET expectStatus: 200 - - - id: blog-cloudflare-com - name: The Cloudflare Blog - url: 'https://blog.cloudflare.com/' + + - id: policies-cotpear-com + name: Cotpear 隱私權與政策 - https://policies.cotpear.com + description: 'Cotpear 隱私權與政策' + url: 'https://policies.cotpear.com' + method: GET + expectStatus: 200 + + - id: yi_chi-cotpear-com + name: Yi Chi Profile - https://yi-chi.cotpear.com + description: '關於我 - 齊一個人頁面' + url: 'https://yi-chi.cotpear.com' method: GET expectStatus: 200 + diff --git a/pages/index.js b/pages/index.js index 4f7121158..73441c28d 100644 --- a/pages/index.js +++ b/pages/index.js @@ -90,7 +90,7 @@ export default function Index({ config, kvMonitors, kvMonitorsLastUpdate }) { })}
- Powered by{' '} + 技術是由{' '} Cloudflare Workers{' '} @@ -98,13 +98,14 @@ export default function Index({ config, kvMonitors, kvMonitorsLastUpdate }) { Flareact{' '} + 提供。
- Get Your Status Page + 部署一個您自己的狀態頁面
diff --git a/src/components/monitorCard.js b/src/components/monitorCard.js index 01fc6e23f..e7b55a522 100644 --- a/src/components/monitorCard.js +++ b/src/components/monitorCard.js @@ -40,8 +40,8 @@ export default function MonitorCard({ key, monitor, data }) {
-
{config.settings.daysInHistogram} days ago
-
Today
+
{config.settings.daysInHistogram} 天前
+
今天
) diff --git a/src/components/monitorStatusHeader.js b/src/components/monitorStatusHeader.js index 38bddac59..c7ad8858f 100644 --- a/src/components/monitorStatusHeader.js +++ b/src/components/monitorStatusHeader.js @@ -23,10 +23,9 @@ export default function MonitorStatusHeader({ kvMonitorsLastUpdate }) {
{text}
{kvMonitorsLastUpdate.time && typeof window !== 'undefined' && (
- checked{' '} - {Math.round((Date.now() - kvMonitorsLastUpdate.time) / 1000)} sec - ago (from{' '} - {locations[kvMonitorsLastUpdate.loc] || kvMonitorsLastUpdate.loc}) + 於{' '} + {Math.round((Date.now() - kvMonitorsLastUpdate.time) / 1000)} 秒前檢查 + (位置: {' '}{locations[kvMonitorsLastUpdate.loc] || kvMonitorsLastUpdate.loc})
)} diff --git a/src/components/monitorStatusLabel.js b/src/components/monitorStatusLabel.js index f03b160dd..40db9ba53 100644 --- a/src/components/monitorStatusLabel.js +++ b/src/components/monitorStatusLabel.js @@ -9,7 +9,7 @@ const classes = { export default function MonitorStatusLabel({ kvMonitor }) { let color = 'gray' - let text = 'No data' + let text = '無資料' if (typeof kvMonitor !== 'undefined') { if (kvMonitor.lastCheck.operational) { diff --git a/src/functions/helpers.js b/src/functions/helpers.js index f4f5327f1..56f507cfa 100644 --- a/src/functions/helpers.js +++ b/src/functions/helpers.js @@ -4,10 +4,10 @@ import { useEffect, useState } from 'react' const kvDataKey = 'monitors_data_v1_1' export const locations = { - WAW: 'Warsaw', - SCL: 'Santiago de Chile', - MEL: 'Melbourne', - SIN: 'Singapore', + WAW: '華沙', + SCL: '聖地牙哥', + MEL: '墨爾本', + SIN: '新加坡', } export async function getKVMonitors() { diff --git a/wrangler.toml b/wrangler.toml index 509a63c12..0a7d30041 100644 --- a/wrangler.toml +++ b/wrangler.toml @@ -5,7 +5,7 @@ type = "webpack" webpack_config = "node_modules/flareact/webpack" [triggers] -crons = ["* * * * *"] +crons = ["*/15 * * * *"] [site] bucket = "out"