mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-01-23 13:51:06 -05:00
ci: remove unused actions
Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
parent
9d90ab6df7
commit
dccb1dfde9
26
.github/actions/install_docgen/action.yml
vendored
26
.github/actions/install_docgen/action.yml
vendored
@ -1,26 +0,0 @@
|
||||
name: Install Docgen
|
||||
description: |
|
||||
Install Docgen
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Checkout talos
|
||||
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
repository: "siderolabs/talos"
|
||||
ref: "v1.3.1"
|
||||
path: talos
|
||||
|
||||
# This is required to be able to build docgen
|
||||
- name: Remove go.work
|
||||
shell: bash
|
||||
working-directory: talos
|
||||
run: rm go.work*
|
||||
|
||||
- name: Install Docgen
|
||||
shell: bash
|
||||
working-directory: talos/hack/docgen
|
||||
run: |
|
||||
go build -o docgen .
|
||||
mv docgen /usr/local/bin
|
24
.github/actions/install_operator_sdk/action.yml
vendored
24
.github/actions/install_operator_sdk/action.yml
vendored
@ -1,24 +0,0 @@
|
||||
name: Install operator-sdk
|
||||
description: |
|
||||
Installs the operator-sdk binary.
|
||||
inputs:
|
||||
version:
|
||||
description: "Version of the operator-sdk to install"
|
||||
required: true
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Install operator-sdk
|
||||
shell: bash
|
||||
run: |
|
||||
export ARCH=$(case $(uname -m) in x86_64) echo -n amd64 ;; aarch64) echo -n arm64 ;; *) echo -n $(uname -m) ;; esac)
|
||||
export OS=$(uname | awk '{print tolower($0)}')
|
||||
export OPERATOR_SDK_DL_URL=https://github.com/operator-framework/operator-sdk/releases/download/${{ inputs.version }}
|
||||
curl -fsSLO ${OPERATOR_SDK_DL_URL}/operator-sdk_${OS}_${ARCH}
|
||||
gpg --keyserver keyserver.ubuntu.com --recv-keys 052996E2A20B5C7E
|
||||
curl -fsSLO ${OPERATOR_SDK_DL_URL}/checksums.txt
|
||||
curl -fsSLO ${OPERATOR_SDK_DL_URL}/checksums.txt.asc
|
||||
gpg -u "Operator SDK (release) <cncf-operator-sdk@cncf.io>" --verify checksums.txt.asc
|
||||
grep operator-sdk_${OS}_${ARCH} checksums.txt | sha256sum -c -
|
||||
chmod +x operator-sdk_${OS}_${ARCH} && sudo mv operator-sdk_${OS}_${ARCH} /usr/local/bin/operator-sdk
|
||||
rm checksums.txt checksums.txt.asc
|
57
.github/actions/setup_linux/action.yml
vendored
57
.github/actions/setup_linux/action.yml
vendored
@ -1,57 +0,0 @@
|
||||
name: Setup Linux build environment
|
||||
description: "Setup a Linux Build environment (for self-hosted runners)"
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Setup custom apt repositories (azure-cli & yq)
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install ca-certificates curl apt-transport-https lsb-release gnupg -y
|
||||
curl -fsSL https://packages.microsoft.com/keys/microsoft.asc |
|
||||
gpg --dearmor |
|
||||
sudo tee /etc/apt/trusted.gpg.d/microsoft.gpg > /dev/null
|
||||
AZ_REPO=$(lsb_release -cs)
|
||||
echo "deb [arch=amd64] https://packages.microsoft.com/repos/azure-cli/ $AZ_REPO main" |
|
||||
sudo tee /etc/apt/sources.list.d/azure-cli.list
|
||||
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CC86BB64
|
||||
sudo add-apt-repository ppa:rmescandon/yq
|
||||
|
||||
- name: Update apt repository information
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get update
|
||||
|
||||
- name: Install build-essential & CMake
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get install \
|
||||
build-essential cmake \
|
||||
-y
|
||||
|
||||
- name: Install curl gpg
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get install curl gpg -y
|
||||
|
||||
- name: Install yq jq
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get install yq jq -y
|
||||
|
||||
- name: Install AWS CLI
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get -y install awscli
|
||||
|
||||
- name: Install az CLI
|
||||
shell: bash
|
||||
run: |
|
||||
sudo apt-get install azure-cli -y
|
||||
|
||||
- name: Set up gcloud CLI
|
||||
uses: google-github-actions/setup-gcloud@e30db14379863a8c79331b04a9969f4c1e225e0b # v1.1.1
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
id: docker-setup
|
||||
uses: docker/setup-buildx-action@16c0bc4a6e6ada2cfd8afd41d22d95379cf7c32a # v2.8.0
|
@ -19,41 +19,41 @@ cd "${BUILD_WORKSPACE_DIRECTORY}"
|
||||
# .github/actions that are not used in any workflow or action YAML.
|
||||
# We only want directory of that exact level and ignore subdirectories.
|
||||
actionNames=$(
|
||||
find .github/actions \
|
||||
-maxdepth 2 \
|
||||
-type d \
|
||||
! -name actions
|
||||
find .github/actions \
|
||||
-maxdepth 2 \
|
||||
-type d \
|
||||
! -name actions
|
||||
)
|
||||
|
||||
actionYMLs=$(
|
||||
find .github/actions \
|
||||
! -name actions \
|
||||
-type f \
|
||||
-name '*.yml'
|
||||
find .github/actions \
|
||||
! -name actions \
|
||||
-type f \
|
||||
-name '*.yml'
|
||||
)
|
||||
|
||||
workflowYMLs=$(
|
||||
find .github/workflows \
|
||||
-type f \
|
||||
-name '*.yml'
|
||||
find .github/workflows \
|
||||
-type f \
|
||||
-name '*.yml'
|
||||
)
|
||||
|
||||
exitcode=0
|
||||
|
||||
for action in ${actionNames}; do
|
||||
used=false
|
||||
used=false
|
||||
|
||||
for yml in ${actionYMLs} ${workflowYMLs}; do
|
||||
if grep -q "${action}" "${yml}"; then
|
||||
used=true
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if ! ${used}; then
|
||||
echo "Action ${action} is unused"
|
||||
exitcode=1
|
||||
for yml in ${actionYMLs} ${workflowYMLs}; do
|
||||
if grep -q "${action}" "${yml}"; then
|
||||
used=true
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if ! ${used}; then
|
||||
echo "Action ${action} is unused"
|
||||
exitcode=1
|
||||
fi
|
||||
done
|
||||
|
||||
exit "${exitcode}"
|
Loading…
Reference in New Issue
Block a user