diff --git a/rules/chrome.json b/rules/chrome.json index d32334e..731d208 100644 --- a/rules/chrome.json +++ b/rules/chrome.json @@ -1,90 +1,133 @@ { - "patterns": [ - "\\bchrome\\b" - ], + "patterns": ["\\bchrome\\b", "\\bchromium\\b"], "dependencies": [ { "pre_install": [ - { "command": "[ $(which google-chrome) ] || apt-get install -y gnupg curl" }, - { "command": "[ $(which google-chrome) ] || curl -fsSL -o /tmp/google-chrome.deb https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb" }, - { "command": "[ $(which google-chrome) ] || DEBIAN_FRONTEND='noninteractive' apt-get install -y /tmp/google-chrome.deb" } - ], - "packages": [], - "post_install": [ - { "command": "rm -f /tmp/google-chrome.deb" } + { "command": "apt-get install -y software-properties-common" }, + { "command": "add-apt-repository -y ppa:xtradeb/apps" }, + { "command": "apt-get update" } ], + "packages": ["chromium"], + "post_install": [], "constraints": [ { "os": "linux", - "distribution": "ubuntu" - }, - { - "os": "linux", - "distribution": "debian" + "distribution": "ubuntu", + "versions": ["22.04", "24.04"] } ] }, { "pre_install": [ - { "command": "yum install -y which" }, - { "command": "[ $(which google-chrome) ] || curl -fsSL -o /tmp/google-chrome.rpm https://dl.google.com/linux/direct/google-chrome-stable_current_x86_64.rpm" }, - { "command": "[ $(which google-chrome) ] || yum install -y /tmp/google-chrome.rpm" } + { + "command": "[ $(which google-chrome) ] || apt-get install -y gnupg curl" + }, + { + "command": "[ $(which google-chrome) ] || curl -fsSL -o /tmp/google-chrome.deb https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb" + }, + { + "command": "[ $(which google-chrome) ] || DEBIAN_FRONTEND='noninteractive' apt-get install -y /tmp/google-chrome.deb" + } ], "packages": [], - "post_install": [ - { "command": "rm -f /tmp/google-chrome.rpm" } - ], + "post_install": [{ "command": "rm -f /tmp/google-chrome.deb" }], "constraints": [ { "os": "linux", - "distribution": "centos", - "versions": ["8"] - }, + "distribution": "ubuntu", + "versions": ["20.04"] + } + ] + }, + { + "pre_install": [ + { "command": "dnf install -y dnf-plugins-core" }, + { "command": "dnf config-manager --set-enabled crb" }, + { "command": "dnf install -y epel-release" } + ], + "packages": ["chromium"], + "post_install": [], + "constraints": [ { "os": "linux", "distribution": "rockylinux" + } + ] + }, + { + "pre_install": [ + { + "command": "subscription-manager repos --enable codeready-builder-for-rhel-8-$(arch)-rpms" }, + { + "command": "dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm" + } + ], + "packages": ["chromium"], + "post_install": [], + "constraints": [ { "os": "linux", "distribution": "redhat", "versions": ["8"] + } + ] + }, + { + "pre_install": [ + { + "command": "subscription-manager repos --enable codeready-builder-for-rhel-9-$(arch)-rpms" }, + { + "command": "dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm" + } + ], + "packages": ["chromium"], + "post_install": [], + "constraints": [ { "os": "linux", - "distribution": "fedora", - "versions": [ "36", "37" ] + "distribution": "redhat", + "versions": ["9"] } ] }, { - "pre_install": [ - { "command": "yum install -y which" }, - { "command": "[ $(which google-chrome) ] || curl -fsSL -o /tmp/google-chrome.rpm https://dl.google.com/linux/chrome/rpm/stable/x86_64/google-chrome-stable-125.0.6422.141-1.x86_64.rpm" }, - { "command": "[ $(which google-chrome) ] || yum install -y /tmp/google-chrome.rpm" } - ], - "packages": [], - "post_install": [ - { "command": "rm -f /tmp/google-chrome.rpm" } - ], + "pre_install": [], + "packages": ["chromium"], + "post_install": [], "constraints": [ { "os": "linux", - "distribution": "centos", - "versions": ["7"] + "distribution": "debian" }, { "os": "linux", - "distribution": "redhat", - "versions": ["7"] + "distribution": "fedora" + }, + { + "os": "linux", + "distribution": "alpine" } ] }, { - "packages": ["chromium"], + "pre_install": [ + { "command": "yum install -y which" }, + { + "command": "[ $(which google-chrome) ] || curl -fsSL -o /tmp/google-chrome.rpm https://dl.google.com/linux/chrome/rpm/stable/x86_64/google-chrome-stable-125.0.6422.141-1.x86_64.rpm" + }, + { + "command": "[ $(which google-chrome) ] || yum install -y /tmp/google-chrome.rpm" + } + ], + "packages": [], + "post_install": [{ "command": "rm -f /tmp/google-chrome.rpm" }], "constraints": [ { "os": "linux", - "distribution": "alpine" + "distribution": "centos", + "versions": ["7", "8"] } ] }