mirror of
https://github.com/ItzCrazyKns/Perplexica.git
synced 2025-09-17 23:01:32 +00:00
Compare commits
8 Commits
feat/remov
...
bfb01be34c
Author | SHA1 | Date | |
---|---|---|---|
|
bfb01be34c | ||
|
74f7eaed6e | ||
|
dddd944a18 | ||
|
7eccd4d75b | ||
|
04a0342b52 | ||
|
590a52d38c | ||
|
ca3fad6632 | ||
|
e0d5787c5d |
109
.github/workflows/docker-build.yaml
vendored
109
.github/workflows/docker-build.yaml
vendored
@@ -8,15 +8,12 @@ on:
|
|||||||
types: [published]
|
types: [published]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-push:
|
build-amd64:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Set up QEMU
|
|
||||||
uses: docker/setup-qemu-action@v2
|
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v2
|
uses: docker/setup-buildx-action@v2
|
||||||
with:
|
with:
|
||||||
@@ -33,28 +30,104 @@ jobs:
|
|||||||
id: version
|
id: version
|
||||||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
|
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Build and push Docker image
|
- name: Build and push AMD64 Docker image
|
||||||
if: github.ref == 'refs/heads/master' && github.event_name == 'push'
|
if: github.ref == 'refs/heads/master' && github.event_name == 'push'
|
||||||
run: |
|
run: |
|
||||||
docker buildx create --use
|
DOCKERFILE=app.dockerfile
|
||||||
DOCKERFILE=app.dockerfile; \
|
IMAGE_NAME=perplexica
|
||||||
IMAGE_NAME=perplexica; \
|
docker buildx build --platform linux/amd64 \
|
||||||
docker buildx build --platform linux/amd64,linux/arm64 \
|
--cache-from=type=registry,ref=itzcrazykns1337/${IMAGE_NAME}:amd64 \
|
||||||
--cache-from=type=registry,ref=itzcrazykns1337/${IMAGE_NAME}:main \
|
|
||||||
--cache-to=type=inline \
|
--cache-to=type=inline \
|
||||||
|
--provenance false \
|
||||||
-f $DOCKERFILE \
|
-f $DOCKERFILE \
|
||||||
-t itzcrazykns1337/${IMAGE_NAME}:main \
|
-t itzcrazykns1337/${IMAGE_NAME}:amd64 \
|
||||||
--push .
|
--push .
|
||||||
|
|
||||||
- name: Build and push release Docker image
|
- name: Build and push AMD64 release Docker image
|
||||||
if: github.event_name == 'release'
|
if: github.event_name == 'release'
|
||||||
run: |
|
run: |
|
||||||
docker buildx create --use
|
DOCKERFILE=app.dockerfile
|
||||||
DOCKERFILE=app.dockerfile; \
|
IMAGE_NAME=perplexica
|
||||||
IMAGE_NAME=perplexica; \
|
docker buildx build --platform linux/amd64 \
|
||||||
docker buildx build --platform linux/amd64,linux/arm64 \
|
--cache-from=type=registry,ref=itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }}-amd64 \
|
||||||
--cache-from=type=registry,ref=itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }} \
|
|
||||||
--cache-to=type=inline \
|
--cache-to=type=inline \
|
||||||
|
--provenance false \
|
||||||
-f $DOCKERFILE \
|
-f $DOCKERFILE \
|
||||||
-t itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }} \
|
-t itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }}-amd64 \
|
||||||
--push .
|
--push .
|
||||||
|
|
||||||
|
build-arm64:
|
||||||
|
runs-on: ubuntu-24.04-arm
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v2
|
||||||
|
with:
|
||||||
|
install: true
|
||||||
|
|
||||||
|
- name: Log in to DockerHub
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
|
||||||
|
- name: Extract version from release tag
|
||||||
|
if: github.event_name == 'release'
|
||||||
|
id: version
|
||||||
|
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
|
||||||
|
|
||||||
|
- name: Build and push ARM64 Docker image
|
||||||
|
if: github.ref == 'refs/heads/master' && github.event_name == 'push'
|
||||||
|
run: |
|
||||||
|
DOCKERFILE=app.dockerfile
|
||||||
|
IMAGE_NAME=perplexica
|
||||||
|
docker buildx build --platform linux/arm64 \
|
||||||
|
--cache-from=type=registry,ref=itzcrazykns1337/${IMAGE_NAME}:arm64 \
|
||||||
|
--cache-to=type=inline \
|
||||||
|
--provenance false \
|
||||||
|
-f $DOCKERFILE \
|
||||||
|
-t itzcrazykns1337/${IMAGE_NAME}:arm64 \
|
||||||
|
--push .
|
||||||
|
|
||||||
|
- name: Build and push ARM64 release Docker image
|
||||||
|
if: github.event_name == 'release'
|
||||||
|
run: |
|
||||||
|
DOCKERFILE=app.dockerfile
|
||||||
|
IMAGE_NAME=perplexica
|
||||||
|
docker buildx build --platform linux/arm64 \
|
||||||
|
--cache-from=type=registry,ref=itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }}-arm64 \
|
||||||
|
--cache-to=type=inline \
|
||||||
|
--provenance false \
|
||||||
|
-f $DOCKERFILE \
|
||||||
|
-t itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }}-arm64 \
|
||||||
|
--push .
|
||||||
|
|
||||||
|
manifest:
|
||||||
|
needs: [build-amd64, build-arm64]
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Log in to DockerHub
|
||||||
|
uses: docker/login-action@v2
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
|
||||||
|
- name: Create and push multi-arch manifest for main
|
||||||
|
if: github.ref == 'refs/heads/master' && github.event_name == 'push'
|
||||||
|
run: |
|
||||||
|
IMAGE_NAME=perplexica
|
||||||
|
docker manifest create itzcrazykns1337/${IMAGE_NAME}:main \
|
||||||
|
--amend itzcrazykns1337/${IMAGE_NAME}:amd64 \
|
||||||
|
--amend itzcrazykns1337/${IMAGE_NAME}:arm64
|
||||||
|
docker manifest push itzcrazykns1337/${IMAGE_NAME}:main
|
||||||
|
|
||||||
|
- name: Create and push multi-arch manifest for releases
|
||||||
|
if: github.event_name == 'release'
|
||||||
|
run: |
|
||||||
|
IMAGE_NAME=perplexica
|
||||||
|
docker manifest create itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }} \
|
||||||
|
--amend itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }}-amd64 \
|
||||||
|
--amend itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }}-arm64
|
||||||
|
docker manifest push itzcrazykns1337/${IMAGE_NAME}:${{ env.RELEASE_VERSION }}
|
||||||
|
@@ -26,9 +26,21 @@ services:
|
|||||||
- ./config.toml:/home/perplexica/config.toml
|
- ./config.toml:/home/perplexica/config.toml
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|
||||||
|
redict:
|
||||||
|
image: registry.redict.io/redict:latest
|
||||||
|
container_name: perplexica-redict
|
||||||
|
ports:
|
||||||
|
- "6379:6379"
|
||||||
|
volumes:
|
||||||
|
- redict_data:/data
|
||||||
|
networks:
|
||||||
|
- perplexica-network
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
perplexica-network:
|
perplexica-network:
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
backend-dbstore:
|
backend-dbstore:
|
||||||
uploads:
|
uploads:
|
||||||
|
redict_data:
|
@@ -12,6 +12,11 @@ search:
|
|||||||
server:
|
server:
|
||||||
secret_key: 'a2fb23f1b02e6ee83875b09826990de0f6bd908b6638e8c10277d415f6ab852b' # Is overwritten by ${SEARXNG_SECRET}
|
secret_key: 'a2fb23f1b02e6ee83875b09826990de0f6bd908b6638e8c10277d415f6ab852b' # Is overwritten by ${SEARXNG_SECRET}
|
||||||
|
|
||||||
|
redis:
|
||||||
|
url: redis://redict:6379/0
|
||||||
|
|
||||||
engines:
|
engines:
|
||||||
- name: wolframalpha
|
- name: wolframalpha
|
||||||
disabled: false
|
disabled: false
|
||||||
|
- name: qwant
|
||||||
|
disabled: true
|
||||||
|
Reference in New Issue
Block a user