mirror of
https://github.com/syumai/workers.git
synced 2025-03-10 17:29:11 +00:00
use wrangler deploy instead of deprecated publish command
This commit is contained in:
parent
64637c0003
commit
e1b75af2c4
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -24,5 +24,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
6
_examples/cache/Makefile
vendored
6
_examples/cache/Makefile
vendored
@ -8,6 +8,6 @@ build:
|
||||
#tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
tinygo build -o ./build/app.wasm -target wasm -no-debug ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
2
_examples/cache/README.md
vendored
2
_examples/cache/README.md
vendored
@ -16,5 +16,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -16,5 +16,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -7,9 +7,9 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./main.go
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
||||
.PHONY: generate
|
||||
generate:
|
||||
|
@ -74,7 +74,7 @@ make build # build Go Wasm binary
|
||||
|
||||
# production
|
||||
make init-db # initialize production DB (remove all rows)
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
||||
* Notice: This example uses raw SQL commands to initialize the DB for simplicity, but in general you should use `wrangler d1 migraions` for your application.
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
mkdir -p build
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -8,7 +8,7 @@ _The durable object is written in js; only the stub is called from go!_
|
||||
|
||||
## Demo
|
||||
|
||||
After `make publish` the trigger is `http://durable-object-counter.YOUR-DOMAIN.workers.dev`
|
||||
After `make deploy` the trigger is `http://durable-object-counter.YOUR-DOMAIN.workers.dev`
|
||||
|
||||
* https://durable-object-counter.YOUR-DOMAIN.workers.dev/
|
||||
* https://durable-object-counter.YOUR-DOMAIN.workers.dev/increment
|
||||
@ -28,7 +28,7 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
||||
## Author
|
||||
|
6
_examples/env/Makefile
vendored
6
_examples/env/Makefile
vendored
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
2
_examples/env/README.md
vendored
2
_examples/env/README.md
vendored
@ -20,5 +20,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -8,6 +8,6 @@ build:
|
||||
#tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
tinygo build -o ./build/app.wasm -target wasm -no-debug ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -44,5 +44,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -17,5 +17,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -22,5 +22,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -20,5 +20,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler pages publish ./pages
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler pages deploy ./pages
|
||||
|
@ -20,5 +20,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make build # build Go Wasm binary
|
||||
make dev # run dev server
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -33,5 +33,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -21,5 +21,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -8,6 +8,6 @@ build:
|
||||
#tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
tinygo build -o ./build/app.wasm -target wasm -no-debug ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -24,7 +24,7 @@ This project requires these tools to be installed globally.
|
||||
3. Deploy this example.
|
||||
```
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
||||
## Documents
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
go run ../../cmd/workers-assets-gen
|
||||
tinygo build -o ./build/app.wasm -target wasm ./main.go
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -40,5 +40,5 @@ This project requires these tools to be installed globally.
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
go run github.com/syumai/workers/cmd/workers-assets-gen@latest -mode=go
|
||||
GOOS=js GOARCH=wasm go build -o ./build/app.wasm .
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -39,7 +39,7 @@ curl http://localhost:8787/hello # outputs "Hello!"
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
||||
### Testing dev server
|
||||
|
@ -7,6 +7,6 @@ build:
|
||||
go run github.com/syumai/workers/cmd/workers-assets-gen@latest
|
||||
tinygo build -o ./build/app.wasm -target wasm ./...
|
||||
|
||||
.PHONY: publish
|
||||
publish:
|
||||
wrangler publish
|
||||
.PHONY: deploy
|
||||
deploy:
|
||||
wrangler deploy
|
||||
|
@ -34,7 +34,7 @@ curl http://localhost:8787/hello # outputs "Hello!"
|
||||
```
|
||||
make dev # run dev server
|
||||
make build # build Go Wasm binary
|
||||
make publish # publish worker
|
||||
make deploy # deploy worker
|
||||
```
|
||||
|
||||
### Testing dev server
|
||||
|
Loading…
x
Reference in New Issue
Block a user