Skip to content

Deploying Wayback

Introduction

Wayback is a self-hosted toolkit for archiving webpages to multiple archiving services simultaneously. It supports archiving to the Internet Archive’s Wayback Machine, archive.today, Telegraph, IPFS, and local storage. The tool can be used via command line, web interface, or through various messaging platforms like Telegram, Discord, and Matrix.

Built in Go, Wayback is lightweight and efficient, making it perfect for individuals and organizations that need to preserve web content for research, legal purposes, or historical documentation.

Key features of Wayback include:

  • Multiple Archiving Services: Save to Internet Archive, archive.today, Telegraph, and IPFS
  • Local Storage: Create local copies of archived pages
  • Web Interface: Simple web UI for archiving URLs
  • Telegram Bot: Archive pages directly from Telegram
  • Discord Bot: Archive via Discord commands
  • Matrix Bot: Matrix protocol integration
  • Mastodon Integration: Archive links mentioned in Mastodon posts
  • Browser Extension Support: Archive pages from your browser
  • Screenshot Capture: Take screenshots of archived pages
  • PDF Generation: Create PDF versions of archived content
  • Batch Processing: Archive multiple URLs at once
  • Proxy Support: Route requests through proxies
  • Customizable: Extensive configuration options

This guide walks you through deploying Wayback on Klutch.sh using Docker for web archiving capabilities.

Prerequisites

Before deploying Wayback on Klutch.sh, ensure you have:

  • A Klutch.sh account
  • A GitHub account with a repository for your Wayback configuration
  • (Optional) API keys for archiving services you want to use
  • (Optional) Bot tokens for Telegram/Discord integration
  • Basic familiarity with Docker concepts

Repository Structure

Create a GitHub repository with the following structure:

wayback-deploy/
├── Dockerfile
└── .dockerignore

Dockerfile

Create a Dockerfile in your repository:

FROM wabarc/wayback:latest
# Web interface port
EXPOSE 8964
# The base image handles the entrypoint

Environment Variables

VariableRequiredDefaultDescription
WAYBACK_LISTEN_ADDRNo0.0.0.0:8964Web interface listen address
WAYBACK_ENABLE_IANotrueEnable Internet Archive
WAYBACK_ENABLE_ISNotrueEnable archive.today
WAYBACK_ENABLE_IPNofalseEnable IPFS
WAYBACK_ENABLE_PHNofalseEnable Telegraph
WAYBACK_TELEGRAM_TOKENNo-Telegram bot token
WAYBACK_DISCORD_BOT_TOKENNo-Discord bot token
WAYBACK_STORAGE_DIRNo/wayback/storageLocal storage directory

Deployment on Klutch.sh

  1. Push your Dockerfile to your GitHub repository.
  2. Log in to Klutch.sh and create a new project.
  3. Create a new app within your project and connect your GitHub repository containing the Dockerfile.
  4. Configure the deployment settings: - Select **HTTP** as the traffic type - Set the internal port to **8964**
  5. Add environment variables for the archiving services you want to enable: - `WAYBACK_ENABLE_IA`: `true` for Internet Archive - `WAYBACK_ENABLE_IS`: `true` for archive.today - Optional: Add bot tokens for Telegram/Discord integration
  6. Attach a persistent volume for local storage: - Mount path: `/wayback/storage` - Recommended size: 10 GB - Purpose: Local copies of archived pages
  7. Click **Deploy** and wait for the build to complete.
  8. Access your Wayback web interface at the provided URL to start archiving.

Usage

Web Interface

Navigate to your Wayback URL and enter any webpage URL to archive it across your configured services.

API Access

Wayback provides an API endpoint for programmatic archiving:

POST /archive
Content-Type: application/json
{"url": "https://example.com"}

Troubleshooting

Archive Requests Failing

Some archiving services may rate limit requests or temporarily be unavailable. Check the logs for specific error messages.

Local Storage Full

Monitor the persistent volume usage and increase size if needed for extensive archiving.

Additional Resources