Skip to content

Commit

Permalink
Improve documentation (#385)
Browse files Browse the repository at this point in the history
* Readme improve

* Get installation script via `get.wabarc.eu.org`

* Move configurations parameters from readme to docs/environment.md

* Update docs/changelog.md

* Place configurations to nav

* Minor changes

* Add screenshots

* File screenshots

* Minor improvements

* Refine deployment section

* Update index.zh.md
  • Loading branch information
waybackarchiver authored May 26, 2023
1 parent 1f16f7f commit 5de16ff
Show file tree
Hide file tree
Showing 15 changed files with 150 additions and 112 deletions.
149 changes: 43 additions & 106 deletions README.md

Large diffs are not rendered by default.

Binary file added docs/assets/discord-server.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/irc.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/mastodon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/matrix-room.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/slack-channel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/telegram-channel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/telegram.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/web.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/xmpp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Add docker-compose.yml ([#367](https://github.com/wabarc/wayback/pull/367))
- Add option to disable onion service ([#372](https://github.com/wabarc/wayback/pull/372))
- Add support for setting preferred path to Chrome executable ([#375](https://github.com/wabarc/wayback/pull/375))
- Add support for XMPP ([#380](https://github.com/wabarc/wayback/pull/380))

### Changed
- Set NoWait to true for tor listen config ([#368](https://github.com/wabarc/wayback/pull/368))
Expand All @@ -19,6 +20,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Refactor and reorganize service entry ([#389](https://github.com/wabarc/wayback/pull/389))
- Replace `fatih/color` with `gookit/color` ([#390](https://github.com/wabarc/wayback/pull/390))
- Using concurrency to manage new workflow runs ([#384](https://github.com/wabarc/wayback/pull/384))
- Improve documentation ([#385](https://github.com/wabarc/wayback/pull/385))

## [0.19.1] - 2023-03-21

Expand Down
97 changes: 97 additions & 0 deletions docs/environment.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
# Configuration Parameters

Wayback can use a configuration file and environment variables.

If both of the definition file and environment variables are specified, they are all will be read and apply,
and preferred from the environment variable for the same item.

Prints the resulting options of the targets with `--print`, in a Go struct with type, without running the `wayback`.

By default, `wayback` looks for configuration options from this files, the following are parsed:

- `./wayback.conf`
- `~/wayback.conf`
- `/etc/wayback.conf`

Use the `-c` / `--config` option to specify the build definition file to use.

## Configuration Options

| Flags | Environment Variable | Default | Description |
| ------------------- | --------------------------------- | -------------------------- | ------------------------------------------------------------ |
| `--debug` | `DEBUG` | `false` | Enable debug mode, override `LOG_LEVEL` |
| `-c`, `--config` | - | - | Configuration file path, defaults: `./wayback.conf`, `~/wayback.conf`, `/etc/wayback.conf` |
| - | `LOG_TIME` | `true` | Display the date and time in log messages |
| - | `LOG_LEVEL` | `info` | Log level, supported level are `debug`, `info`, `warn`, `error`, `fatal`, defaults to `info` |
| - | `ENABLE_METRICS` | `false` | Enable metrics collector |
| - | `WAYBACK_LISTEN_ADDR` | `0.0.0.0:8964` | The listen address for the HTTP server |
| - | `CHROME_BIN` | - | Preferred to sets the path to the Chrome executable |
| - | `CHROME_REMOTE_ADDR` | - | Chrome/Chromium remote debugging address, for screenshot, format: `host:port`, `wss://domain.tld` |
| - | `WAYBACK_POOLING_SIZE` | `3` | Number of worker pool for wayback at once |
| - | `WAYBACK_BOLT_PATH` | `./wayback.db` | File path of bolt database |
| - | `WAYBACK_STORAGE_DIR` | - | Directory to store binary file, e.g. PDF, html file |
| - | `WAYBACK_MAX_MEDIA_SIZE` | `512MB` | Max size to limit download stream media |
| - | `WAYBACK_MEDIA_SITES` | - | Extra media websites wish to be supported, separate with comma |
| - | `WAYBACK_TIMEOUT` | `300` | Timeout for single wayback request, defaults to 300 second |
| - | `WAYBACK_MAX_RETRIES` | `2` | Max retries for single wayback request, defaults to 2 |
| - | `WAYBACK_USERAGENT` | `WaybackArchiver/1.0` | User-Agent for a wayback request |
| - | `WAYBACK_FALLBACK` | `off` | Use Google cache as a fallback if the original webpage is unavailable |
| - | `WAYBACK_MEILI_ENDPOINT` | - | Meilisearch API endpoint |
| - | `WAYBACK_MEILI_INDEXING` | `capsules` | Meilisearch indexing name |
| - | `WAYBACK_MEILI_APIKEY` | - | Meilisearch admin API key |
| `-d`, `--daemon` | - | - | Run as daemon service, e.g. `telegram`, `web`, `mastodon`, `twitter`, `discord` |
| `--ia` | `WAYBACK_ENABLE_IA` | `true` | Wayback webpages to **Internet Archive** |
| `--is` | `WAYBACK_ENABLE_IS` | `true` | Wayback webpages to **Archive Today** |
| `--ip` | `WAYBACK_ENABLE_IP` | `false` | Wayback webpages to **IPFS** |
| `--ph` | `WAYBACK_ENABLE_PH` | `false` | Wayback webpages to **[Telegra.ph](https://telegra.ph)**, required Chrome/Chromium |
| `--ipfs-host` | `WAYBACK_IPFS_HOST` | `127.0.0.1` | IPFS daemon service host |
| `-p`, `--ipfs-port` | `WAYBACK_IPFS_PORT` | `5001` | IPFS daemon service port |
| `-m`, `--ipfs-mode` | `WAYBACK_IPFS_MODE` | `pinner` | IPFS mode for preserve webpage, e.g. `daemon`, `pinner` |
| - | `WAYBACK_IPFS_TARGET` | `web3storage` | The IPFS pinning service is used to store files, supported pinners: infura, pinata, nftstorage, web3storage. |
| - | `WAYBACK_IPFS_APIKEY` | - | Apikey of the IPFS pinning service |
| - | `WAYBACK_IPFS_SECRET` | - | Secret of the IPFS pinning service |
| - | `WAYBACK_GITHUB_TOKEN` | - | GitHub Personal Access Token, required the `repo` scope |
| - | `WAYBACK_GITHUB_OWNER` | - | GitHub account name |
| - | `WAYBACK_GITHUB_REPO` | - | GitHub repository to publish results |
| - | `WAYBACK_NOTION_TOKEN` | - | Notion integration token |
| - | `WAYBACK_NOTION_DATABASE_ID` | - | Notion database ID for archiving results |
| `-t`, `--token` | `WAYBACK_TELEGRAM_TOKEN` | - | Telegram Bot API Token |
| `--chatid` | `WAYBACK_TELEGRAM_CHANNEL` | - | The Telegram public/private channel id to publish archive result |
| - | `WAYBACK_TELEGRAM_HELPTEXT` | - | The help text for Telegram command |
| - | `WAYBACK_MASTODON_SERVER` | - | Domain of Mastodon instance |
| - | `WAYBACK_MASTODON_KEY` | - | The client key of your Mastodon application |
| - | `WAYBACK_MASTODON_SECRET` | - | The client secret of your Mastodon application |
| - | `WAYBACK_MASTODON_TOKEN` | - | The access token of your Mastodon application |
| - | `WAYBACK_TWITTER_CONSUMER_KEY` | - | The customer key of your Twitter application |
| - | `WAYBACK_TWITTER_CONSUMER_SECRET` | - | The customer secret of your Twitter application |
| - | `WAYBACK_TWITTER_ACCESS_TOKEN` | - | The access token of your Twitter application |
| - | `WAYBACK_TWITTER_ACCESS_SECRET` | - | The access secret of your Twitter application |
| - | `WAYBACK_IRC_NICK` | - | IRC nick |
| - | `WAYBACK_IRC_PASSWORD` | - | IRC password |
| - | `WAYBACK_IRC_CHANNEL` | - | IRC channel |
| - | `WAYBACK_IRC_SERVER` | `irc.libera.chat:6697` | IRC server, required TLS |
| - | `WAYBACK_MATRIX_HOMESERVER` | `https://matrix.org` | Matrix homeserver |
| - | `WAYBACK_MATRIX_USERID` | - | Matrix unique user ID, format: `@foo:example.com` |
| - | `WAYBACK_MATRIX_ROOMID` | - | Matrix internal room ID, format: `!bar:example.com` |
| - | `WAYBACK_MATRIX_PASSWORD` | - | Matrix password |
| - | `WAYBACK_DISCORD_BOT_TOKEN` | - | Discord bot authorization token |
| - | `WAYBACK_DISCORD_CHANNEL` | - | Discord channel ID, [find channel ID](https://support.discord.com/hc/en-us/articles/206346498-Where-can-I-find-my-server-ID-) |
| - | `WAYBACK_DISCORD_HELPTEXT` | - | The help text for Discord command |
| - | `WAYBACK_SLACK_APP_TOKEN` | - | App-Level Token of Slack app |
| - | `WAYBACK_SLACK_BOT_TOKEN` | - | `Bot User OAuth Token` for Slack workspace, use `User OAuth Token` if requires create external link |
| - | `WAYBACK_SLACK_CHANNEL` | - | Channel ID of Slack channel |
| - | `WAYBACK_SLACK_HELPTEXT` | - | The help text for Slack slash command |
| - | `WAYBACK_NOSTR_RELAY_URL` | `wss://nostr.developer.li` | Nostr relay server url, multiple separated by comma |
| - | `WAYBACK_NOSTR_PRIVATE_KEY` | - | The private key of a Nostr account |
| - | `WAYBACK_XMPP_JID` | - | The JID of a XMPP account |
| - | `WAYBACK_XMPP_PASSWORD` | - | The password of a XMPP account |
| - | `WAYBACK_XMPP_NOTLS` | - | Connect to XMPP server without TLS |
| - | `WAYBACK_XMPP_HELPTEXT` | - | The help text for XMPP command |
| `--tor` | `WAYBACK_USE_TOR` | `false` | Snapshot webpage via Tor anonymity network |
| `--tor-key` | `WAYBACK_ONION_PRIVKEY` | - | The private key for Tor Hidden Service |
| - | `WAYBACK_ONION_LOCAL_PORT` | `8964` | Local port for Tor Hidden Service, also support for a **reverse proxy**. This is ignored if `WAYBACK_LISTEN_ADDR` is set. |
| - | `WAYBACK_ONION_REMOTE_PORTS` | `80` | Remote ports for Tor Hidden Service, e.g. `WAYBACK_ONION_REMOTE_PORTS=80,81` |
| - | `WAYBACK_ONION_DISABLED` | `false` | Disable onion service |
| - | `WAYBACK_SLOT` | - | Pinning service for IPFS mode of pinner, see [ipfs-pinner](https://github.com/wabarc/ipfs-pinner#supported-pinning-services) |
| - | `WAYBACK_APIKEY` | - | API key for pinning service |
| - | `WAYBACK_SECRET` | - | API secret for pinning service |
4 changes: 2 additions & 2 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Wayback is a web archiving and replay tool that enables users to capturing and preserving web content. It provides an interface to crawl and archive the contents of the web, and a search and replay service to access previously archived pages. Wayback is designed to be used by web archivists, researchers, and anyone who wants to preserve web content and access it in the future.
Wayback is a web archiving and playback tool that allows users to capture and preserve web content. It provides an IM-style interface for receiving and presenting archived web content, and a search and playback service for retrieving previously archived pages. Wayback is designed to be used by web archivists, researchers, and anyone who wants to preserve web content and access it in the future.

Wayback is an open-source web archiving application written in Go. With a modular and customizable architecture, it is designed to be flexible and adaptable to various use cases and environments. It provides support for multiple storage backends and integration with other services.

Whether you need to archive a single web page or a large collection of websites, Wayback can help you capture and store web content for posterity. With its user-friendly interface and powerful features, Wayback is a valuable tool for anyone interested in web archiving and preservation.
Whether you need to archive a single web page or a large collection of web sites, Wayback can help you capture and preserve web content for posterity. With an easy-to-use interface and powerful features, Wayback is a valuable tool for anyone interested in web archiving and preservation.

## Features

Expand Down
4 changes: 2 additions & 2 deletions docs/index.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
title: 简介
---

Wayback是一个网络存档和回放工具,可以帮助用户捕获和保存网络内容。它提供了一个会话界面,用于爬取和存档网络内容,以及一个搜索和回放服务,用于访问先前存档的页面。Wayback旨在供网络存档员、研究人员以及任何想要保存网络内容并在未来访问它的人使用
Wayback是一个网络归档和回放工具,允许用户抓取和保存网络内容。它提供了一个IM风格的界面来接收和展示存档的网络内容,以及一个搜索和回放服务来检索以前存档的网页。Wayback是为网络档案员、研究人员和任何想保存网络内容并在未来访问这些内容的人设计的

Wayback是用Go编写的开源网络存档应用程序。具有模块化和可定制化的架构,它被设计成灵活和适应各种用例和环境。它提供了对多个存储后端的支持,并与其他服务集成。

无论您需要存档单个网页还是大量网站的集合,Wayback都可以帮助您为后人捕获和存储网络内容。凭借其用户友好的界面和强大的功能,Wayback是对网络存档和保护感兴趣的任何人都非常有价值的工具
无论您是需要归档一个网页,还是需要归档一大批网站,Wayback都可以帮助你抓取和保存网络内容,以备后用。凭借易于使用的界面和强大的功能,Wayback对于任何对网络归档和保存感兴趣的人来说都是一个宝贵的工具

## 特性

Expand Down
6 changes: 4 additions & 2 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@ nav:
- Installation: 'installation.md'
- Usage:
- 'Command Line': 'command-line.md'
- 'Service': 'service.md'
- 'Daemon Service': 'service.md'
- 'Configurations': 'environment.md'
- Deployment: 'deployment.md'
- Integrations:
- Discord: 'integrations/discord.md'
Expand Down Expand Up @@ -120,7 +121,8 @@ plugins:
Installation: 安装
Usage: 使用
'Command Line': 命令行
'Service': 守护服务
'Daemon Service': 守护服务
Configurations: 配置选项
Deployment: 部署
Integrations: 集成
Resources: 资源
Expand Down

0 comments on commit 5de16ff

Please sign in to comment.