mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-29 18:00:51 +01:00
ci: updated dockerfile
This commit is contained in:
12
.github/workflows/docker-crawlab.yml
vendored
12
.github/workflows/docker-crawlab.yml
vendored
@@ -304,23 +304,11 @@ jobs:
|
|||||||
CRAWLAB_MONGO_PORT: 27017
|
CRAWLAB_MONGO_PORT: 27017
|
||||||
ports:
|
ports:
|
||||||
- 8080:8080
|
- 8080:8080
|
||||||
options: >-
|
|
||||||
--health-cmd "curl -f http://localhost:8080/api/health || exit 1"
|
|
||||||
--health-interval 30s
|
|
||||||
--health-timeout 10s
|
|
||||||
--health-retries 5
|
|
||||||
worker:
|
worker:
|
||||||
image: ghcr.io/${{ github.repository_owner }}/crawlab:${{ needs.setup.outputs.version }}
|
image: ghcr.io/${{ github.repository_owner }}/crawlab:${{ needs.setup.outputs.version }}
|
||||||
env:
|
env:
|
||||||
CRAWLAB_NODE_MASTER: N
|
CRAWLAB_NODE_MASTER: N
|
||||||
CRAWLAB_MASTER_HOST: master
|
CRAWLAB_MASTER_HOST: master
|
||||||
ports:
|
|
||||||
- 8001:8000
|
|
||||||
options: >-
|
|
||||||
--health-cmd "curl -f http://localhost:8001/health || exit 1"
|
|
||||||
--health-interval 30s
|
|
||||||
--health-timeout 10s
|
|
||||||
--health-retries 5
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|||||||
@@ -26,3 +26,10 @@ COPY ./docker/bin/* /app/bin
|
|||||||
|
|
||||||
# start backend
|
# start backend
|
||||||
CMD ["/bin/bash", "/app/bin/docker-init.sh"]
|
CMD ["/bin/bash", "/app/bin/docker-init.sh"]
|
||||||
|
|
||||||
|
# frontend port
|
||||||
|
EXPOSE 8080
|
||||||
|
|
||||||
|
# healthcheck for backend
|
||||||
|
HEALTHCHECK --interval=1m --timeout=3s \
|
||||||
|
CMD curl -f http://localhost:8000/health || exit 1
|
||||||
BIN
docker/ghcr/.docker-compose.yml.swp
Normal file
BIN
docker/ghcr/.docker-compose.yml.swp
Normal file
Binary file not shown.
@@ -11,7 +11,7 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- mongo
|
- mongo
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "curl", "-f", "http://localhost:8000/health", "||", "exit", "1"]
|
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
|
||||||
interval: 30s
|
interval: 30s
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
retries: 5
|
retries: 5
|
||||||
@@ -25,7 +25,7 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- master
|
- master
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "curl", "-f", "http://localhost:8000/health", "||", "exit", "1"]
|
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
|
||||||
interval: 30s
|
interval: 30s
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
retries: 5
|
retries: 5
|
||||||
|
|||||||
Reference in New Issue
Block a user