From 8a2040df0cc5f376572c95249a51e78968739efa Mon Sep 17 00:00:00 2001 From: Antoine Rybacki <15911822+Lifeismana@users.noreply.github.com> Date: Tue, 9 Jul 2024 20:45:59 +0200 Subject: [PATCH] maybe --- .github/workflows/run.yml | 14 +++++++------- Dockerfile | 9 ++++++++- script.sh | 2 +- setup.sh | 2 ++ 4 files changed, 18 insertions(+), 9 deletions(-) create mode 100755 setup.sh diff --git a/.github/workflows/run.yml b/.github/workflows/run.yml index 4f79a31..5e3a433 100644 --- a/.github/workflows/run.yml +++ b/.github/workflows/run.yml @@ -32,13 +32,13 @@ jobs: # remove-android: 'true' # remove-haskell: 'true' # remove-codeql: 'true' - - name: More space - shell: bash - run: | - sudo rm -rf /usr/share/dotnet - sudo rm -rf /usr/local/lib/android - sudo rm -rf /opt/ghc - sudo rm -rf /opt/hostedtoolcache/CodeQL + # - name: More space + # shell: bash + # run: | + # sudo rm -rf /usr/share/dotnet + # sudo rm -rf /usr/local/lib/android + # sudo rm -rf /opt/ghc + # sudo rm -rf /opt/hostedtoolcache/CodeQL - uses: actions/checkout@v4 with: ref: main diff --git a/Dockerfile b/Dockerfile index 55a28b6..19a9fef 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,3 +1,8 @@ +FROM archlinux:base-devel AS build +RUN pacman -Syu --noconfirm \ + rust && \ + cargo install apkeep + FROM archlinux:base RUN pacman -Syu --noconfirm \ git \ @@ -9,4 +14,6 @@ RUN python -m venv /data/.venv && \ pip install --upgrade git+https://github.com/P1sec/hermes-dec ENV PATH=/data/.venv/bin:$PATH -CMD [ "ls -la && cd $GITHUB_WORKSPACE && ls -la" ] \ No newline at end of file +COPY --from=build /root/.cargo/bin/* /usr/local/bin/ +COPY setup.sh /data/setup.sh +CMD [ "/data/setup.sh" ] \ No newline at end of file diff --git a/script.sh b/script.sh index a756946..e0deba4 100755 --- a/script.sh +++ b/script.sh @@ -12,7 +12,7 @@ ProcessApp() mkdir -p $1 if [ -n "$2" ]; then echo "Downloading $1 Version $2" - apkeep -a $1@$2 -d apk-pure $1 $2 + apkeep -a $1@$2 -d apk-pure $1 Commit_message="$1 Version $2" else echo "Downloading $1" diff --git a/setup.sh b/setup.sh new file mode 100755 index 0000000..c386210 --- /dev/null +++ b/setup.sh @@ -0,0 +1,2 @@ +#!/bin/bash +cd $GITHUB_WORKSPACE && ./script.sh \ No newline at end of file