fix(ci): provide proper ipfs process
This commit is contained in:
parent
95a51fd152
commit
c98e53a984
6
.github/workflows/publish-dist.yml
vendored
6
.github/workflows/publish-dist.yml
vendored
@ -155,10 +155,10 @@ jobs:
|
|||||||
- name: Sanity check docker image
|
- name: Sanity check docker image
|
||||||
run: |
|
run: |
|
||||||
echo "Check ipfs-hash"
|
echo "Check ipfs-hash"
|
||||||
docker run --rm --entrypoint /bin/sh ghcr.io/vegaprotocol/frontend/${{ matrix.app }}:local -c 'cat /ipfs-hash'
|
docker run --rm ghcr.io/vegaprotocol/frontend/${{ matrix.app }}:local /bin/sh -c 'cat /ipfs-hash'
|
||||||
docker run --rm --entrypoint /bin/sh ghcr.io/vegaprotocol/frontend/${{ matrix.app }}:local -c 'cat /ipfs-hash' > ${{ matrix.app }}-ipfs-hash
|
docker run --rm ghcr.io/vegaprotocol/frontend/${{ matrix.app }}:local /bin/sh -c 'cat /ipfs-hash' > ${{ matrix.app }}-ipfs-hash
|
||||||
echo "List html directory"
|
echo "List html directory"
|
||||||
docker run --rm --entrypoint /bin/sh ghcr.io/vegaprotocol/frontend/${{ matrix.app }}:local -c 'apk add --update tree; tree /usr/share/nginx/html'
|
docker run --rm ghcr.io/vegaprotocol/frontend/${{ matrix.app }}:local /bin/sh -c 'apk add --update tree; tree /usr/share/nginx/html'
|
||||||
|
|
||||||
- name: Publish dist as docker image (ghcr)
|
- name: Publish dist as docker image (ghcr)
|
||||||
uses: docker/build-push-action@v3
|
uses: docker/build-push-action@v3
|
||||||
|
@ -118,7 +118,7 @@ On top of that there are two possible scenarios for running docker image - using
|
|||||||
to run ipfs on port 3000:
|
to run ipfs on port 3000:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker run -p 3000:80 [TAG] ipfs
|
docker run -p 3000:80 [TAG] /run-ipfs.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
to run nginx on port 3000:
|
to run nginx on port 3000:
|
||||||
|
@ -20,8 +20,7 @@ RUN sh docker/docker-build.sh
|
|||||||
FROM --platform=amd64 nginx:1.23-alpine@sha256:6318314189b40e73145a48060bff4783a116c34cc7241532d0d94198fb2c9629
|
FROM --platform=amd64 nginx:1.23-alpine@sha256:6318314189b40e73145a48060bff4783a116c34cc7241532d0d94198fb2c9629
|
||||||
# configuration of system
|
# configuration of system
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
COPY docker/entrypoint.sh /entrypoint.sh
|
COPY docker/run-ipfs.sh /run-ipfs.sh
|
||||||
ENTRYPOINT [ "/entrypoint.sh" ]
|
|
||||||
# Copy dist
|
# Copy dist
|
||||||
COPY docker/nginx.conf /etc/nginx/conf.d/default.conf
|
COPY docker/nginx.conf /etc/nginx/conf.d/default.conf
|
||||||
RUN rm -rf /usr/share/nginx/html/*
|
RUN rm -rf /usr/share/nginx/html/*
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
FROM --platform=amd64 nginx:1.23-alpine@sha256:6318314189b40e73145a48060bff4783a116c34cc7241532d0d94198fb2c9629
|
FROM --platform=amd64 nginx:1.23-alpine@sha256:6318314189b40e73145a48060bff4783a116c34cc7241532d0d94198fb2c9629
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
COPY docker/entrypoint.sh /entrypoint.sh
|
COPY docker/run-ipfs.sh /run-ipfs.sh
|
||||||
ENTRYPOINT [ "/entrypoint.sh" ]
|
|
||||||
COPY docker/nginx.conf /etc/nginx/conf.d/default.conf
|
COPY docker/nginx.conf /etc/nginx/conf.d/default.conf
|
||||||
RUN rm -rf /usr/share/nginx/html/*
|
RUN rm -rf /usr/share/nginx/html/*
|
||||||
COPY ./dist-result/ /usr/share/nginx/html/
|
COPY ./dist-result/ /usr/share/nginx/html/
|
||||||
|
4
docker/run-ipfs.sh
Executable file
4
docker/run-ipfs.sh
Executable file
@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
ipfs config profile apply server
|
||||||
|
ipfs config --json Addresses.Gateway '"/ip4/127.0.0.1/tcp/80"'
|
||||||
|
ipfs daemon
|
Loading…
Reference in New Issue
Block a user