mirror of
https://github.com/restic/rest-server.git
synced 2026-09-26 05:51:24 -07:00
Improve reproducibility of built archives
The binaries and generate archives should be reproducible now. Note that this does not apply to the source tarball.
This commit is contained in:
committed by
Alexander Neumann
parent
dedcb846df
commit
0a09c8d633
+17
-3
@@ -31,6 +31,8 @@ builds:
|
|||||||
# don't include any paths to source files in the resulting binary
|
# don't include any paths to source files in the resulting binary
|
||||||
- -trimpath
|
- -trimpath
|
||||||
|
|
||||||
|
mod_timestamp: '{{ .CommitTimestamp }}'
|
||||||
|
|
||||||
ldflags:
|
ldflags:
|
||||||
# set the version variable in the main package
|
# set the version variable in the main package
|
||||||
- "-s -w -X main.version={{ .Version }}"
|
- "-s -w -X main.version={{ .Version }}"
|
||||||
@@ -66,11 +68,23 @@ archives:
|
|||||||
# package a directory which contains the source file
|
# package a directory which contains the source file
|
||||||
wrap_in_directory: true
|
wrap_in_directory: true
|
||||||
|
|
||||||
|
builds_info: &archive_file_info
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
mtime: '{{ .CommitDate }}'
|
||||||
|
mode: 0644
|
||||||
|
|
||||||
# add these files to all archives
|
# add these files to all archives
|
||||||
files:
|
files:
|
||||||
- LICENSE
|
- src: LICENSE
|
||||||
- README.md
|
dst: .
|
||||||
- CHANGELOG.md
|
info: *archive_file_info
|
||||||
|
- src: README.md
|
||||||
|
dst: .
|
||||||
|
info: *archive_file_info
|
||||||
|
- src: CHANGELOG.md
|
||||||
|
dst: .
|
||||||
|
info: *archive_file_info
|
||||||
|
|
||||||
# also build an archive of the source code
|
# also build an archive of the source code
|
||||||
source:
|
source:
|
||||||
|
|||||||
Reference in New Issue
Block a user