Liuli Historical article introduction:

This time Liuli brings you a subscription solution for novel and book reading scenes. The construction method is no different from the previous based on Liuli to build a pure RSS public account information stream .

The final effect is as follows:

owllook theme rss 客户端订阅

heti theme 浏览器访问

use

The deployment and use of Liuli is still very convenient. It is recommended that you use Docker for deployment, so you need to install Docker on your device before starting. If not, click here to install .

The current configuration of Liuli is mainly divided into two parts:

  • Global configuration: It is the global environment variable, see Liuli environment variable for related instructions
  • Task configuration: This configuration is formed for the problems that users need to solve. For example, this article will generate a configuration that collects, processes, and outputs book pages into RSS (you can copy my configuration when you use it)

Here I will not write step by step how to install and configure Liuli , because builds a pure RSS public account information flow based on Liuli This article has been explained in detail, so please read this article thoroughly before using it. . Remember! Remember! Remember!

......

Ok, finished reading, now you should have these directory files in the Liuli directory:

(base) [liuli] tree -L 1        
├── docker-compose.yaml
├── liuli_config
├────default.json
├── mongodb_data
└── pro.env

Then make some modifications to the docker-compose.yaml and default.json files:

The contents of default.json file are as follows:

{
    "name": "book",
    "author": "liuli_team",
    "doc_source": "liuli_book",
    "collector": {
        "book_common": {
            "book_dict": {
                "诡秘之主": "https://www.yruan.com/article/38563.html"
            },
            "delta_time": 5
        }
    },
    "processor": {
        "before_collect": [],
        "after_collect": [{
            "func": "to_rss",
            "link_source": "github"

        }]
    },
    "sender": {
        "sender_list": ["wecom", "ding"],
        "query_days": 7,
        "delta_time": 3,
        "link_source": "github"
    },
    "backup": {
        "backup_list": ["github", "mongodb"],
        "query_days": 7,
        "delta_time": 3,
        "doc_html_dict": {
            "liuli_book": "book"
        },
        "init_config": {},
        "after_get_content": [{
            "func": "str_replace",
            "before_str": "本书首发",
            "after_str": ""
        }]
    },
    "schedule": {
        "period_list": [
            "00:10",
            "12:10",
            "21:10"
        ]
    }
}

After confirming that there is no problem, execute:

docker-compose up -d

Not surprisingly, you will see that Docker starts these three containers:

Wait a moment, you can try to access the RSS subscription address of the collector to configure the novel's subscription address http://ip:8765/rss/liuli_book/novel name, in my case, the effect is as follows:

Pay attention to the red box, because I am using the GitHub backup device, so the address shows the GitHub address, which everyone can access directly, for example, click here (the content displayed by the RSS subscription comes from this link):

If you also want to use this, you can refer to the tutorial backup device configuration , I use the GitHub backup device and the effect is as follows:

Note that there are more directories of liuli_book coming out.

Q&A

: How do I add book sources?

Since Liuli did not do any novel data collection, nor did it adapt to any novel website (just made two modules of chapter extraction and core content identification), the user needs to fill in the following configuration in the xxx.json file:

"book_dict": {
    "诡秘之主": "https://www.yruan.com/article/38563.html"
}

For example, I am chasing this book . I have no money to go to college. I can only go to slay the dragon and search it directly (Baidu may be better here):

Just choose a link and fill it in the configuration. For example, if I choose the second one, the configuration is as follows:

"book_dict": {
    "诡秘之主": "https://www.yruan.com/article/38563.html",
    "没钱上大学的我只能去屠龙了": "https://www.xbiquwx.la/90_90983/"
}

After adding the book source, simply restart the scheduler container:

docker restart liuli_schedule
: Now it is a demo novel subscription, how can I use it with the last WeChat subscription?

It's very simple, both configurations ( official configuration ) can be placed under the folder, Liuli will be automatically recognized, as follows:

(base) [liuli] tree -L 1        
├── docker-compose.yaml
├── liuli_config
├────wechat.json
├────book.json
├── mongodb_data
└── pro.env

!!! Note: If you have used the configuration of the official account before, please add the configuration of "doc_source": "liuli_wechat" to be compatible.

What if there are other problems?

You can mention Issue at the project address, or you can leave a message directly below this article, you can also add me WeChat in the lower right corner of the official account to answer you directly, and you can add the following Liuli exchange group:

instruction

Liuli is still in the early stage of development. I personally hope that build a multi-source, clean and personalized reading environment , so now the main thing is to make the compatibility of different reading sources, such as public accounts, blogs, novels Based on these basic sources, the follow-up will focus on creating a more refined reading environment for users, such as the existing de-advertising, subsequent planning of smart labels, classification, and a knowledge management system.

In short, there is a long way to go, do it and cherish it. If you have ideas or suggestions, welcome to participate and chat together. Finally, the project address liuli-io/liuli is here, give Star encouragement.


howie6879
104 声望14 粉丝

努力就好