Skip to content

Commit

Permalink
fix build failure related to disk usage (#1372)
Browse files Browse the repository at this point in the history
  • Loading branch information
wind57 authored Jun 21, 2023
1 parent 065a3cb commit f6e15ae
Show file tree
Hide file tree
Showing 45 changed files with 99 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/composites/clean-space/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: clean space
description: clean space
runs:
using: "composite"
steps:
- name: apt-update
shell: bash
run: |
sudo apt-get update
- name: Free Disk Space
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true
android: true
dotnet: true
haskell: true
large-packages: true
swap-storage: true
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ runs:
cd ..
docker load -i /tmp/docker/images/spring-cloud-kubernetes-fabric8-istio-it.tar
rm -fr /tmp/docker/images/spring-cloud-kubernetes-fabric8-istio-it.tar
cd spring-cloud-kubernetes-integration-tests/spring-cloud-kubernetes-fabric8-istio-it/
../.././mvnw clean install -Dskip.build.image=true
cd ../..
6 changes: 6 additions & 0 deletions .github/workflows/maven.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ jobs:
- name: checkout project
uses: actions/checkout@v2

- name: clean space
uses: ./.github/workflows/composites/clean-space

- name: set env variables
uses: ./.github/workflows/composites/env-variables

Expand Down Expand Up @@ -111,6 +114,9 @@ jobs:
- name: checkout project
uses: actions/checkout@v2

- name: clean space
uses: ./.github/workflows/composites/clean-space

- name: set env variables
uses: ./.github/workflows/composites/env-variables

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import io.kubernetes.client.openapi.models.V1Deployment;
import io.kubernetes.client.openapi.models.V1Ingress;
import io.kubernetes.client.openapi.models.V1Service;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.BeforeEach;
Expand Down Expand Up @@ -66,6 +67,11 @@ static void beforeAll() throws Exception {
util.setUp(NAMESPACE);
}

@AfterAll
static void afterAll() {
Commons.systemPrune();
}

@BeforeEach
void beforeEach() {
util.busybox(NAMESPACE, Phase.CREATE);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
import io.kubernetes.client.openapi.models.V1EnvVarBuilder;
import io.kubernetes.client.openapi.models.V1Ingress;
import io.kubernetes.client.openapi.models.V1Service;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeAll;
Expand Down Expand Up @@ -74,6 +75,11 @@ static void beforeAll() throws Exception {
util.setUp(NAMESPACE_DEFAULT);
}

@AfterAll
static void afterAll() {
Commons.systemPrune();
}

@BeforeEach
void beforeEach() {
util.createNamespace(NAMESPACE_A);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ static void setup() throws Exception {
@AfterAll
static void afterAll() throws Exception {
Commons.cleanUp(K8S_CONFIG_CLIENT_IT_SERVICE_NAME, K3S);
Commons.systemPrune();
}

@AfterEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ static void afterAll() throws Exception {
Commons.cleanUp(SPRING_CLOUD_K8S_CONFIG_WATCHER_APP_NAME, K3S);
Commons.cleanUp(CONFIG_WATCHER_APP_A_IMAGE, K3S);
Commons.cleanUp(CONFIG_WATCHER_APP_B_IMAGE, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ static void afterAll() throws Exception {
util.deleteNamespace("left");
util.deleteNamespace("right");
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ static void beforeAll() throws Exception {
static void afterAll() throws Exception {
util.deleteNamespace(LEFT_NAMESPACE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ static void beforeAll() throws Exception {
static void after() throws Exception {
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ static void beforeAll() throws Exception {
static void after() throws Exception {
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ static void beforeAll() throws Exception {
static void afterAll() throws Exception {
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ static void afterAll() throws Exception {
util.deleteNamespace(NAMESPACE_A);
util.deleteNamespace(NAMESPACE_B);
manifests(Phase.DELETE);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void afterAll() throws Exception {
Commons.cleanUp(SPRING_CLOUD_K8S_LOADBALANCER_APP_NAME, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void afterAll() throws Exception {
Commons.cleanUp(SPRING_CLOUD_K8S_REACTIVE_DISCOVERY_APP_NAME, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ static void afterAll() throws Exception {
Commons.cleanUp(SPRING_CLOUD_K8S_CONFIG_WATCHER_APP_NAME, K3S);
Commons.cleanUp(CONFIG_WATCHER_APP_A_IMAGE, K3S);
Commons.cleanUp(CONFIG_WATCHER_APP_B_IMAGE, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void afterAll() throws Exception {
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ static void setup() throws Exception {
@AfterAll
static void afterAll() throws Exception {
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void afterAll() throws Exception {
Commons.cleanUp(SPRING_CLOUD_K8S_CONFIG_WATCHER_APP_NAME, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ static void beforeAll() throws Exception {
static void afterAll() throws Exception {
Commons.cleanUp(SPRING_CLOUD_K8S_CONFIG_WATCHER_APP_NAME, K3S);
Commons.cleanUp(CONFIG_WATCHER_IT_IMAGE, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ static void afterAll() throws Exception {
util.deleteNamespace(LEFT_NAMESPACE);
util.deleteNamespace(RIGHT_NAMESPACE);
Commons.cleanUp(SPRING_CLOUD_K8S_CONFIG_WATCHER_APP_NAME, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ static void beforeAll() throws Exception {
static void afterAll() throws Exception {
Commons.cleanUp(SPRING_CLOUD_K8S_CONFIG_WATCHER_APP_NAME, K3S);
Commons.cleanUp(CONFIG_WATCHER_IT_IMAGE, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void afterAll() {
coreK8sClientIt(Phase.DELETE);
Commons.systemPrune();
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ static void afterAll() throws Exception {
discoveryServer(Phase.DELETE);
util.deleteNamespace(NAMESPACE_LEFT);
util.deleteNamespace(NAMESPACE_RIGHT);
Commons.systemPrune();
}

@AfterEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ static void afterAll() throws Exception {

discoveryServer(Phase.DELETE);
discoveryIt(Phase.DELETE);
Commons.systemPrune();
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
import io.fabric8.kubernetes.api.model.apps.Deployment;
import io.fabric8.kubernetes.api.model.networking.v1.Ingress;
import io.fabric8.kubernetes.client.KubernetesClient;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.BeforeEach;
Expand Down Expand Up @@ -73,6 +74,11 @@ static void beforeAll() throws Exception {
util.setUp(NAMESPACE);
}

@AfterAll
static void afterAll() {
Commons.systemPrune();
}

@BeforeEach
void beforeEach() {
util.busybox(NAMESPACE, Phase.CREATE);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ void beforeEach() {
static void afterAll() {
util.deleteNamespace(NAMESPACE_A);
util.deleteNamespace(NAMESPACE_B);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ static void afterAll() throws Exception {
util.deleteNamespace("left");
util.deleteNamespace("right");
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ static void beforeAll() throws Exception {
static void afterAll() throws Exception {
util.deleteNamespace(LEFT_NAMESPACE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ static void beforeAll() throws Exception {
static void after() throws Exception {
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ static void beforeAll() throws Exception {
static void after() throws Exception {
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ static void beforeAll() throws Exception {
static void after() throws Exception {
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ static void beforeAll() throws Exception {
static void afterAll() throws Exception {
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ static void after() throws Exception {
util.wiremock(NAMESPACE, "/wiremock", Phase.DELETE);
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void after() throws Exception {
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ static void beforeAll() throws Exception {
util.setUp(NAMESPACE);
}

@AfterAll
static void afterAll() {
Commons.systemPrune();
}

@BeforeEach
void beforeEach() {
util.createNamespace(NAMESPACE_A_UAT);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ static void after() throws Exception {
util.wiremock(NAMESPACE, "/wiremock", Phase.DELETE);
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ static void after() throws Exception {
util.deleteNamespace(NAMESPACE_LEFT);
util.deleteNamespace(NAMESPACE_RIGHT);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ static void after() throws Exception {
util.busybox(NAMESPACE, Phase.DELETE);
manifests(Phase.DELETE);
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void afterAll() throws Exception {
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

@BeforeEach
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void after() throws Exception {
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ static void beforeAll() throws Exception {
@AfterAll
static void after() throws Exception {
Commons.cleanUp(IMAGE_NAME, K3S);
Commons.systemPrune();
}

@Test
Expand Down
Loading

0 comments on commit f6e15ae

Please sign in to comment.