Skip to content

Commit 9cf6398

Browse files
committed
Build cuttlefish-cloud-orchestrator during presubmit
1 parent b1ee467 commit 9cf6398

2 files changed

Lines changed: 25 additions & 50 deletions

File tree

.github/workflows/artifacts_arm64.yaml

Lines changed: 0 additions & 32 deletions
This file was deleted.

.github/workflows/presubmit.yaml

Lines changed: 25 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -61,29 +61,39 @@ jobs:
6161
name: cuttlefish-cvdremote-arm64
6262
path: cuttlefish-cvdremote_*.deb
6363

64-
build-cuttlefish-cloud-orchestrator-x86_64-docker-image:
64+
build-cuttlefish-cloud-orchestrator-amd64-docker-image:
6565
runs-on: ubuntu-24.04
6666
steps:
6767
- name: Checkout repository
6868
uses: actions/checkout@a81bbbf8298c0fa03ea29cdc473d45769f953675 # aka v2
69-
- name: Get docker image filename and tag
70-
run: |
71-
short_sha=$(echo ${{ github.sha }} | cut -c1-8)
72-
echo "image_path=cloud-orchestrator-docker-image-x86_64-${short_sha}.tar" >> $GITHUB_ENV
73-
echo "image_tag=cuttlefish-cloud-orchestrator:${short_sha}" >> $GITHUB_ENV
7469
- name: Build docker image
75-
run: docker build --force-rm --no-cache -t ${{ env.image_tag }} .
70+
run: docker build -t cuttlefish-cloud-orchestrator .
71+
- name: Save docker image
72+
run: docker save --output cuttlefish-cloud-orchestrator.tar cuttlefish-cloud-orchestrator
73+
- name: Publish docker image
74+
uses: actions/upload-artifact@c7d193f32edcb7bfad88892161225aeda64e9392 # aka v4.0.0
75+
with:
76+
name: cuttlefish-cloud-orchestrator-amd64
77+
path: cuttlefish-cloud-orchestrator.tar
78+
79+
build-cuttlefish-cloud-orchestrator-arm64-docker-image:
80+
runs-on: ubuntu-24.04-arm
81+
steps:
82+
- name: Checkout repository
83+
uses: actions/checkout@a81bbbf8298c0fa03ea29cdc473d45769f953675 # aka v2
84+
- name: Build docker image
85+
run: docker build -t cuttlefish-cloud-orchestrator .
7686
- name: Save docker image
77-
run: docker save --output ${{ env.image_path }} ${{ env.image_tag }}
87+
run: docker save --output cuttlefish-cloud-orchestrator.tar cuttlefish-cloud-orchestrator
7888
- name: Publish docker image
7989
uses: actions/upload-artifact@c7d193f32edcb7bfad88892161225aeda64e9392 # aka v4.0.0
8090
with:
81-
name: docker-image-x86_64
82-
path: ${{ env.image_path }}
91+
name: cuttlefish-cloud-orchestrator-arm64
92+
path: cuttlefish-cloud-orchestrator.tar
8393

8494
e2e-test-cvdr-with-on-premise-cloud-orchestrator:
8595
runs-on: ubuntu-24.04
86-
needs: [build-cuttlefish-cloud-orchestrator-x86_64-docker-image, build-cuttlefish-cvdremote-amd64-debian-package]
96+
needs: [build-cuttlefish-cloud-orchestrator-amd64-docker-image, build-cuttlefish-cvdremote-amd64-debian-package]
8797
steps:
8898
- name: Checkout repository
8999
uses: actions/checkout@a81bbbf8298c0fa03ea29cdc473d45769f953675 # aka v2
@@ -95,20 +105,17 @@ jobs:
95105
- name: Download cuttlefish-cloud-orchestrator
96106
uses: actions/download-artifact@7a1cd3216ca9260cd8022db641d960b1db4d1be4 # aka v4.0.0
97107
with:
98-
name: docker-image-x86_64
99-
path: cuttlefish-cloud-orchestrator
108+
name: cuttlefish-cloud-orchestrator-amd64
100109
- name: Load and run cuttlefish-cloud-orchestrator
101110
run: |
102-
short_sha=$(echo ${{ github.sha }} | cut -c1-8)
103-
docker load --input cuttlefish-cloud-orchestrator/cloud-orchestrator-docker-image-x86_64-${short_sha}.tar
104-
docker run -d -p 8080:8080 -e CONFIG_FILE="/conf.toml" -v $PWD/scripts/on-premises/single-server/conf.toml:/conf.toml -v /var/run/docker.sock:/var/run/docker.sock -t cuttlefish-cloud-orchestrator:${short_sha}
111+
docker load --input cuttlefish-cloud-orchestrator.tar
112+
docker run -d -p 8080:8080 -e CONFIG_FILE="/conf.toml" -v $PWD/scripts/on-premises/single-server/conf.toml:/conf.toml -v /var/run/docker.sock:/var/run/docker.sock -t cuttlefish-cloud-orchestrator
105113
- name: Download cuttlefish-cvdremote
106114
uses: actions/download-artifact@7a1cd3216ca9260cd8022db641d960b1db4d1be4 # aka v4.0.0
107115
with:
108116
name: cuttlefish-cvdremote-amd64
109-
path: cuttlefish-cvdremote
110117
- name: Install cuttlefish-cvdremote
111-
run: sudo apt-get install -y ./cuttlefish-cvdremote/cuttlefish-cvdremote_*_*64.deb
118+
run: sudo apt-get install -y ./cuttlefish-cvdremote_*.deb
112119
- name: Install bazel
113120
run: |
114121
sudo apt-get update && sudo apt-get install -y apt-transport-https curl gnupg

0 commit comments

Comments
 (0)