Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
89 commits
Select commit Hold shift + click to select a range
8ca3660
Add blog URL (#261)
n0vad3v Jul 24, 2023
9250d6f
Optimize README.md (#262)
n0vad3v Jul 26, 2023
5dba6bb
M1 should be arm64 (#263)
n0vad3v Jul 29, 2023
4003b03
Multiple backends support (#207)
bugfest Aug 2, 2023
6790ddd
Add support for Go 1.21, bump version, optimize code (#264)
n0vad3v Aug 9, 2023
ab43732
apt update before apt install (#265)
n0vad3v Aug 9, 2023
d9da7f3
Remove metadata when original not exist, update support for heic (#266)
n0vad3v Aug 17, 2023
523294e
fix image exist nil (#274)
BennyThink Sep 15, 2023
5d265dc
Parse flat before load config (#275)
n0vad3v Sep 15, 2023
c54b8be
Use compiled libwebp (#276)
n0vad3v Sep 15, 2023
51dde5e
Remove ARMv7 (#277)
n0vad3v Sep 15, 2023
0b0e5b1
Upgrade github.com/gofiber/fiber (#278)
n0vad3v Sep 18, 2023
655fb1d
Add env on startup (#283)
n0vad3v Oct 17, 2023
d98740c
ISSUE-281 Add NEF support by convert to jpg (#284)
llanc Oct 30, 2023
4a90b18
Fix bug that could remove original image (#287)
n0vad3v Nov 4, 2023
543af24
Better configuration (#288)
n0vad3v Nov 5, 2023
4f39a1c
Unify ENV (#289)
n0vad3v Nov 5, 2023
ace5642
Bump golang.org/x/image from 0.5.0 to 0.10.0 (#290)
dependabot[bot] Nov 11, 2023
cd0b87c
Bump github.com/gofiber/fiber/v2 from 2.50.0 to 2.51.0 (#294)
dependabot[bot] Nov 22, 2023
d7d4c37
Bump github.com/valyala/fasthttp from 1.50.0 to 1.51.0 (#293)
dependabot[bot] Nov 22, 2023
290b233
fix: incorrect cache key (#286)
HolgerHuo Nov 22, 2023
84bd4c6
Bump github.com/schollz/progressbar/v3 from 3.13.1 to 3.14.1 (#291)
dependabot[bot] Nov 22, 2023
cc26be0
Add healthz endpoint (#296)
n0vad3v Nov 23, 2023
0d4856c
fix: metadata not updated when remote file changes (#297)
HolgerHuo Nov 23, 2023
d67601a
Fix link in README.md and fix CI permission (#299)
n0vad3v Nov 24, 2023
c771160
Ignore GIF when converting to AVIF (#302)
n0vad3v Dec 1, 2023
d83f666
Refine convert part (#303)
n0vad3v Dec 16, 2023
484c876
Bump to 0.10.4 (#304)
n0vad3v Dec 18, 2023
d35e0e0
Lock on convert (#307)
n0vad3v Dec 29, 2023
1ec981b
Read all pages (#308)
n0vad3v Dec 29, 2023
0dc7a0f
Bump github.com/gofiber/fiber/v2 from 2.51.0 to 2.52.0 (#309)
dependabot[bot] Feb 10, 2024
12d4cc1
Upgrade to Go 1.22 (#311)
n0vad3v Feb 10, 2024
123c96d
add: cache for remote images (#310)
HolgerHuo Feb 11, 2024
9be1a6b
Fix tests, bump version (#312)
n0vad3v Feb 11, 2024
c921561
Bump github.com/valyala/fasthttp from 1.51.0 to 1.52.0 (#314)
dependabot[bot] Feb 20, 2024
eb2b6d1
Bump govips to 2.14 (#317)
n0vad3v Feb 26, 2024
55c04d2
Bump github.com/gofiber/fiber/v2 from 2.52.0 to 2.52.1 (#315)
dependabot[bot] Feb 27, 2024
61880e2
Bump github.com/schollz/progressbar/v3 from 3.14.1 to 3.14.2 (#316)
dependabot[bot] Feb 29, 2024
ca1050d
Optimized Dockerfile, bump version (#318)
n0vad3v Feb 29, 2024
5a9b4ed
Bump github.com/gofiber/fiber/v2 from 2.52.1 to 2.52.2 (#320)
dependabot[bot] Mar 4, 2024
ddcb532
Bump github.com/stretchr/testify from 1.8.4 to 1.9.0 (#319)
dependabot[bot] Mar 4, 2024
43c275e
Adds JPEG XL support, max_height/max_width support (#321)
n0vad3v Mar 22, 2024
ac30605
Bump github.com/gofiber/fiber/v2 from 2.52.2 to 2.52.3 (#323)
dependabot[bot] Mar 26, 2024
8c15bf3
Bump github.com/gofiber/fiber/v2 from 2.52.3 to 2.52.4 (#324)
dependabot[bot] Apr 10, 2024
b5842b2
Allow jxl based on Accept header (#326)
n0vad3v Apr 10, 2024
c7bebfc
Add EXTRA_PARAMS_CROP_INTERESTING (#328)
n0vad3v Apr 19, 2024
be32328
Fix Malformed dir traversal (#331)
BennyThink Apr 23, 2024
e69c3a2
Bump golang.org/x/net from 0.21.0 to 0.23.0 (#329)
dependabot[bot] Apr 23, 2024
74c6aa6
--- (#334)
dependabot[bot] May 21, 2024
d9c542d
Bump github.com/davidbyttow/govips/v2 to 2.15.0 (#337)
syedcherry Jun 7, 2024
5b3e2f3
Bump golang.org/x/image from 0.17.0 to 0.18.0 (#340)
dependabot[bot] Jun 27, 2024
53487b5
Bump github.com/valyala/fasthttp from 1.52.0 to 1.55.0 (#339)
dependabot[bot] Jun 27, 2024
81c6e78
Bump github.com/schollz/progressbar/v3 from 3.14.3 to 3.14.4 (#338)
dependabot[bot] Jun 27, 2024
f207e3c
Update README (#343)
n0vad3v Jun 28, 2024
89ea0af
Add `MAX_CACHE_SIZE` config (#344)
n0vad3v Jun 29, 2024
d29959c
Bump to 0.12.0 (#345)
n0vad3v Jun 29, 2024
a0ee22a
Bump github.com/gofiber/fiber/v2 from 2.52.4 to 2.52.5 (#346)
dependabot[bot] Jul 1, 2024
80d6a04
Bump github.com/schollz/progressbar/v3 from 3.14.4 to 3.14.5 (#348)
dependabot[bot] Aug 4, 2024
d400f52
Bump github.com/schollz/progressbar/v3 from 3.14.5 to 3.14.6 (#350)
dependabot[bot] Aug 5, 2024
89aea97
Bump to Go 1.23 (#353)
n0vad3v Aug 16, 2024
ae0274c
Add iOS 18 support (#360)
n0vad3v Oct 30, 2024
a08b6e6
Use newer version of libaom (#363)
n0vad3v Nov 13, 2024
e696ee9
Add prefetch-foreground (#365)
n0vad3v Nov 25, 2024
8d24d70
Bump github.com/stretchr/testify from 1.9.0 to 1.10.0 (#366)
dependabot[bot] Nov 26, 2024
ec27023
Bump github.com/schollz/progressbar/v3 from 3.14.6 to 3.17.1 (#362)
dependabot[bot] Nov 26, 2024
3f732e8
WebP Server Go 0.13.0 (#367)
n0vad3v Jan 1, 2025
95b112e
Bump github.com/gofiber/fiber/v2 from 2.52.5 to 2.52.6 (#372)
dependabot[bot] Jan 10, 2025
686a2bf
Bump github.com/schollz/progressbar/v3 from 3.17.1 to 3.18.0 (#373)
dependabot[bot] Jan 11, 2025
a654b4f
Bump github.com/valyala/fasthttp from 1.55.0 to 1.58.0 (#368)
dependabot[bot] Jan 11, 2025
67f6467
Customize loglevel with `--verbosity` flag (#375)
n0vad3v Jan 15, 2025
1384d6e
Bump github.com/davidbyttow/govips/v2 from 2.15.0 to 2.16.0 (#378)
dependabot[bot] Feb 21, 2025
3cb4f26
Bump to Go 1.24 (#380)
n0vad3v Feb 21, 2025
d85cb5e
Correctly handle non-image file when using remote backend (#382)
n0vad3v Feb 25, 2025
3ded00c
Bump github.com/valyala/fasthttp from 1.58.0 to 1.59.0 (#379)
dependabot[bot] Feb 25, 2025
3d98f3c
Drop old version of glibc (#384)
n0vad3v Feb 27, 2025
3b9a9ae
Add install Go go release_binary
n0vad3v Feb 28, 2025
8001531
Fix upload path on ARM64
n0vad3v Feb 28, 2025
babd681
Bump golang.org/x/net from 0.35.0 to 0.36.0 (#386)
dependabot[bot] Mar 13, 2025
b05c03b
Bump GitHub Actions (#389)
n0vad3v Mar 20, 2025
fb272e7
Always use Dockerfile.CI for testing (#390)
n0vad3v Mar 20, 2025
afd2c7a
Partial fix for bugs (#393)
n0vad3v Apr 4, 2025
fbbe156
Bump github.com/valyala/fasthttp from 1.59.0 to 1.60.0 (#394)
dependabot[bot] Apr 4, 2025
4c33e07
add-tests-fix (#395)
n0vad3v Apr 12, 2025
6dbc328
Fix for prefix slash on reqURIwithQuery (#399)
n0vad3v Apr 24, 2025
596a373
patch for undeleted tmp (#403)
BennyThink May 17, 2025
8d44a5b
Bump github.com/gofiber/fiber/v2 from 2.52.6 to 2.52.8 (#406)
dependabot[bot] Jun 18, 2025
208d3bc
Bump github.com/valyala/fasthttp from 1.60.0 to 1.62.0 (#402)
dependabot[bot] Jun 18, 2025
df31ace
Bump to Go 1.25 (#415)
n0vad3v Sep 7, 2025
1e0b84c
Do not resize image when ExtraParams Height/Width is larger than orig…
n0vad3v Nov 17, 2025
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
4 changes: 1 addition & 3 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
.github/*
exhaust/*
pics/*
remote-raw/*
scripts/*
.git
.dockerignore
README.md
LICENSE
Makefile
LICENSE
52 changes: 16 additions & 36 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
@@ -1,64 +1,43 @@
name: CI check on every PR
on:
pull_request:
branches:
- master
paths-ignore:
- '**.md'
- 'Makefile'
- 'config.json'

jobs:
ci:
name: CI check on every push and PR
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Install Go
uses: actions/setup-go@v3
with:
go-version: '1.20'

- name: Setup necessary packages
run: |
sudo apt install libvips-dev -y

- name: run test cases
run: make && make test

image-test:
name: Check for image build and CVE
name: Check for image build, testing and CVE
runs-on: ubuntu-latest
permissions:
pull-requests: write
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: true

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3

- name: Cache Docker layers
uses: actions/cache@v2
- name: Make test
uses: docker/build-push-action@v6
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-
context: .
file: ./Dockerfile.CI
load: true
tags: |
ghcr.io/${{ github.event.repository.full_name }}:latest

- name: Build and load image
uses: docker/build-push-action@v3
- name: Build image test
uses: docker/build-push-action@v6
with:
context: .
load: true
tags: |
ghcr.io/${{ github.event.repository.full_name }}:latest

cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache-new,mode=max

- name: Install trivy
run: |
wget -qO - https://aquasecurity.github.io/trivy-repo/deb/public.key | sudo apt-key add -
Expand All @@ -77,11 +56,12 @@ jobs:
run: |
echo "${{ steps.trivy.outputs.stdout }}"

- name: Comment PR
- name: Comment PR for CVE
uses: thollander/actions-comment-pull-request@v2
with:
message: |
```
${{ steps.trivy.outputs.stdout }}
```
comment_tag: cve
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
15 changes: 4 additions & 11 deletions .github/workflows/codecov.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,16 @@ on:

jobs:
ci:
name: CI check and codecov on every push
name: Codecov on every push
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install Go
uses: actions/setup-go@v3
uses: actions/setup-go@v5
with:
go-version: '1.20'

- name: Setup necessary packages
run: |
sudo apt install libvips-dev -y

- name: run test cases
run: make && make test
go-version: '1.25'

- name: Codecov
uses: codecov/codecov-action@v2
Expand Down
28 changes: 6 additions & 22 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ on:
push:
branches: [ master ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ master ]
schedule:
- cron: '32 20 * * 2'
Expand All @@ -33,38 +32,23 @@ jobs:
fail-fast: false
matrix:
language: [ 'go' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://git.io/codeql-language-support

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.25'

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
24 changes: 17 additions & 7 deletions .github/workflows/integration-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install docker-compose
run: |
sudo apt-get update
sudo apt-get install -y docker-compose

- name: Build image
uses: docker/build-push-action@v3
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64
Expand All @@ -32,7 +37,7 @@ jobs:
- name: Send Requests to Server
run: |
cd pics
find * -type f -print | xargs -I {} curl -H "User-Agent: Mozilla/5.0 Gecko/20100101 Firefox/98.0" http://localhost:3333/{}
find * -type f -print | xargs -I {} curl -o /dev/null -H "Accept: image/webp" --silent http://localhost:3333/{}

- name: Get container RAM stats
run: |
Expand All @@ -43,10 +48,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3

uses: actions/checkout@v4

- name: Install docker-compose
run: |
sudo apt-get update
sudo apt-get install -y docker-compose

- name: Build image
uses: docker/build-push-action@v3
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64
Expand All @@ -61,7 +71,7 @@ jobs:
- name: Send Requests to Server
run: |
cd pics
find * -type f -print | xargs -I {} curl -H "User-Agent: Mozilla/5.0 Gecko/20100101 Firefox/98.0" http://localhost:3333/{}
find * -type f -print | xargs -I {} curl -o /dev/null -H "Accept: image/webp" --silent http://localhost:3333/{}

- name: Get container RAM stats
run: |
Expand Down
92 changes: 68 additions & 24 deletions .github/workflows/release_binary.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,42 +10,86 @@ on:
- '*'

jobs:
build:
name: Create Release
runs-on: ubuntu-latest
build-amd64:
name: Create AMD64 Binary
runs-on: ubuntu-22.04 # Using 22.04 of ubuntu to get the lowest version of glibc
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.25'

- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Install dependencies
run: |
sudo apt update && sudo apt install --no-install-recommends libvips-dev -y

- name: Make
run: |
make

- name: Upload Binary
uses: actions/upload-artifact@v4
with:
name: webp-server-linux-amd64
path: builds/webp-server-linux-amd64

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Make WebP Server Go (amd64)
run: |
docker run --rm -w /app -v "$(pwd)":/app webpsh/libvips make
sudo chown -R $USER:$USER builds/
sha256sum builds/webp-server-linux-amd64 > builds/webp-server-linux-amd64.sha256
build-arm64:
name: Create ARM64 Binary
runs-on: ubuntu-22.04-arm # Using 22.04 of ubuntu to get the lowest version of glibc
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Make WebP Server Go (arm64)
run: |
docker run --rm -w /app -v "$(pwd)":/app --platform linux/arm64 webpsh/libvips make
sudo chown -R $USER:$USER builds/
sha256sum builds/webp-server-linux-arm64 > builds/webp-server-linux-arm64.sha256
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: '1.25'

- name: Check for ldd version(AMD64 only)
- name: Install dependencies
run: |
sudo apt update && sudo apt install --no-install-recommends libvips-dev -y

- name: Make
run: |
make

- name: Upload Binary
uses: actions/upload-artifact@v4
with:
name: webp-server-linux-arm64
path: builds/webp-server-linux-arm64

release-binary:
name: Release Binary
runs-on: ubuntu-latest
needs: [build-amd64, build-arm64]
steps:
- name: Download Binaries
uses: actions/download-artifact@v4
with:
name: webp-server-linux-amd64

- name: Download Binaries
uses: actions/download-artifact@v4
with:
name: webp-server-linux-arm64

- name: Get SHA256
run: |
ldd builds/webp-server-linux-amd64
sha256sum webp-server-linux-amd64 > webp-server-linux-amd64.sha256
sha256sum webp-server-linux-arm64 >webp-server-linux-arm64.sha256

- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: true
title: "WebP Server Go"
files: |
builds/webp-server-linux-amd64
builds/webp-server-linux-amd64.sha256
builds/webp-server-linux-arm64
builds/webp-server-linux-arm64.sha256
webp-server-linux-amd64
webp-server-linux-amd64.sha256
webp-server-linux-arm64
webp-server-linux-arm64.sha256
Loading