Skip to content

Deploying Wiki-Go

Introduction

Wiki-Go is a lightweight, self-hosted wiki application written in Go. It provides a simple way to create and manage documentation using Markdown files without requiring a database. The application compiles to a single binary, making it extremely easy to deploy and maintain.

Key highlights of Wiki-Go:

  • Single Binary: Entire application compiles to one executable for easy deployment
  • No Database: All content stored as Markdown files on disk
  • Markdown Support: Full Markdown rendering with syntax highlighting
  • Fast Performance: Go-powered backend delivers instant page loads
  • Simple Authentication: Basic authentication for protected wikis
  • Search: Built-in search functionality across all pages
  • Git Integration: Optional Git backend for version control
  • Responsive Design: Clean interface that works on all devices

This guide walks through deploying Wiki-Go on Klutch.sh using Docker with persistent storage for your wiki content.

Why Deploy Wiki-Go on Klutch.sh

Deploying Wiki-Go on Klutch.sh provides several advantages:

Minimal Resource Usage: Go’s efficiency means Wiki-Go runs well with minimal CPU and memory allocation.

Persistent Storage: Wiki pages persist across container restarts using Klutch.sh volumes.

HTTPS by Default: Automatic SSL certificates secure your wiki access.

Simple Maintenance: Single binary architecture means fewer moving parts to maintain.

Prerequisites

Before deploying Wiki-Go on Klutch.sh, ensure you have:

Deploying Wiki-Go on Klutch.sh

    Create Your Repository

    Create a new GitHub repository with a Dockerfile:

    FROM golang:1.21-alpine AS builder
    RUN apk add --no-cache git
    WORKDIR /app
    RUN git clone https://github.com/nickvellios/wiki-go.git .
    RUN go build -o wiki-go .
    FROM alpine:latest
    RUN apk add --no-cache ca-certificates
    WORKDIR /app
    COPY --from=builder /app/wiki-go .
    COPY --from=builder /app/templates ./templates
    COPY --from=builder /app/static ./static
    ENV WIKI_PORT=8080
    ENV WIKI_DATA=/data
    EXPOSE 8080
    CMD ["./wiki-go"]

    Push to GitHub

    Push your Dockerfile to your GitHub repository.

    Create a New Project on Klutch.sh

    Navigate to the Klutch.sh dashboard and create a new project.

    Create a New App

    Within your project, create a new app and connect your GitHub repository.

    Configure HTTP Traffic

    Set the traffic type to HTTP with port 8080.

    Set Environment Variables

    Configure the following environment variables:

    VariableValue
    WIKI_PORT8080
    WIKI_DATA/data

    Attach Persistent Volume

    Add a persistent volume mounted at /data for your wiki content.

    Deploy Your Application

    Click Deploy to build and launch your Wiki-Go instance.

    Access Wiki-Go

    Once deployed, access your wiki at your Klutch.sh URL and begin creating documentation.

Additional Resources

Conclusion

Wiki-Go on Klutch.sh provides a lightweight documentation solution powered by Go’s performance and simplicity. The single binary architecture combined with file-based storage makes it an excellent choice for teams who want a fast, maintainable wiki without database complexity.