Skip to content

Commit

Permalink
Merge branch 'next'
Browse files Browse the repository at this point in the history
  • Loading branch information
mariuswilms committed Feb 13, 2025
2 parents 7293d10 + 1d9ca19 commit d64ac81
Show file tree
Hide file tree
Showing 68 changed files with 3,772 additions and 2,063 deletions.
38 changes: 27 additions & 11 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,14 +1,30 @@
# TOBEY_DEBUG=false
# TOBEY_SKIP_CACHE=false
# Controls debug mode, uncomment to enable debug mode, by default it is disabled.
# TOBEY_DEBUG=true

TOBEY_PROGRESS_DSN=http://progress:8080
TOBEY_RABBITMQ_DSN=amqp://guest:guest@rabbitmq:5672/
TOBEY_REDIS_DSN=redis:6379/0
# Controls caching access, uncomment to disabled caching. By default caching is enabled.
# TOBEY_SKIP_CACHE=true

# TOBEY_REQS_PER_S=2
# Controls the number of workers per instance, by default 5.
# TOBEY_WORKERS=5

# A space separated list of telemetry to send. Available telemetry: metrics,
# traces. To disable telemetry provide an empty value. When enabling telemetry
# appropriate OTLP endpoints must provided as well.
TOBEY_TELEMETRY="traces"
OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://jaeger:4318/v1/traces
# DSN specifying where crawl results should be stored, by default no results are stored. Here we store results
# in the "results" directory, relative to the current working directory.
TOBEY_RESULTS_DSN=disk://results
# TOBEY_RESULTS_DSN=webhook://host/path

# DSN for progress reporting. By default, a console progress reporter is used. Uncomment to report progress to the
# Factorial service or disable progress reporting.
# TOBEY_PROGRESS_DSN=factorial://localhost:8080
# TOBEY_PROGRESS_DSN=

# If you have multiple instances of Tobey, you can use a Redis instance to coordinate the work queue. By default
# no coordination is done, uncomment to enable coordination.
# TOBEY_REDIS_DSN=redis://localhost:6379

# A space separated list of telemetry to send. Available telemetry: metrics, traces, pulse. By default no telemetry
# is send. Uncomment to enable metrics and traces.
# TOBEY_TELEMETRY=metrics traces

# In order to send telemetry you need to provide the OTLP endpoints, as well.
# OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=
# OTEL_EXPORTER_OTLP_METRICS_ENDPOINT=
26 changes: 26 additions & 0 deletions .env.example.factorial
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Controls debug mode, uncomment to enable debug mode, by default it is disabled.
# TOBEY_DEBUG=true

# Controls caching access, uncomment to disabled caching. By default caching is enabled.
# TOBEY_SKIP_CACHE=true

# DSN specifying where crawl results should be stored, by default no results are stored. Here we store results
# in the "results" directory, relative to the current working directory.
# TOBEY_RESULTS_DSN=disk://results
TOBEY_RESULTS_DSN=webhook://?enable_dynamic_config

# DSN for progress reporting. By default no progress is reported, uncomment to report progress to the
# Factorial service.
TOBEY_PROGRESS_DSN=factorial://localhost:8080

# If you have multiple instances of Tobey, you can use a Redis instance to coordinate the work queue. By default
# no coordination is done, uncomment to enable coordination.
TOBEY_REDIS_DSN=redis:6379/0

# A space separated list of telemetry to send. Available telemetry: metrics, traces, pulse. By default no telemetry
# is send. Uncomment to enable metrics and traces.
TOBEY_TELEMETRY="traces"

# In order to send telemetry you need to provide the OTLP endpoints, as well.
OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://jaeger:4318/v1/traces
OTEL_EXPORTER_OTLP_METRICS_ENDPOINT=
29 changes: 0 additions & 29 deletions .fabfile.yaml

This file was deleted.

53 changes: 53 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Release

on:
push:
tags:
- 'v*'

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.21'

- name: Run Tests
run: go test -v ./...

release:
needs: test
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.21'

- name: Build for Linux
run: |
GOOS=linux GOARCH=amd64 go build -o tobey-linux-amd64
GOOS=linux GOARCH=arm64 go build -o tobey-linux-arm64
- name: Build for macOS
run: |
GOOS=darwin GOARCH=amd64 go build -o tobey-darwin-amd64
GOOS=darwin GOARCH=arm64 go build -o tobey-darwin-arm64
- name: Create Release
uses: softprops/action-gh-release@v1
with:
files: |
tobey-linux-amd64
tobey-linux-arm64
tobey-darwin-amd64
tobey-darwin-arm64
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
22 changes: 22 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Tests

on:
push:
branches: [ main, next ]
pull_request:
branches: [ main, next ]

jobs:
test:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.21'

- name: Run Tests
run: go test -v ./...
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
cache
tobey
.env
8 changes: 0 additions & 8 deletions .hosting/scaffold/index.yml

This file was deleted.

53 changes: 0 additions & 53 deletions .hosting/scaffold/template/app/app-deployment.yml

This file was deleted.

17 changes: 0 additions & 17 deletions .hosting/scaffold/template/app/app-service.yml

This file was deleted.

18 changes: 0 additions & 18 deletions .hosting/scaffold/template/secrets/app-secrets.yml

This file was deleted.

8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
.PHONY: dev
dev:
TOBEY_DEBUG=true go run .
TOBEY_SKIP_CACHE=true TOBEY_DEBUG=true TOBEY_RESULTS_DSN=disk:///tmp/tobey go run . -host 127.0.0.1

.PHONY: pulse
pulse:
go run cmd/pulse/main.go

.PHONY: test
test:
TOBEY_SKIP_CACHE=true TOBEY_DEBUG=true go test
TOBEY_SKIP_CACHE=true TOBEY_DEBUG=true go test -v ./...

.PHONY: clean
clean:
Expand Down
Loading

0 comments on commit d64ac81

Please sign in to comment.