Skip to content

Commit ffc5532

Browse files
authored
Merge pull request #133 from DefangLabs/lio-warnings
fix compose warnings
2 parents 9ba76a4 + 78b9bdd commit ffc5532

File tree

22 files changed

+35
-10
lines changed

22 files changed

+35
-10
lines changed

.github/workflows/check-sample.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
jobs:
99
check_samples:
1010
runs-on: ubuntu-latest
11-
permissions:
11+
permissions:
1212
contents: write
1313
pull-requests: write
1414
steps:
@@ -26,20 +26,25 @@ jobs:
2626
echo "@@ MODIFIED @@"
2727
cat modified.txt
2828
29+
- name: Validate Compose Files with Defang CLI
30+
run: |
31+
. <(curl -Ls https://s.defang.io/install)
32+
cat modified.txt | xargs -n1 defang compose config -C > /dev/null
33+
2934
- name: Add checklist to PR description
3035
uses: actions/github-script@v5
3136
with:
3237
script: |
3338
const fs = require('fs');
3439
const pr_number = context.issue.number;
3540
const marker = '## Samples Checklist';
36-
41+
3742
// Read the checklist from the file
3843
let checklist = fs.readFileSync('checklist.txt', 'utf8').trim();
3944
let error = false;
4045
4146
if(!checklist) {
42-
checklist = "✅"
47+
checklist = "✅ All good!"
4348
}
4449
else {
4550
error = true;

samples/bullmq-bullboard-redis/compose.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
board:
3+
restart: unless-stopped
34
build:
45
context: ./board
56
dockerfile: Dockerfile
@@ -15,6 +16,7 @@ services:
1516
- redis
1617

1718
api:
19+
restart: unless-stopped
1820
build:
1921
context: ./api
2022
dockerfile: Dockerfile
@@ -29,6 +31,7 @@ services:
2931
- redis
3032

3133
worker:
34+
restart: unless-stopped
3235
deploy:
3336
replicas: 2
3437
build:

samples/django-postgres/compose.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
db:
3+
restart: unless-stopped
34
image: postgres:14
45
volumes: ["./tmp/postgres:/var/lib/postgresql/data/"]
56
environment:
@@ -18,9 +19,9 @@ services:
1819
interval: 1m30s
1920
timeout: 30s
2021
retries: 5
21-
start_period: 30s
2222
django-crm:
23-
build: .
23+
restart: unless-stopped
24+
build: ./app
2425
ports:
2526
- mode: ingress
2627
target: 8000

samples/django/compose.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
django:
3+
restart: unless-stopped
34
build:
45
context: ./app
56
dockerfile: Dockerfile

samples/fastapi-postgres/compose.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
fastapi:
3+
restart: unless-stopped
34
build:
45
context: ./fastapi
56
dockerfile: Dockerfile

samples/golang-slackbot/compose.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
bot:
3+
restart: unless-stopped
34
build:
45
context: ./app
56
dockerfile: Dockerfile

samples/hasura/compose.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
hasura:
3+
restart: unless-stopped
34
build:
45
dockerfile: Dockerfile
56
context: ./hasura

samples/huginn/compose.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ services:
1616
interval: 1m30s
1717
timeout: 30s
1818
retries: 10
19-
start_period: 30s
2019
environment:
2120
- DATABASE_ADAPTER=postgresql
2221
- DATABASE_NAME

samples/metabase/compose.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
metabase:
3+
restart: unless-stopped
34
image: "metabase/metabase:latest"
45
ports:
56
- mode: ingress

samples/nextjs-blog/compose.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
blogstarter:
3+
restart: unless-stopped
34
build:
45
context: ./app
56
dockerfile: Dockerfile

0 commit comments

Comments
 (0)