Skip to content

Commit

Permalink
[INLONG-10048][Tools] Remove more useless paths to release more size …
Browse files Browse the repository at this point in the history
…for workflows
  • Loading branch information
dockerzhang committed Apr 23, 2024
1 parent 3abb856 commit 9b92250
Showing 1 changed file with 15 additions and 17 deletions.
32 changes: 15 additions & 17 deletions .github/workflows/codeql_analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,18 @@ jobs:
- name: Checkout
uses: actions/checkout@v3

# Release space
- name: Remove unnecessary packages
run: |
echo "=== Before pruning ==="
df -h
sudo rm -rf /usr/share/dotnet
sudo rm -rf /usr/local/lib/android
sudo rm -rf /opt/ghc
sudo rm -rf /opt/hostedtoolcache
echo "=== After pruning ==="
df -h
# Set up jdk
- name: Set up JDK
uses: actions/setup-java@v3
Expand All @@ -55,32 +67,18 @@ jobs:
uses: actions/cache@v3
with:
path: |
~/.m2/repository
~/.m2/repository/*/*/*
!~/.m2/repository/org/apache/inlong
!~/.m2/repository/com/github/eirslett
key: ${{ runner.os }}-inlong-codesql-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-inlong-codesql

- name: Set up swapfile path
run: |
sudo sysctl -w vm.max_map_count=262144
sudo sysctl -w fs.file-max=65536
sudo fallocate -l 5G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
# Release space
- name: Remove unnecessary packages
run: |
echo "=== Before pruning ==="
df -h
sudo rm -rf /usr/share/dotnet
sudo rm -rf /usr/local/lib/android
sudo rm -rf /opt/ghc
echo
echo "=== After pruning ==="
df -h
- name: Build with Maven
run: |
mvn --batch-mode --update-snapshots -e -V clean install -DskipTests -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.httpconnectionManager.ttlSeconds=120 -Daether.connector.http.reuseConnections=false -Daether.connector.requestTimeout=60000
Expand Down

0 comments on commit 9b92250

Please sign in to comment.