Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "feat: add attestation to installer" #18089

Merged
merged 1 commit into from
Aug 19, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
4 changes: 0 additions & 4 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,6 @@ jobs:
fail-fast: false
matrix:
version: ["18.04", "20.04", "22.04", "24.04"]
permissions:
contents: read # for code access
attestations: write # for actions/attest-build-provenance
id-token: write # for actions/attest-build-provenance
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
Expand Down
9 changes: 0 additions & 9 deletions .github/workflows/pkg-installer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@ jobs:
build:
if: github.repository_owner == 'Homebrew' && github.actor != 'dependabot[bot]'
runs-on: macos-latest
permissions:
contents: read # for code access
attestations: write # for actions/attest-build-provenance
id-token: write # for actions/attest-build-provenance
outputs:
installer_path: "Homebrew-${{ steps.homebrew-version.outputs.version }}.pkg"
env:
Expand Down Expand Up @@ -123,11 +119,6 @@ jobs:
security delete-keychain "${RUNNER_TEMP}/${TEMPORARY_KEYCHAIN_FILE}"
fi

- name: Generate build provenance
uses: actions/attest-build-provenance@5e9cb68e95676991667494a6a4e59b8a2f13e1d0 # v1.3.3
with:
subject-path: Homebrew-${{ steps.homebrew-version.outputs.version }}.pkg

- name: Upload installer to GitHub Actions
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4
with:
Expand Down
28 changes: 6 additions & 22 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -239,30 +239,14 @@ jobs:
- name: Deploy the Docker image to GitHub Packages and Docker Hub
if: github.ref == 'refs/heads/master'
run: |
echo ${{ secrets.HOMEBREW_BREW_GITHUB_PACKAGES_TOKEN }} |
echo ${{secrets.HOMEBREW_BREW_GITHUB_PACKAGES_TOKEN}} |
docker login ghcr.io -u BrewTestBot --password-stdin
docker tag brew "ghcr.io/homebrew/ubuntu22.04:${{ github.ref_name }}"
docker push "ghcr.io/homebrew/ubuntu22.04:${{ github.ref_name }}"
echo ${{ secrets.HOMEBREW_BREW_DOCKER_TOKEN }} |
docker tag brew "ghcr.io/homebrew/ubuntu22.04:master"
docker push "ghcr.io/homebrew/ubuntu22.04:master"
echo ${{secrets.HOMEBREW_BREW_DOCKER_TOKEN}} |
docker login -u brewtestbot --password-stdin
docker tag brew "homebrew/ubuntu22.04:${{ github.ref_name }}"
docker push "homebrew/ubuntu22.04:${{ github.ref_name }}"

- name: Generate Docker image digest
if: github.ref == 'refs/heads/master'
id: digest
run: |
digest="$(docker image inspect --format='{{.Digest}}' brew)"
echo "digest=$digest" >> "$GITHUB_OUTPUT"

- name: Generate Docker image build provenance
uses: actions/attest-build-provenance@5e9cb68e95676991667494a6a4e59b8a2f13e1d0 # v1.3.3
if: github.ref == 'refs/heads/master'
id: attest
with:
push-to-registry: true
subject-digest: ${{ steps.digest.outputs.digest }}
subject-name: ghcr.io/homebrew/ubuntu22.04:${{ github.ref_name }}
docker tag brew "homebrew/ubuntu22.04:master"
docker push "homebrew/ubuntu22.04:master"

update-test:
name: ${{ matrix.name }}
Expand Down
Loading