Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ci): bump dependency versions in CI #12

Merged
merged 1 commit into from
Jan 15, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -16,22 +16,22 @@ jobs:
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: '1.20'
go-version: '1.23'

- name: Setup TinyGo
uses: acifani/setup-tinygo@v2
with:
tinygo-version: '0.28.0'
tinygo-version: '0.35.0'

- name: Setup Spin
uses: fermyon/actions/spin/setup@v1
with:
version: "v2.6.0"
version: "v3.1.2"

- name: Setup Wasmtime
uses: bytecodealliance/actions/wasmtime/setup@v1
with:
version: "13.0.1"
version: "28.0.0"

- name: Run unit tests
run: make test
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -4,9 +4,9 @@ VERSION = 2.3.0-pre0
# Test
# ----------------------------------------------------------------------
.PHONY: test
test: test
tinygo test -target=wasi -gc=leaking -v ./http
tinygo test -target=wasi -gc=leaking -v ./redis
test:
tinygo test -target=wasip1 -gc=leaking -buildmode=c-shared -v ./http
tinygo test -target=wasip1 -gc=leaking -buildmode=c-shared -v ./redis

.PHONY: test-integration
test-integration:
4 changes: 2 additions & 2 deletions examples/http-outbound/README.md
Original file line number Diff line number Diff line change
@@ -16,9 +16,9 @@ Building this as a WebAssembly module can be done using the `tinygo` compiler:

```shell
$ spin build
Building component outbound-http-to-same-app with `tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go`
Building component outbound-http-to-same-app with `tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm .`
Working directory: "./outbound-http-to-same-app"
Building component tinygo-hello with `tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go`
Building component tinygo-hello with `tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm .`
Working directory: "./tinygo-hello"
Finished building all Spin components
```
4 changes: 2 additions & 2 deletions examples/http-outbound/spin.toml
Original file line number Diff line number Diff line change
@@ -22,12 +22,12 @@ allowed_outbound_hosts = [
]
[component.hello.build]
workdir = "hello"
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."

[component.http-to-same-app]
source = "http-to-same-app/main.wasm"
# Use self to make outbound requests to components in the same Spin application.
allowed_outbound_hosts = ["http://self"]
[component.http-to-same-app.build]
workdir = "http-to-same-app"
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
2 changes: 1 addition & 1 deletion examples/http-router/spin.toml
Original file line number Diff line number Diff line change
@@ -13,4 +13,4 @@ component = "hello"
[component.hello]
source = "main.wasm"
[component.hello.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
2 changes: 1 addition & 1 deletion examples/http/spin.toml
Original file line number Diff line number Diff line change
@@ -13,4 +13,4 @@ component = "hello"
[component.hello]
source = "main.wasm"
[component.hello.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
2 changes: 1 addition & 1 deletion examples/key-value/spin.toml
Original file line number Diff line number Diff line change
@@ -13,4 +13,4 @@ component = "key-value"
source = "main.wasm"
key_value_stores = ["default"]
[component.key-value.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
2 changes: 1 addition & 1 deletion examples/llm/spin.toml
Original file line number Diff line number Diff line change
@@ -15,5 +15,5 @@ source = "main.wasm"
allowed_outbound_hosts = []
ai_models = ["llama2-chat", "all-minilm-l6-v2"]
[component.llm.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
watch = ["**/*.go", "go.mod"]
2 changes: 1 addition & 1 deletion examples/mysql-outbound/spin.toml
Original file line number Diff line number Diff line change
@@ -15,5 +15,5 @@ environment = { DB_URL = "mysql://spin:spin@127.0.0.1/spin_dev" }
source = "main.wasm"
allowed_outbound_hosts = ["mysql://127.0.0.1"]
[component.mysql.build]
command = "tinygo build -target=wasi -gc=leaking -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
watch = ["**/*.go", "go.mod"]
2 changes: 1 addition & 1 deletion examples/pg-outbound/spin.toml
Original file line number Diff line number Diff line change
@@ -15,5 +15,5 @@ environment = { DB_URL = "host=localhost user=postgres dbname=spin_dev" }
source = "main.wasm"
allowed_outbound_hosts = ["postgres://localhost"]
[component.pg-outbound.build]
command = "tinygo build -target=wasi -gc=leaking -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
watch = ["**/*.go", "go.mod"]
2 changes: 1 addition & 1 deletion examples/redis-outbound/spin.toml
Original file line number Diff line number Diff line change
@@ -14,4 +14,4 @@ source = "main.wasm"
environment = { REDIS_ADDRESS = "redis://127.0.0.1:6379", REDIS_CHANNEL = "messages" }
allowed_outbound_hosts = ["redis://127.0.0.1"]
[component.outbound-redis.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
2 changes: 1 addition & 1 deletion examples/redis/spin.toml
Original file line number Diff line number Diff line change
@@ -16,4 +16,4 @@ component = "echo-message"
[component.echo-message]
source = "main.wasm"
[component.echo-message.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
2 changes: 1 addition & 1 deletion examples/sqlite/spin.toml
Original file line number Diff line number Diff line change
@@ -15,5 +15,5 @@ source = "main.wasm"
allowed_outbound_hosts = []
sqlite_databases = ["default"]
[component.sqlite.build]
command = "tinygo build -target=wasi -gc=leaking -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
watch = ["**/*.go", "go.mod"]
2 changes: 1 addition & 1 deletion examples/variables/spin.toml
Original file line number Diff line number Diff line change
@@ -18,4 +18,4 @@ source = "main.wasm"
[component.variables.variables]
message = "I'm a {{object}}"
[component.variables.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
2 changes: 1 addition & 1 deletion http/testdata/http-tinygo/Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
.PHONY: build
build:
tinygo build -target=wasi -gc=leaking -o main.wasm main.go
tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm .
24 changes: 14 additions & 10 deletions http/testdata/http-tinygo/spin.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
spin_version = "1"
spin_manifest_version = 2

[application]
name = "spin-http-tinygo-test"
version = "0.1.0"
authors = ["Fermyon Engineering <engineering@fermyon.com>"]
description = "A simple Spin application written in (Tiny)Go."
name = "spin-http-tinygo-test"
trigger = { type = "http" }
version = "1.0.0"

[[component]]
id = "http-tinygo-test"
source = "main.wasm"
[component.trigger]
[[trigger.http]]
route = "/hello/..."
[component.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
component = "http-test"

[component.http-test]
source = "main.wasm"
allowed_outbound_hosts = []
[component.http-test.build]
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
watch = ["**/*.go", "go.mod"]
2 changes: 1 addition & 1 deletion http/testdata/spin-roundtrip/Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
.PHONY: build
build:
tinygo build -target=wasi -gc=leaking -o main.wasm main.go
tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm .
23 changes: 13 additions & 10 deletions http/testdata/spin-roundtrip/spin.toml
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
spin_version = "1"
spin_manifest_version = 2

[application]
name = "spin-roundtrip-test"
version = "0.1.0"
authors = ["Fermyon Engineering <engineering@fermyon.com>"]
description = "A simple Spin application written in (Tiny)Go."
name = "spin-roundtrip-test"
trigger = { type = "http" }
version = "1.0.0"

[[component]]
id = "http-roundtrip-test"
[[trigger.http]]
route = "/hello/..."
component = "http-roundtrip-test"

[component.http-roundtrip-test]
source = "main.wasm"
allowed_outbound_hosts = ["https://example.com"]
[component.trigger]
route = "/hello/..."
[component.build]
command = "tinygo build -target=wasi -gc=leaking -no-debug -o main.wasm main.go"
[component.http-roundtrip-test.build]
command = "tinygo build -target=wasip1 -gc=leaking -buildmode=c-shared -no-debug -o main.wasm ."
watch = ["**/*.go", "go.mod"]