Skip to content

Commit

Permalink
feat: Unvendor, update deps
Browse files Browse the repository at this point in the history
  • Loading branch information
matbme committed Jun 25, 2024
1 parent 8c04d7f commit 8828b4b
Show file tree
Hide file tree
Showing 1,809 changed files with 141 additions and 1,118,028 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
test.db
differ
differ
sources/
Containerfile
17 changes: 14 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ It was designed for allowing the user to visualize changes in package versions i

## Build and Setup

In order to setup Differ, you need Go 1.21 and some Sqlite manager (in this section we use the `sqlite3` command line tool).
### Build and Run from Source

In order to setup Differ from source, you need Go 1.22 and a Sqlite manager (in this section we use the `sqlite3` command line tool).
First, you need to create a database to store all the images and releases Differ will manage, as well as auth information (see read-only subsection below).
Using the `sqlite3` tool, run the following commands:

Expand All @@ -22,14 +24,23 @@ sqlite> select * from auth;
1|admin_user|admin_password
```
Now, build the project with the provided Makefile and run Differ passing the database path as argument.
Now, all you need to do is use the provided Makefile. Once the binary is built, run it by passing the database path as argument.
```sh
$ make
$ ./differ path/to/database.db
```
When setting up Differ in production, you must `export GIN_MODE=release` before running the binary.
When setting up Differ in production, you must run `export GIN_MODE=release` before running the binary.
### Container Image
Alternatively, you can use the provided container image. In this case, all you need to do is pull it using either Docker or Podman, create a new container and pass the database path as argument. Differ will handle the database setup by using the contents of `admin_user` and `admin_password` environment variables.
```sh
$ podman pull ghcr.io/vanilla-os/differ:main
$ podman run --env 'admin_user=user' --env 'admin_password=password' differ path/to/database.db
```
## Endpoints
Expand Down
2 changes: 1 addition & 1 deletion diff/go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/vanilla-os/differ/diff

go 1.21.4
go 1.22.4
63 changes: 32 additions & 31 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,61 +1,62 @@
module github.com/vanilla-os/differ

go 1.21.4
go 1.22.4

require (
github.com/eko/gocache/store/ristretto/v4 v4.2.1
github.com/gin-gonic/gin v1.9.1
github.com/vanilla-os/differ/diff v0.0.0-20231207205048-0a8c0510e12f
gorm.io/driver/sqlite v1.5.4
gorm.io/gorm v1.25.5
github.com/eko/gocache/store/ristretto/v4 v4.2.2
github.com/gin-gonic/gin v1.10.0
github.com/vanilla-os/differ/diff v0.0.0-20240522191229-8c04d7fdbac7
gorm.io/driver/sqlite v1.5.6
gorm.io/gorm v1.25.10
github.com/bytedance/sonic v1.11.9
)

require (
github.com/beorn7/perks v1.0.1 // indirect
github.com/bytedance/sonic/loader v0.1.1 // indirect
github.com/cloudwego/base64x v0.1.4 // indirect
github.com/cloudwego/iasm v0.2.0 // indirect
github.com/golang/mock v1.6.0 // indirect
github.com/kr/text v0.2.0 // indirect
github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect
github.com/prometheus/client_golang v1.17.0 // indirect
github.com/prometheus/client_model v0.5.0 // indirect
github.com/prometheus/common v0.45.0 // indirect
github.com/prometheus/procfs v0.12.0 // indirect
golang.org/x/exp v0.0.0-20231214170342-aacd6d4b4611 // indirect
github.com/prometheus/client_golang v1.19.1 // indirect
github.com/prometheus/client_model v0.6.1 // indirect
github.com/prometheus/common v0.54.0 // indirect
github.com/prometheus/procfs v0.15.1 // indirect
golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8 // indirect
golang.org/x/sync v0.7.0 // indirect
)

require (
github.com/bytedance/sonic v1.10.2
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/chenzhuoyu/base64x v0.0.0-20230717121745-296ad89f973d // indirect
github.com/chenzhuoyu/iasm v0.9.1 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/dgraph-io/ristretto v0.1.1
github.com/dustin/go-humanize v1.0.1 // indirect
github.com/eko/gocache/lib/v4 v4.1.5
github.com/gabriel-vasile/mimetype v1.4.3 // indirect
github.com/eko/gocache/lib/v4 v4.1.6
github.com/gabriel-vasile/mimetype v1.4.4 // indirect
github.com/gin-contrib/sse v0.1.0 // indirect
github.com/go-playground/locales v0.14.1 // indirect
github.com/go-playground/universal-translator v0.18.1 // indirect
github.com/go-playground/validator/v10 v10.16.0 // indirect
github.com/goccy/go-json v0.10.2 // indirect
github.com/golang/glog v1.2.0 // indirect
github.com/go-playground/validator/v10 v10.22.0 // indirect
github.com/goccy/go-json v0.10.3 // indirect
github.com/golang/glog v1.2.1 // indirect
github.com/jinzhu/inflection v1.0.0 // indirect
github.com/jinzhu/now v1.1.5 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/klauspost/cpuid/v2 v2.2.6 // indirect
github.com/leodido/go-urn v1.2.4 // indirect
github.com/klauspost/cpuid/v2 v2.2.8 // indirect
github.com/leodido/go-urn v1.4.0 // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/mattn/go-sqlite3 v1.14.19 // indirect
github.com/mattn/go-sqlite3 v1.14.22 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/pelletier/go-toml/v2 v2.1.1 // indirect
github.com/pelletier/go-toml/v2 v2.2.2 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
github.com/ugorji/go/codec v1.2.12 // indirect
golang.org/x/arch v0.6.0 // indirect
golang.org/x/crypto v0.16.0 // indirect
golang.org/x/net v0.19.0 // indirect
golang.org/x/sys v0.15.0 // indirect
golang.org/x/text v0.14.0 // indirect
google.golang.org/protobuf v1.31.0 // indirect
golang.org/x/arch v0.8.0 // indirect
golang.org/x/crypto v0.24.0 // indirect
golang.org/x/net v0.26.0 // indirect
golang.org/x/sys v0.21.0 // indirect
golang.org/x/text v0.16.0 // indirect
google.golang.org/protobuf v1.34.2 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

Expand Down
Loading

0 comments on commit 8828b4b

Please sign in to comment.