Skip to content

設定檔填寫教學

gnehs edited this page Mar 27, 2021 · 3 revisions

請參考以下設定檔進行設定

註:

  • 您可以在 config-simple.json 取得該檔案
  • // 及其後內容不可放置於 json 內否則會出錯

設定檔範例

{
    "PokaPlayer": {
        "debug": false // 除錯開關
    },

    // (必填)MongoDB 資料庫,若有設定密碼則是填寫 
    // mongodb://<user>:<password>@<host>:<port>/poka
    "mongodb": "mongodb://mongodb/poka", 

    // DSM 模組
    "DSM": {
        "enabled": true, // 若無需使用請將 enabled 改為 false
        "protocol": "https",
        "host": "192.168.x.x",
        "port": 5000,
        "account": "YOUR_DSM_ACCOUNT",
        "password": "YOUR_DSM_PASSWORD",
        "showPins": false // 為顯示 DSM 帳號下的釘選開關,即將棄用。
    },
    // 網易雲模組
    "Netease2": {
        "enabled": false, // 若無需使用請將 enabled 改為 false
        "server": "http://neteaseapi2:3000/",
        "isPremium": true,
        "topPlaylist": {
            "enabled": true,
            "category": "ACG",
            "limit": 6,
            "order": "hot",
            "image": "https://i.imgur.com/ZFaycMw.gif"
        },
        "login": {
            // 信箱或電話兩者選一填寫,並將未填寫之選項改為 null
            "email": "YOUR_NETEASE_EMAIL",
            "phone": "YOUR_NETEASE_PHONE_NUMBER",
            "password": "YOUR_NETEASE_PASSWORD"
        },
        "dailyRecommendSongs": {
            "enabled": true,
            "image": "https://i.imgur.com/ZFaycMw.gif"
        },
        "dailyRecommendPlaylists": {
            "enabled": true,
            "limit": 6,
            "image": "https://i.imgur.com/ZFaycMw.gif"
        },
        "hqPlaylist": {
            "enabled": true,
            "category": "ACG",
            "limit": 6,
            "image": "https://i.imgur.com/ZFaycMw.gif"
        }
    }
}