diff --git a/seaweedfs.yaml b/seaweedfs.yaml index 9f73efc2c34..3cea51f4dc8 100644 --- a/seaweedfs.yaml +++ b/seaweedfs.yaml @@ -1,7 +1,7 @@ package: name: seaweedfs version: "4.05" - epoch: 0 # GHSA-g754-hx8w-x2g6 + epoch: 1 description: SeaweedFS is a fast distributed storage system for blobs, objects, files. copyright: - license: Apache-2.0 @@ -9,6 +9,12 @@ package: runtime: - fuse2 +var-transforms: + - from: ${{package.version}} + match: ^(\d+).* + replace: $1 + to: major-version + environment: environment: CGO_ENABLED: "0" @@ -63,6 +69,63 @@ subpackages: test -x /entrypoint.sh /entrypoint.sh help | grep -F "SeaweedFS" + - name: ${{package.name}}-iamguarded-compat + description: Compatibility package for iamguarded variant of SeaweedFS + dependencies: + runtime: + - bash + - busybox + - procps + pipeline: + - uses: iamguarded/build-compat + with: + package: ${{package.name}} + version: ${{vars.major-version}} + - runs: | + mkdir -p ${{targets.contextdir}}/opt/iamguarded/seaweedfs/bin + mkdir -p ${{targets.contextdir}}/data + mkdir -p ${{targets.contextdir}}/tmp + chmod g+rwX ${{targets.contextdir}}/opt/iamguarded + chmod g+rwX ${{targets.contextdir}}/data + ln -sf /usr/bin/weed ${{targets.contextdir}}/opt/iamguarded/seaweedfs/bin/weed + - uses: iamguarded/finalize-compat + with: + package: ${{package.name}} + version: ${{vars.major-version}} + test: + environment: + contents: + packages: + - ${{package.name}} + - curl + - jq + - wait-for-it + environment: + MASTER_PORT: "9333" + pipeline: + - uses: iamguarded/test-compat + with: + package: ${{package.name}} + version: ${{vars.major-version}} + - uses: test/tw/symlink-check + with: + allow-absolute: true + - name: "Test master server startup and API" + uses: test/daemon-check-output + with: + start: /opt/iamguarded/seaweedfs/bin/weed master -ip=0.0.0.0 -port="${MASTER_PORT}" -mdir=/tmp/seaweedfs-test + timeout: 45 + expected_output: | + Start Seaweed Master + No existing leader found! + Initializing new cluster + post: | + wait-for-it "localhost:${MASTER_PORT}" -t 30 + + curl -sf "http://localhost:${MASTER_PORT}/cluster/status" | grep -F "Leader" + curl -sf "http://localhost:${MASTER_PORT}/dir/assign" | jq -e ".fid and .url" + curl -sf "http://localhost:${MASTER_PORT}/dir/status" | jq -e ".Topology" + test: environment: contents: @@ -73,10 +136,13 @@ test: environment: MASTER_PORT: "9333" pipeline: - - name: "Version and help commands" - runs: | - weed version | grep -F "${{package.version}}" - weed help | grep -F "SeaweedFS" + - uses: test/tw/ldd-check + - uses: test/tw/help-check + with: + bins: weed + - uses: test/tw/ver-check + with: + bins: weed - name: "Test master server startup and API" uses: test/daemon-check-output with: