本文へスキップ

workers-go

トレンド活発
syumai/workers-go

Go で書いた HTTP サーバーを Cloudflare Workers で動かすための Go モジュール。workers.Serve() で任意の http.Handler を提供できます。

GitHub で見る
スター
1188
フォーク
85
ウォッチ
1188
未解決の Issue
29

この紹介文は現在英語版のみです。

Overview

workers-go is a Go module (root package workers) for running an HTTP server written in Go on Cloudflare Workers. It serves any standard http.Handler. The project describes itself as experimental.

Installation

go get github.com/syumai/workers-go

Usage

func main() {
	http.HandleFunc("/hello", func(w http.ResponseWriter, req *http.Request) { /* ... */ })
	workers.Serve(nil) // nil serves http.DefaultServeMux
}

Quick start

Requires Node.js and Go 1.24 or later. Create a project from the template with:

npm create cloudflare@latest -- --template github.com/syumai/workers-go/_templates/cloudflare/worker-go

or use the Deploy to Cloudflare button. The documentation covers feature support, platform guides and the full binding reference.

共通のカテゴリとタグで順位付けした、似たオープンソースプロジェクトです。

すべての SDK プロジェクト →