Add ROCm
This commit is contained in:
parent
deb3487276
commit
f442b90730
44
.github/workflows/rocm.yml
vendored
Normal file
44
.github/workflows/rocm.yml
vendored
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
name: PikaOS Radeon ROCm Sync
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: self-hosted
|
||||||
|
container:
|
||||||
|
image: ghcr.io/pikaos-linux/pika-package-container:latest
|
||||||
|
volumes:
|
||||||
|
- /proc:/proc
|
||||||
|
options: --privileged -it
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Import GPG key
|
||||||
|
id: import_gpg
|
||||||
|
uses: crazy-max/ghaction-import-gpg@v5
|
||||||
|
with:
|
||||||
|
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
|
||||||
|
passphrase: ${{ secrets.PASSPHRASE }}
|
||||||
|
|
||||||
|
- name: Install SSH key
|
||||||
|
uses: shimataro/ssh-key-action@v2
|
||||||
|
with:
|
||||||
|
key: ${{ secrets.SSH_KEY }}
|
||||||
|
name: id_rsa
|
||||||
|
known_hosts: ${{ secrets.KNOWN_HOSTS }}
|
||||||
|
if_key_exists: replace
|
||||||
|
|
||||||
|
- name: Sync Repository
|
||||||
|
run: chmod +x ./rocm.sh && ./rocm.sh
|
||||||
|
|
||||||
|
- name: Purge cache
|
||||||
|
uses: jakejarvis/cloudflare-purge-action@master
|
||||||
|
env:
|
||||||
|
# Zone is required by both authentication methods
|
||||||
|
CLOUDFLARE_ZONE: ${{ secrets.CLOUDFLARE_ZONE }}
|
||||||
|
|
||||||
|
CLOUDFLARE_TOKEN: ${{ secrets.CLOUDFLARE_TOKEN }}
|
||||||
|
PURGE_URLS: ${{ vars.PURGE_URLS }}
|
||||||
|
|
10
amdgpu.sh
10
amdgpu.sh
@ -1,8 +1,6 @@
|
|||||||
#! /bin/bash
|
#! /bin/bash
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
apt install -y tree
|
|
||||||
|
|
||||||
# AMDGPU MIRROR
|
# AMDGPU MIRROR
|
||||||
mkdir -p ./output/amdgpu
|
mkdir -p ./output/amdgpu
|
||||||
cd ./output/amdgpu
|
cd ./output/amdgpu
|
||||||
@ -10,13 +8,13 @@ cd ./output/amdgpu
|
|||||||
mkdir -p ./libd
|
mkdir -p ./libd
|
||||||
cd ./libd
|
cd ./libd
|
||||||
wget --recursive --no-parent -m http://repo.radeon.com/amdgpu/5.5.3/ubuntu/pool/main/libd/
|
wget --recursive --no-parent -m http://repo.radeon.com/amdgpu/5.5.3/ubuntu/pool/main/libd/
|
||||||
# Retrun to AMDGPU MIRROR
|
# Return to AMDGPU MIRROR
|
||||||
cd ../
|
cd ../
|
||||||
# amdgpu proprietary dir
|
# amdgpu proprietary dir
|
||||||
mkdir -p ./proprietary
|
mkdir -p ./proprietary
|
||||||
cd ./proprietary
|
cd ./proprietary
|
||||||
wget --recursive --no-parent -m https://repo.radeon.com/amdgpu/5.5.3/ubuntu/pool/proprietary/
|
wget --recursive --no-parent -m https://repo.radeon.com/amdgpu/5.5.3/ubuntu/pool/proprietary/
|
||||||
# Retrun to AMDGPU MIRROR
|
# Return to AMDGPU MIRROR
|
||||||
cd ../
|
cd ../
|
||||||
# Get rid of all 20.04 deb files
|
# Get rid of all 20.04 deb files
|
||||||
find . -name \*20.04*.deb -exec rm -fv {} \;
|
find . -name \*20.04*.deb -exec rm -fv {} \;
|
||||||
@ -24,12 +22,10 @@ find . -name \*20.04*.deb -exec rm -fv {} \;
|
|||||||
mkdir -p ./amdgpu-dkms-firmware
|
mkdir -p ./amdgpu-dkms-firmware
|
||||||
cd ./amdgpu-dkms-firmware
|
cd ./amdgpu-dkms-firmware
|
||||||
wget http://repo.radeon.com/amdgpu/5.5.3/ubuntu/pool/main/a/amdgpu-dkms/amdgpu-dkms-firmware_6.0.5.50503-1620033.20.04_all.deb
|
wget http://repo.radeon.com/amdgpu/5.5.3/ubuntu/pool/main/a/amdgpu-dkms/amdgpu-dkms-firmware_6.0.5.50503-1620033.20.04_all.deb
|
||||||
# Retrun to AMDGPU MIRROR
|
# Return to AMDGPU MIRROR
|
||||||
cd ../
|
cd ../
|
||||||
mkdir -p ./output
|
mkdir -p ./output
|
||||||
find . -name \*.deb -exec cp -vf {} ./output \;
|
find . -name \*.deb -exec cp -vf {} ./output \;
|
||||||
# Check final result
|
|
||||||
tree
|
|
||||||
|
|
||||||
# Sign the packages
|
# Sign the packages
|
||||||
dpkg-sig --sign builder ./output/*.deb
|
dpkg-sig --sign builder ./output/*.deb
|
||||||
|
36
rocm.sh
Normal file
36
rocm.sh
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
apt install tree
|
||||||
|
|
||||||
|
# ROCm MIRROR
|
||||||
|
mkdir -p ./output/rocm
|
||||||
|
cd ./output/rocm
|
||||||
|
# Get ROCm pool
|
||||||
|
wget -np -c -r -v -nd -R "*20.04*.deb" -A "*" -m "http://repo.radeon.com/rocm/apt/5.6/pool/main/"
|
||||||
|
# Return to ROCm MIRROR
|
||||||
|
cd ../
|
||||||
|
mkdir -p ./output
|
||||||
|
find . -name \*.deb -exec cp -vf {} ./output \;
|
||||||
|
|
||||||
|
tree
|
||||||
|
|
||||||
|
# Sign the packages
|
||||||
|
#dpkg-sig --sign builder ./output/*.deb
|
||||||
|
|
||||||
|
# Pull down existing ppa repo db files etc
|
||||||
|
#rsync -azP --exclude '*.deb' ferreo@direct.pika-os.com:/srv/www/pikappa/ ./output/repo
|
||||||
|
|
||||||
|
# Check if the rocm component exists
|
||||||
|
#if cat ./output/repo/conf/distributions | grep Components: | grep rocm
|
||||||
|
#then
|
||||||
|
# true
|
||||||
|
#else
|
||||||
|
# sed -i "s#Components:#Components: rocm#" ./output/repo/conf/distributions
|
||||||
|
#fi
|
||||||
|
|
||||||
|
# Add the new package to the repo
|
||||||
|
#reprepro -C rocm -V --basedir ./output/repo/ includedeb lunar ./output/*.deb
|
||||||
|
|
||||||
|
# Push the updated ppa repo to the server
|
||||||
|
#rsync -azP ./output/repo/ ferreo@direct.pika-os.com:/srv/www/pikappa/
|
Loading…
Reference in New Issue
Block a user