Skip to content

Commit

Permalink
Fixes for maxmind (#128)
Browse files Browse the repository at this point in the history
  • Loading branch information
fortuna authored Oct 24, 2022
1 parent a9a52e8 commit 80a2144
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 17 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Go
name: Build and Test

on:
push:
Expand All @@ -13,10 +13,10 @@ jobs:
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.18
- name: Set up Go 1.19
uses: actions/setup-go@v2
with:
go-version: ^1.18
go-version: ^1.19
id: go

- name: Check out code into the Go module directory
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@

# Tools
/bin/

# Git submodules
/third_party/maxmind/
17 changes: 12 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,20 @@ BUILDDIR=$(CURDIR)/build
GOBIN=$(CURDIR)/bin
GORELEASER=$(GOBIN)/goreleaser

.PHONY: release-local test clean clean-all
.PHONY: release release-local test clean clean-all

release-local:
# This requires GITHUB_TOKEN to be set.
release: clean-all $(GORELEASER)
$(GORELEASER)

release-local: $(GORELEASER)
$(GORELEASER) --rm-dist --snapshot

test:
go test -v ./...
test: third_party/maxmind/test-data/GeoIP2-Country-Test.mmdb
go test -v -race -bench=. ./... -benchtime=100ms

third_party/maxmind/test-data/GeoIP2-Country-Test.mmdb:
git submodule update --init

$(GORELEASER): go.mod
env GOBIN=$(GOBIN) go install github.com/goreleaser/goreleaser
Expand All @@ -22,5 +29,5 @@ clean:
go clean

clean-all: clean
rm -rf $(CURDIR)/third_party/maxmind/*
rm -rf $(GOBIN)

17 changes: 8 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# Outline ss-server
[![Build Status](https://travis-ci.org/Jigsaw-Code/outline-ss-server.svg?branch=master)](https://travis-ci.org/Jigsaw-Code/outline-ss-server)

This repository has the Shadowsocks service used by Outline servers. It uses components from [go-shadowsocks2](https://github.com/shadowsocks/go-shadowsocks2), and adds a number of improvements to meet the needs of the Outline users.
![Build Status](https://github.com/Jigsaw-Code/outline-ss-server/actions/workflows/go.yml/badge.svg)
[![Mattermost](https://badgen.net/badge/Mattermost/Outline%20Community/blue)](https://community.internetfreedomfestival.org/community/channels/outline-community)
[![Reddit](https://badgen.net/badge/Reddit/r%2Foutlinevpn/orange)](https://www.reddit.com/r/outlinevpn/)

This repository has the Shadowsocks service used by Outline servers. It was inspired by [go-shadowsocks2](https://github.com/shadowsocks/go-shadowsocks2), and adds a number of improvements to meet the needs of the Outline users.

The Outline Shadowsocks service allows for:
- Multiple users on a single port.
Expand Down Expand Up @@ -111,13 +114,9 @@ You can mix and match the libev and go servers and clients.

## Tests and Benchmarks

Before running tests, you should first run
```
git submodule update --init
```
to download test data used by the GeoIP metrics tests. To run all tests, you can use
To run the tests and benchmarks, call:
```
go test -v ./...
make test
```

You can benchmark the cipher finding code with
Expand Down Expand Up @@ -147,7 +146,7 @@ Summary:
```
- Build and upload:
```bash
goreleaser
make release
```
- Go to https://github.com/Jigsaw-Code/outline-ss-server/releases, review and publish the release.

Expand Down

0 comments on commit 80a2144

Please sign in to comment.