Skip to content
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
89 changes: 89 additions & 0 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -159,3 +159,92 @@ jobs:
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

update-package-repos:
name: Update APT & RPM Repositories
needs: release
runs-on: ubuntu-latest
permissions:
contents: write

steps:
- name: Install dependencies
run: sudo apt-get update && sudo apt-get install -y createrepo-c

- name: Checkout gh-pages branch
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: gh-pages
path: gh-pages
persist-credentials: true

- name: Download .deb and .rpm packages from release
env:
GH_TOKEN: ${{ github.token }}
TAG: ${{ github.ref_name }}
run: |
mkdir ./packages
gh release download $TAG --dir ./packages -p "*.deb"
gh release download $TAG --dir ./packages -p "*.rpm"

- name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@e89d40939c28e39f97cf32126055eeae86ba74ec # v6.3.0
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}

- name: Update APT repository
working-directory: ./gh-pages
run: |
# Move new .deb files into the repository
find ../packages -name "*_amd64.deb" -exec mv {} dists/stable/main/binary-amd64/ \;
find ../packages -name "*_arm64.deb" -exec mv {} dists/stable/main/binary-arm64/ \;
# Generate Packages metadata
apt-ftparchive packages dists/stable/main/binary-amd64 > dists/stable/main/binary-amd64/Packages
gzip -k -f dists/stable/main/binary-amd64/Packages
apt-ftparchive packages dists/stable/main/binary-arm64 > dists/stable/main/binary-arm64/Packages
gzip -k -f dists/stable/main/binary-arm64/Packages
# Generate and sign the Release file
apt-ftparchive \
-o APT::FTPArchive::Release::Origin="Seagate Technology" \
-o APT::FTPArchive::Release::Label="cloudfuse" \
-o APT::FTPArchive::Release::Suite="stable" \
-o APT::FTPArchive::Release::Codename="stable" \
-o APT::FTPArchive::Release::Architectures="amd64 arm64" \
-o APT::FTPArchive::Release::Components="main" \
-o APT::FTPArchive::Release::Description="APT repository for cloudfuse" \
release dists/stable > dists/stable/Release
gpg --clearsign -u "${STEPS_IMPORT_GPG_OUTPUTS_FINGERPRINT}" --batch --pinentry-mode loopback --passphrase "${SECRET_GPG_PASSPHRASE}" -o dists/stable/InRelease dists/stable/Release
gpg -u "${STEPS_IMPORT_GPG_OUTPUTS_FINGERPRINT}" --batch --pinentry-mode loopback --passphrase "${SECRET_GPG_PASSPHRASE}" -abs -o dists/stable/Release.gpg dists/stable/Release
env:
STEPS_IMPORT_GPG_OUTPUTS_FINGERPRINT: ${{ steps.import_gpg.outputs.fingerprint }}
SECRET_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}

- name: Update RPM repository
working-directory: ./gh-pages
run: |
# Move new .rpm files
find ../packages -name "*.rpm" -exec mv {} rpm-repo/ \;
# Create/update repository metadata
createrepo_c --database rpm-repo/
# Sign the repository metadata
gpg --detach-sign --armor -u "${STEPS_IMPORT_GPG_OUTPUTS_FINGERPRINT}" --batch --pinentry-mode loopback --passphrase "${SECRET_GPG_PASSPHRASE}" rpm/repodata/repomd.xml
env:
STEPS_IMPORT_GPG_OUTPUTS_FINGERPRINT: ${{ steps.import_gpg.outputs.fingerprint }}
SECRET_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}

- name: Commit and push repository updates
working-directory: ./gh-pages
env:
GITHUB_REF_NAME: ${{ github.ref_name }}
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add .
if git diff-index --quiet HEAD; then
echo "No changes to commit."
else
git commit -m "Update APT & RPM repositories for release ${GITHUB_REF_NAME}"
git push
fi
54 changes: 53 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,68 @@ Download and run the .exe installer from our latest release [here](https://githu

#### Debian /Ubuntu

##### Using Release on GitHub

Download the .deb file from our latest release [here](https://github.com/Seagate/cloudfuse/releases) and run the following command in your terminal:

`sudo apt-get install ./cloudfuse*.deb`

#### CentOS / RHEL
##### Using APT Repository

1. **Add the GPG key for the repository:**

```bash
sudo apt-get update
sudo apt-get install -y curl gpg
curl -fsSL https://seagate.github.io/cloudfuse/public.key | sudo gpg --dearmor -o /usr/share/keyrings/cloudfuse-archive-keyring.gpg
```

2. **Add the repository to your APT sources:**

```bash
echo "deb [signed-by=/usr/share/keyrings/cloudfuse-archive-keyring.gpg] https://seagate.github.io/cloudfuse stable main" | sudo tee /etc/apt/sources.list.d/cloudfuse.list > /dev/null
```

3. **Install `cloudfuse`:**

```bash
sudo apt-get update
sudo apt-get install cloudfuse
```

#### Fedora / RHEL

##### Using Release on GitHub

Download the .rpm file from our latest release [here](https://github.com/Seagate/cloudfuse/releases) and run the following command in your terminal:

`sudo rpm -i ./cloudfuse*.rpm`

##### Using YUM/DNF Repository

1. **Add the `cloudfuse` repository:**

```bash
sudo tee /etc/yum.repos.d/cloudfuse.repo <<EOF
[cloudfuse]
name=cloudfuse Repository
baseurl=https://seagate.github.io/cloudfuse/rpm-repo/
enabled=1
gpgcheck=1
gpgkey=https://seagate.github.io/cloudfuse/public.key
EOF
```

2. **Install `cloudfuse`:**

```bash
# For Fedora, RHEL 8+
sudo dnf install cloudfuse

# For RHEL 7
sudo yum install cloudfuse
```

#### Enable Running With Systemd

To enable Cloudfuse to run using systemd, see [Setup for systemd instructions](setup/readme.md)
Expand Down
Loading