diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index 5278192..9c90b43 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -5,10 +5,14 @@ on: branches: - "master" +env: + IMAGE_NAME: "nventiveux/syncthing" + DOCKER_BUILDKIT: "1" + jobs: lint: name: "Linting" - runs-on: "ubuntu-22.04" + runs-on: "ubuntu-24.04" steps: - uses: "actions/checkout@v3" @@ -19,7 +23,7 @@ jobs: build: name: "Build" - runs-on: "ubuntu-22.04" + runs-on: "ubuntu-24.04" steps: - uses: "actions/checkout@v3" @@ -34,6 +38,12 @@ jobs: with: install: true + - name: "Login to DockerHub" + uses: "docker/login-action@v2" + with: + username: "${{ secrets.DOCKER_USERNAME }}" + password: "${{ secrets.DOCKER_PASSWORD }}" + - name: "Build images" uses: "docker/build-push-action@v3" with: @@ -41,5 +51,5 @@ jobs: context: "." file: "./Dockerfile" platforms: "linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v6" - push: false - tags: "latest" + push: true + tags: "${{ env.IMAGE_NAME }}:pr-${{ github.event.number }}" diff --git a/CHANGELOG.md b/CHANGELOG.md index c5958af..72d7802 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## v2.0.10 (2025-10-23) + +### Feat + +- prepare for syncthing v2 + +### Fix + +- **ci**: login to docker hub in pr + ## v1.30.0 (2025-07-15) ### Feat diff --git a/Dockerfile b/Dockerfile index e739a29..8c21934 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM alpine:3.21 +FROM alpine:3.22 LABEL authors="nVentiveUX " LABEL license="MIT" @@ -13,7 +13,7 @@ ENV SYNCTHING_USER="syncthing" \ SYNCTHING_GROUP="syncthing" \ SYNCTHING_GROUP_GID=1000 \ SYNCTHING_ADMIN_USER="admin" \ - SYNCTHING_VERSION="1.30.0" \ + SYNCTHING_VERSION="2.0.10" \ SYNCTHING_ARCH="amd64" RUN set -x \ @@ -46,4 +46,4 @@ EXPOSE 8384/tcp 22000/tcp 22000/udp 21027/udp ENTRYPOINT ["/docker-entrypoint.sh"] -CMD ["syncthing", "-home=/etc/syncthing", "-logflags=0"] +CMD ["syncthing", "--home=/etc/syncthing", "--logflags=0"] diff --git a/Makefile b/Makefile index 528f94c..fa42880 100644 --- a/Makefile +++ b/Makefile @@ -12,7 +12,7 @@ build: .PHONY: tests tests: build - docker run -it --rm --name syncthing_tests local/syncthing:latest + docker run -it --rm -p 8000:8384 --name syncthing_tests local/syncthing:latest .PHONY: clean clean: diff --git a/README.md b/README.md index 622e633..71077b8 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ Following arch are missing tests: ## Available image tags * [nventiveux/syncthing](https://hub.docker.com/r/nventiveux/syncthing) - * `latest`, `v1.30.0` ([Dockerfile](./Dockerfile)) + * `latest`, `v2.0.10` ([Dockerfile](./Dockerfile)) ## Usage @@ -103,7 +103,7 @@ make install Tweak `Dockerfile` to your convenience. -**Note**: if you are upgrading Syncthing to a newer version, also [sync the config file version](https://github.com/syncthing/syncthing/blob/main/lib/config/config.go#L34) ! +**Note**: if you are upgrading Syncthing to a newer version, also [sync the config file version](https://github.com/syncthing/syncthing/blob/main/lib/config/config.go#L36) ! Commit changes and submit a **Pull Request**. @@ -111,13 +111,19 @@ Commit changes and submit a **Pull Request**. Bump the version using: -```shell +```sh git switch -c release/next make release version= git commit -a -m "feat(core): bump syncthing to " +# Open a pull request +# Tests... +``` + +Release: + +```sh uv run cz bump --changelog git push origin -u --tags HEAD -# Open a pull request ``` ## References diff --git a/pyproject.toml b/pyproject.toml index 43feae3..a18937f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "docker-syncthing" -version = "1.30.0" +version = "2.0.10" description = "Syncthing as a container using Docker" authors = [ { name = "BESANCON Vincent", email = "besancon.vincent@gmail.com" } @@ -15,7 +15,7 @@ dependencies = [ [tool.commitizen] name = "cz_conventional_commits" -version = "1.30.0" +version = "2.0.10" tag_format = "v$version" version_files = [ "pyproject.toml:version" diff --git a/rootfs/etc/syncthing/config.xml b/rootfs/etc/syncthing/config.xml index 6d68289..2e00f8b 100644 --- a/rootfs/etc/syncthing/config.xml +++ b/rootfs/etc/syncthing/config.xml @@ -1,4 +1,4 @@ - +
0.0.0.0:8384
static diff --git a/uv.lock b/uv.lock index a22e63f..a85ddf3 100644 --- a/uv.lock +++ b/uv.lock @@ -1,5 +1,5 @@ version = 1 -revision = 2 +revision = 3 requires-python = ">=3.11" [[package]] @@ -100,7 +100,7 @@ wheels = [ [[package]] name = "docker-syncthing" -version = "1.29.6" +version = "1.30.0" source = { virtual = "." } dependencies = [ { name = "commitizen" },