Update chrome_thel8.yml

This commit is contained in:
rl544
2026-03-23 17:58:53 +09:00
committed by GitHub
parent 85ae37bea9
commit a3eb56edbc
+27 -21
View File
@@ -1,36 +1,42 @@
name: Get Chrome RPMs for RHEL8 name: Export Chrome RPM Bundle (RHEL8)
on: on:
workflow_dispatch: # 수동 실행 버튼 활성화 workflow_dispatch:
jobs: jobs:
download-rpms: build-bundle:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Extract RPMs using RHEL8-like Docker - name: Checkout
uses: actions/checkout@v4
- name: Fetch RPMs and Zip
run: | run: |
# 1. RHEL 8 호환 이미지(Oracle Linux 8) 실행 및 패키지 다운로드 # 1. 도커 내부에서 RPM 수집 (경로 및 명령어 최적화)
docker run --name rpm-fetcher -v ${{ github.workspace }}:/out oraclelinux:8 /bin/bash -c " docker run --name fetcher -v ${{ github.workspace }}:/output oraclelinux:8 /bin/bash -c "
# 저장소 설정
dnf install -y dnf-utils; dnf install -y dnf-utils;
cat <<EOF > /etc/yum.repos.d/google-chrome.repo # 저장소 설정 (echo 방식으로 변경하여 EOF 오류 방지)
[google-chrome] echo '[google-chrome]' > /etc/yum.repos.d/google-chrome.repo;
name=google-chrome echo 'name=google-chrome' >> /etc/yum.repos.d/google-chrome.repo;
baseurl=http://dl.google.com echo 'baseurl=http://dl.google.com' >> /etc/yum.repos.d/google-chrome.repo;
enabled=1 echo 'enabled=1' >> /etc/yum.repos.d/google-chrome.repo;
gpgcheck=1 echo 'gpgcheck=1' >> /etc/yum.repos.d/google-chrome.repo;
gpgkey=https://dl-ssl.google.com echo 'gpgkey=https://dl-ssl.google.com' >> /etc/yum.repos.d/google-chrome.repo;
EOF
# 의존성 포함 모든 RPM 다운로드 mkdir -p /bundle;
mkdir /chrome_bundle; # 의존성 포함 전체 다운로드
dnf download --resolve --alldeps -y google-chrome-stable --destdir=/chrome_bundle; dnf download --resolve --alldeps -y google-chrome-stable --destdir=/bundle;
cp -r /chrome_bundle/* /out/ # 결과를 공유 볼륨으로 이동
cp /bundle/*.rpm /output/;
" "
zip -r chrome-rhel8-bundle.zip ./*.rpm
# 2. 결과물 확인 후 압축
ls -lh *.rpm # 파일이 잘 받아졌는지 로그에 출력
zip chrome-rhel8-bundle.zip ./*.rpm
- name: Upload Zip Artifact - name: Upload Zip Artifact
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: chrome-bundle-file name: chrome-bundle-file
path: chrome-rhel8-bundle.zip path: chrome-rhel8-bundle.zip
retention-days: 1 # 1일 후 자동 삭제 retention-days: 1