-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
221 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
#!/usr/bin/env bash | ||
|
||
function info () { | ||
echo >&2 "===]> Info: $* "; | ||
} | ||
|
||
info "Print information about agent..." | ||
|
||
echo -e '\n' | ||
info "uname -a" | ||
uname -a | ||
echo -e '\n' | ||
|
||
info "CPU threads: $(nproc --all)" | ||
info "CPU $(grep 'model name' /proc/cpuinfo | uniq)" | ||
info "CPU freq:" | ||
grep 'MHz' /proc/cpuinfo | ||
echo -e '\n' | ||
|
||
info "Egress Public IP: $(curl -4 -s ifconfig.co)" | ||
echo -e '\n' | ||
|
||
info "pwd" | ||
pwd | ||
echo -e '\n' | ||
|
||
info "df -h" | ||
df -h | ||
echo -e '\n' | ||
|
||
info "free -m" | ||
free -m | ||
echo -e '\n' | ||
|
||
info "w" | ||
w | ||
echo -e '\n' | ||
|
||
info "Top 5 processes sorted by CPU usage..." | ||
ps -Ao user,uid,pid,pcpu,pmem,command,cmd --sort=-pcpu | head -n 6 | ||
echo -e '\n' | ||
|
||
info "Top 5 processes sorted by MEM usage..." | ||
ps -Ao user,uid,pid,pcpu,pmem,command,cmd --sort=-pmem | head -n 6 | ||
echo -e '\n' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
#!/usr/bin/env bash | ||
|
||
function info () { | ||
echo >&2 "===]> Info: $* "; | ||
} | ||
|
||
info "Remove unneeded stuff from GitHub Actions Runner..." | ||
|
||
|
||
# 11,2 GiB [###################################] /android | ||
info "Removing Android SDK from /usr/local/lib/android..." | ||
rm -rf /usr/local/lib/android | ||
|
||
# 6,1 GiB [###################################] /hostedtoolcache | ||
|
||
# 2,7 GiB [###################################] /CodeQL | ||
# 1,3 GiB [################# ] /go | ||
# 1,2 GiB [############### ] /Python | ||
# 499,0 MiB [###### ] /PyPy | ||
# 372,6 MiB [#### ] /node | ||
# 60,9 MiB [ ] /Ruby | ||
# 16,0 KiB [ ] /Java_Temurin-Hotspot_jdk | ||
|
||
info "Removing CodeQL..." | ||
rm -rf /opt/hostedtoolcache/CodeQL | ||
info "Removing go..." | ||
rm -rf /opt/hostedtoolcache/go | ||
|
||
# 1,3 GiB [###################################] /jvm | ||
|
||
info "Removing jvm..." | ||
rm -rf /usr/lib/jvm | ||
|
||
# 1,1 GiB [###################################] /powershell | ||
|
||
# rm -rf /usr/local/share/powershell | ||
|
||
# 2,7 GiB [###################################] /dotnet | ||
|
||
info "Removing dotnet core..." | ||
rm -rf /usr/share/dotnet | ||
|
||
# 1,6 GiB [###################################] /swift | ||
|
||
info "Removing swift..." | ||
rm -rf /usr/share/swift | ||
|
||
info "Removing all docker images..." | ||
# shellcheck disable=SC2046 | ||
docker rmi $(docker images | awk '{print $3}') | ||
|
||
info "Cleaning up docker storage..." | ||
docker system prune -f --volumes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
--- | ||
name: Check runner storage | ||
|
||
# yamllint disable-line rule:truthy | ||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- master | ||
|
||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#choosing-github-hosted-runners | ||
# https://hub.docker.com/_/alpine | ||
jobs: | ||
tests20: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: "AgentInfo before" | ||
run: ./.github/agent-info.sh | ||
- name: "ncdu" | ||
run: | | ||
sudo apt-get update; | ||
sudo apt-get install -y ncdu; | ||
cd / | ||
ncdu -o /tmp/ncdu20.json | ||
- name: Archive ncdu output | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: ncdu20-report | ||
path: /tmp/ncdu20.json | ||
- name: "AgentInfo after" | ||
run: ./.github/agent-info.sh | ||
tests22: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: "AgentInfo before" | ||
run: ./.github/agent-info.sh | ||
- name: "ncdu" | ||
run: | | ||
sudo apt-get update; | ||
sudo apt-get install -y ncdu; | ||
cd / | ||
ncdu -o /tmp/ncdu22.json | ||
- name: Archive ncdu output | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: ncdu22-report | ||
path: /tmp/ncdu22.json | ||
- name: "AgentInfo after" | ||
run: ./.github/agent-info.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
[fedora-mbp] | ||
name=Fedora MBP | ||
baseurl=https://fedora-mbp-repo.herokuapp.com/ | ||
gpgcheck=1 | ||
enabled=1 | ||
cost=998 | ||
priority=98 | ||
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-mbp |
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
yum-repo/mbp-fedora-t2-config/rpm.spec → yum-repo/specs/mbp-fedora-t2-config.spec
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
Name: mbp-fedora-t2-repo | ||
Version: 1.0.0 | ||
Release: 1%{?dist} | ||
Summary: RPM repo for mbp-fedora on Apple T2 Macs. | ||
|
||
%undefine _disable_source_fetch | ||
|
||
License: GPLv2+ | ||
URL: https://github.com/mikeeq/mbp-fedora | ||
|
||
%description | ||
RPM repo with packages for mbp-fedora on Apple T2 Macs. | ||
|
||
%prep | ||
cp -rf %{_sourcedir}/repo %{_builddir}/ | ||
|
||
%build | ||
|
||
%install | ||
mkdir -p %{buildroot}/etc/pki/rpm-gpg | ||
mv %{_builddir}/repo/fedora-mbp.gpg %{buildroot}/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-mbp | ||
|
||
mkdir -p %{buildroot}/etc/yum.repos.d | ||
mv %{_builddir}/repo/fedora-mbp-external.repo %{buildroot}/etc/yum.repos.d/fedora-mbp.repo | ||
|
||
|
||
%files | ||
/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-mbp | ||
/etc/yum.repos.d/fedora-mbp.repo |