Skip to content

Commit b25de2f

Browse files
committed
Update CI
1 parent 5a83813 commit b25de2f

File tree

5 files changed

+27
-18
lines changed

5 files changed

+27
-18
lines changed

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ jobs:
4141
- name: Download Artifact
4242
uses: actions/download-artifact@v4
4343
with:
44-
name: enstate-server
45-
path: packages/app/target/release
44+
name: enstate
45+
path: /target/release
4646

4747
- name: Build
4848
run: chmod +x ./target/release/enstate

.github/workflows/prebuild.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,5 +50,5 @@ jobs:
5050
uses: actions/upload-artifact@v4
5151
with:
5252
name: enstate-server
53-
path: packages/app/target/release/enstate
53+
path: target/release/enstate
5454
retention-days: 1

.github/workflows/test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,8 @@ jobs:
6969
- name: Download Artifact
7070
uses: actions/download-artifact@v4
7171
with:
72-
name: enstate-server
73-
path: packages/app/target/release
72+
name: enstate
73+
path: target/release
7474

7575
- name: Build
7676
run: chmod +x ./target/release/enstate

packages/app/compose.yaml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ services:
2626
depends_on:
2727
- prometheus
2828
ports:
29-
- 3000:3000
29+
- 9002:3000
3030
environment:
3131
PROMETHEUS_URL: http://prometheus:9090
3232
volumes:
@@ -37,6 +37,12 @@ services:
3737
sh -c "cp -r /etc/grafana/provisioning_temp/dashboards/. /etc/grafana/provisioning/dashboards &&
3838
find /etc/grafana/provisioning/dashboards/ -name '*.json' -exec sed -i 's/$${DS_PROMETHEUS}/Prometheus/g' {} \+ &&
3939
/run.sh"
40+
meilisearch:
41+
image: getmeili/meilisearch:latest
42+
ports:
43+
- 7700:7700
44+
environment:
45+
MEILISEARCH_NO_ANALYTICS: true
4046

4147
volumes:
4248
logs:

test/tests/server.spec.ts

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,27 @@ import { http_fetch } from '../src/http_fetch';
1111
import { test_implementation } from '../src/test_implementation';
1212

1313
const TEST_RELEASE = true;
14+
const SPAWN_SERVER = false;
1415

1516
let server: Subprocess | undefined;
1617

1718
beforeAll(async () => {
18-
server = Bun.spawn(['../packages/app/target/release/enstate'], {
19-
env: { ...process.env, RUST_LOG: 'info' },
20-
});
19+
if (SPAWN_SERVER) {
20+
server = Bun.spawn(['../packages/app/target/release/enstate'], {
21+
env: { ...process.env, RUST_LOG: 'info' },
22+
});
2123

22-
const decoder = new TextDecoder();
24+
const decoder = new TextDecoder();
2325

24-
// @ts-ignore
25-
server.stdout.pipeTo(
26-
new WritableStream({
27-
write(chunk) {
28-
console.log(decoder.decode(chunk));
29-
},
30-
})
31-
);
26+
// @ts-ignore
27+
server.stdout.pipeTo(
28+
new WritableStream({
29+
write(chunk) {
30+
console.log(decoder.decode(chunk));
31+
},
32+
})
33+
);
34+
}
3235

3336
console.log('Waiting for server to start...');
3437

0 commit comments

Comments
 (0)