Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
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
3 changes: 3 additions & 0 deletions .github/workflows/release-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,10 @@ jobs:
- name: Create artifact archive
run: |
mkdir artifacts
mkdir artifacts/gpg
cp ./scripts/install/*.sh ./artifacts
cp ./signature/gpg/bdot-public-gpg-key.asc ./artifacts/gpg/bdot-public-gpg-key.asc
cp -r ./signature/gpg/revocations ./artifacts/gpg/revocations
cp ./observiq-otel-collector.msi/observiq-otel-collector.msi ./artifacts
cp ./dist/*tar.gz ./artifacts
cp ./windows-archive/windows_amd64/*.zip ./artifacts
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,10 @@ jobs:
- name: Create artifact archive
run: |
mkdir artifacts
mkdir artifacts/gpg
cp ./scripts/install/*.sh ./artifacts
cp ./signature/gpg/bdot-public-gpg-key.asc ./artifacts/gpg/bdot-public-gpg-key.asc
cp -r ./signature/gpg/revocations ./artifacts/gpg/revocations
cp ./observiq-otel-collector.msi/observiq-otel-collector.msi ./artifacts
cp ./dist/*tar.gz ./artifacts
cp ./windows-archive/windows_amd64/*.zip ./artifacts
Expand All @@ -195,6 +198,8 @@ jobs:
run: |
gsutil cp ./scripts/install/install_unix.sh gs://bdot-release/latest/install_unix.sh
gsutil cp ./scripts/install/install_macos.sh gs://bdot-release/latest/install_macos.sh
gsutil cp ./signature/gpg/bdot-public-gpg-key.asc gs://bdot-release/latest/gpg/bdot-public-gpg-key.asc
gsutil cp -r ./signature/gpg/revocations gs://bdot-release/latest/gpg/revocations/
- name: Upload artifact bundle to release
uses: AButler/upload-release-assets@v2.0
with:
Expand Down
3 changes: 3 additions & 0 deletions .goreleaser.gpg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ archives:
- src: release_deps/windows_service.json
dst: install
strip_parent: true
- src: release_deps/gpg/*
dst: gpg
strip_parent: true
format_overrides:
- goos: windows
format: zip
Expand Down
7 changes: 6 additions & 1 deletion .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ project_name: observiq-otel-collector

before:
hooks:
- make release-prep CURR_VERSION={{ .Version }}
- make release-prep-gpg CURR_VERSION={{ .Version }}

# https://goreleaser.com/customization/build/
builds:
Expand Down Expand Up @@ -88,6 +88,9 @@ archives:
- src: release_deps/com.observiq.collector.plist
dst: "install"
strip_parent: true
- src: release_deps/gpg/*
dst: gpg
strip_parent: true

nfpms:
- id: collector
Expand Down Expand Up @@ -741,6 +744,7 @@ release:
- glob: "./observiq-otel-collector*.msi.sig"
- glob: "./scripts/install/install_unix.sh"
- glob: "./scripts/install/install_macos.sh"
- glob: "./release_deps/gpg-keys.zip"

# https://console.cloud.google.com/storage/browser/bdot-release
blobs:
Expand All @@ -752,6 +756,7 @@ blobs:
- glob: "./observiq-otel-collector*.msi.sig"
- glob: "./scripts/install/install_unix.sh"
- glob: "./scripts/install/install_macos.sh"
- glob: "./release_deps/gpg-keys.zip"
Comment on lines 753 to +765
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will the user and install script retrieve the key from gs://bdot-release/latest/gpg/bdot-public-gpg-key.asc? (The equivalent HTTP uri). That makes sense if we want the user to always retrieve the latest public key.

If the install script should use the public key versioned in the release, we should upload it outside of the zip file to its release directory in the bucket.

I suspect it is fine how you have it now, but I want to make sure. We can avoid the user needing to download and unzip this file.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So the tricky thing is that we really want the install script to both retrieve both the key and any revocations and import them all, this will allow for both the installation of software signed by the current key and prevent installation of software signed by any revoked keys. I can't think of a great way to do that besides zipping everything we want them to import into one folder so they have to take all of it instead of cherrypicking.


# https://goreleaser.com/customization/changelog/
changelog:
Expand Down
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -242,11 +242,18 @@ release-prep:
@echo 'v$(CURR_VERSION)' > release_deps/VERSION.txt
./buildscripts/download-dependencies.sh release_deps
@cp -r ./plugins release_deps/
@cp -r ./signature/gpg release_deps/gpg
@rm release_deps/gpg/revocations.md
@cp config/example.yaml release_deps/config.yaml
@cp config/logging.yaml release_deps/logging.yaml
@cp service/com.observiq.collector.plist release_deps/com.observiq.collector.plist
@jq ".files[] | select(.service != null)" windows/wix.json >> release_deps/windows_service.json

.PHONY: release-prep-gpg
release-prep-gpg:
$(MAKE) release-prep
@cd release_deps/gpg && zip -r ../gpg-keys.zip .

# Build and sign, skip release and ignore dirty git tree
.PHONY: release-test
release-test:
Expand Down
87 changes: 87 additions & 0 deletions signature/gpg/bdot-public-gpg-key.asc
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----

mQINBGkcxWUBEADa+YPrVwO4J3g6ELtLQUyixx4nbIa88bD8lpxztTfizMLczxMv
tlMGhDUgRPg7LJjebNq+C9XdcNjrce2PntVj8BNpXx+D8Qidxe+m0vM/BVs5EDp4
MHB8WIT+LVVPqAJB3970Joj7xNv9I6kqEB3KAp9S47/RFA8w/mi8ca+heH2N4yEs
SkcroDZvspjg7RdfoEn1YN6WVvfcT21nB/bsWnW+m78XOQXl0oodTFoidligsYkq
XxawY5jzNTtJ5mQPk+X3ip4dFPN+S7w2FPbvOJS0vI94q1pdwEtzDkwGXjyZsHFi
bVG2DnaYEsP5W3Tc7dUMBdD2VMWM3T4GKd6WlgTas9RM8mU14Izo2CmqY7waDVia
cIDbN2DYfl2WQHzsOBu2Fu07Otr1fQrFR91Nk4LyUtkxPHk+cXVUzt0VYVuQE52d
xc/6DwzSeiJ5J+pFyKHjMqUF0xZkO1trz3u9N8BK5eA68DMTxdlYbYQRh/pXyMtP
3RoQqHvK5ZrHqzWJ97p4lWBV+XjkOzV8H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tcx6C+Hp1rV7niT6yrs7WT9gxg2bcbidk5Avjr
cR1YIFN4OXPl77ndpStYsW46aQbw96ojv7I+PdgxaDHxseX3ix1Pb159V0ATnl1q
cUim52mDFQYlme3V3Bq7e0dUCr8hMPVi2VxKcu87vfSvv+GTFO5im+o+3O7NpBP0
NP8DMx2aMBZqjTBNp/d5lZxqJjHUOHujHVMFLCl2UTCksSCdYGJVVP3bNP2nGbFq
ZdUea/IyCKbD7YYZeTSDAxHYtGpocAGoa1eMg4OUm5alCidag3cPjcJ7QF+axHAQ
V1EIlgGozufLIEan4FYw5b1PZlxqeReFD4MbCDZEh5bsfX58MtcbHW2IXjCydTNR
UKoLK8/cG3/KpGfXO8MkHV4myuq44TjUSkNjttbGdgajpP5CsPcHkBciBUXO+weX
0wBNL9biSvLC/n9eoYX1y/yEIhP0TenSh8elxQaAIkzW7kLQdnWDCdXiLlevNgU8
J8ou98jsYb6bLlenuyiMQVBgNDk1NxzZ
=VtDX
-----END PGP PUBLIC KEY BLOCK-----
7 changes: 7 additions & 0 deletions signature/gpg/revocations.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# GPG Key Revocations

Any primary public keys that have been revoked should be placed within the `revocations` folder.

If a primary keypair has been lost or destroyed, its revocation certificate should be placed within the `revocations` folder.

Once one of the above two steps has been taken for the revoked keypair, the release action and install scripts will distribute the revocations to prevent users from installing new software signed using the revoked keypair.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure if this will work, unfortunately this revocations folder needs to be empty but included for now. Hoping I can delete this file in a future commit/PR and have git keep the empty folder around.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ive seen .keep file name before. I think that would work fine.

Empty file.
Loading