mirror of
https://github.com/joaovitoriasilva/endurain.git
synced 2026-01-07 23:13:57 -05:00
Fixed docker-compose example file
This commit is contained in:
2
.github/FUNDING.yml
vendored
2
.github/FUNDING.yml
vendored
@@ -1,7 +1,7 @@
|
||||
# These are supported funding model platforms
|
||||
|
||||
github: joaovitoriasilva # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
|
||||
patreon: 84745218 # Replace with a single Patreon username
|
||||
#patreon: # Replace with a single Patreon username
|
||||
#open_collective: # Replace with a single Open Collective username
|
||||
#ko_fi: # Replace with a single Ko-fi username
|
||||
#tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
|
||||
|
||||
@@ -1,34 +1,3 @@
|
||||
# name: Create backend Docker image with latest tag on manual trigger
|
||||
|
||||
# on:
|
||||
# workflow_dispatch:
|
||||
|
||||
# jobs:
|
||||
|
||||
# build:
|
||||
|
||||
# runs-on: ubuntu-latest
|
||||
|
||||
# steps:
|
||||
# - name: Checkout code
|
||||
# uses: actions/checkout@v3
|
||||
|
||||
# - name: Build the backend Docker image
|
||||
# run: |
|
||||
# ls -al
|
||||
# IMAGE_TAG="latest"
|
||||
# docker build . --file Dockerfile_backend --tag ${{ github.repository }}/backend:$IMAGE_TAG
|
||||
# echo "IMAGE_TAG=${IMAGE_TAG}" >> $GITHUB_ENV
|
||||
# if: github.event_name == 'release' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
# - name: Push the backend Docker image to GHCR
|
||||
# if: success() && (github.event_name == 'release' || github.event_name == 'workflow_dispatch')
|
||||
# run: |
|
||||
# echo ${{ secrets.TOKEN_FOR_ACTIONS }} | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin
|
||||
# IMAGE_NAME="ghcr.io/${{ github.repository }}/backend"
|
||||
# docker tag ${{ github.repository }}/backend:$IMAGE_TAG $IMAGE_NAME:$IMAGE_TAG
|
||||
# docker push $IMAGE_NAME:$IMAGE_TAG
|
||||
|
||||
name: Create backend Docker image with latest tag on manual trigger
|
||||
|
||||
on:
|
||||
|
||||
@@ -1,41 +1,3 @@
|
||||
# name: Create backend Docker image on new release or using manual trigger
|
||||
|
||||
# on:
|
||||
# workflow_dispatch:
|
||||
# release:
|
||||
# types:
|
||||
# - created
|
||||
|
||||
# jobs:
|
||||
|
||||
# build:
|
||||
|
||||
# runs-on: ubuntu-latest
|
||||
|
||||
# steps:
|
||||
# - name: Checkout code
|
||||
# uses: actions/checkout@v3
|
||||
|
||||
# - name: Build the backend Docker image
|
||||
# run: |
|
||||
# ls -al
|
||||
# if [ "${{ github.event_name }}" == 'workflow_dispatch' ]; then
|
||||
# IMAGE_TAG="dev_$(date +"%d%m%Y")"
|
||||
# else
|
||||
# IMAGE_TAG="${{ github.event.release.tag_name }}"
|
||||
# fi
|
||||
# docker build . --file Dockerfile_backend --tag ${{ github.repository }}/backend:$IMAGE_TAG
|
||||
# echo "IMAGE_TAG=${IMAGE_TAG}" >> $GITHUB_ENV
|
||||
# if: github.event_name == 'release' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
# - name: Push the backend Docker image to GHCR
|
||||
# if: success() && (github.event_name == 'release' || github.event_name == 'workflow_dispatch')
|
||||
# run: |
|
||||
# echo ${{ secrets.TOKEN_FOR_ACTIONS }} | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin
|
||||
# IMAGE_NAME="ghcr.io/${{ github.repository }}/backend"
|
||||
# docker tag ${{ github.repository }}/backend:$IMAGE_TAG $IMAGE_NAME:$IMAGE_TAG
|
||||
# docker push $IMAGE_NAME:$IMAGE_TAG
|
||||
|
||||
name: Create backend Docker image on new release or using manual trigger
|
||||
|
||||
on:
|
||||
@@ -66,6 +28,13 @@ jobs:
|
||||
run: |
|
||||
docker buildx create --use
|
||||
|
||||
- name: Verify app directory exists
|
||||
run: |
|
||||
if [ ! -d "./app" ]; then
|
||||
echo "Directory 'app' does not exist."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
- name: Build and push the backend Docker image
|
||||
run: |
|
||||
if [ "${{ github.event_name }}" == 'workflow_dispatch' ]; then
|
||||
|
||||
@@ -1,32 +1,3 @@
|
||||
# name: Create frontend Docker image with latest tag on manual trigger
|
||||
|
||||
# on:
|
||||
# workflow_dispatch:
|
||||
|
||||
# jobs:
|
||||
|
||||
# build:
|
||||
|
||||
# runs-on: ubuntu-latest
|
||||
|
||||
# steps:
|
||||
# - name: Checkout code
|
||||
# uses: actions/checkout@v3
|
||||
|
||||
# - name: Build the frontend Docker image
|
||||
# run: |
|
||||
# IMAGE_TAG="latest"
|
||||
# docker build . --file Dockerfile_frontend --tag ${{ github.repository }}/frontend:$IMAGE_TAG
|
||||
# echo "IMAGE_TAG=${IMAGE_TAG}" >> $GITHUB_ENV
|
||||
# if: github.event_name == 'release' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
# - name: Push the frontend Docker image to GHCR
|
||||
# if: success() && (github.event_name == 'release' || github.event_name == 'workflow_dispatch')
|
||||
# run: |
|
||||
# echo ${{ secrets.TOKEN_FOR_ACTIONS }} | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin
|
||||
# IMAGE_NAME="ghcr.io/${{ github.repository }}/frontend"
|
||||
# docker tag ${{ github.repository }}/frontend:$IMAGE_TAG $IMAGE_NAME:$IMAGE_TAG
|
||||
# docker push $IMAGE_NAME:$IMAGE_TAG
|
||||
name: Create frontend Docker image with latest tag on manual trigger
|
||||
|
||||
on:
|
||||
|
||||
@@ -1,39 +1,3 @@
|
||||
# name: Create frontend Docker image on new release or using manual trigger
|
||||
|
||||
# on:
|
||||
# workflow_dispatch:
|
||||
# release:
|
||||
# types:
|
||||
# - created
|
||||
|
||||
# jobs:
|
||||
|
||||
# build:
|
||||
|
||||
# runs-on: ubuntu-latest
|
||||
|
||||
# steps:
|
||||
# - name: Checkout code
|
||||
# uses: actions/checkout@v3
|
||||
|
||||
# - name: Build the frontend Docker image
|
||||
# run: |
|
||||
# if [ "${{ github.event_name }}" == 'workflow_dispatch' ]; then
|
||||
# IMAGE_TAG="dev_$(date +"%d%m%Y")"
|
||||
# else
|
||||
# IMAGE_TAG="${{ github.event.release.tag_name }}"
|
||||
# fi
|
||||
# docker build . --file Dockerfile_frontend --tag ${{ github.repository }}/frontend:$IMAGE_TAG
|
||||
# echo "IMAGE_TAG=${IMAGE_TAG}" >> $GITHUB_ENV
|
||||
# if: github.event_name == 'release' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
# - name: Push the frontend Docker image to GHCR
|
||||
# if: success() && (github.event_name == 'release' || github.event_name == 'workflow_dispatch')
|
||||
# run: |
|
||||
# echo ${{ secrets.TOKEN_FOR_ACTIONS }} | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin
|
||||
# IMAGE_NAME="ghcr.io/${{ github.repository }}/frontend"
|
||||
# docker tag ${{ github.repository }}/frontend:$IMAGE_TAG $IMAGE_NAME:$IMAGE_TAG
|
||||
# docker push $IMAGE_NAME:$IMAGE_TAG
|
||||
name: Create frontend Docker image on new release or using manual trigger
|
||||
|
||||
on:
|
||||
|
||||
@@ -1,12 +1,11 @@
|
||||
version: '3'
|
||||
services:
|
||||
# frontend logic
|
||||
frontend:
|
||||
container_name: frontend
|
||||
image: ghcr.io/joaovitoriasilva/endurain/frontend:latest
|
||||
#environment:
|
||||
#- MY_APP_BACKEND_PROTOCOL=http # http or https, default is http
|
||||
#- MY_APP_BACKEND_HOST=localhost:98 # api host or local ip (example: 192.168.1.10:98), default is localhost:98
|
||||
#- VITE_BACKEND_PROTOCOL=http # http or https, default is http
|
||||
#- VITE_BACKEND_HOST=localhost:98 # api host or local ip (example: 192.168.1.10:98), default is localhost:98
|
||||
# Configure volume if you want to edit the code locally by clomming the repo
|
||||
#volumes:
|
||||
# - <local_path>/endurain/frontend:/app
|
||||
@@ -30,9 +29,9 @@ services:
|
||||
- FRONTEND_PORT=8080 # default is 80
|
||||
ports:
|
||||
- "98:80" # API port, change per your needs
|
||||
# Configure volume if you want to edit the code locally by clomming the repo
|
||||
#volumes:
|
||||
# - <local_path>/endurain/backend:/app
|
||||
volumes:
|
||||
# - <local_path>/endurain/backend:/app # Configure volume if you want to edit the code locally by cloning the repo and comment next line
|
||||
- <local_path>/endurain/backend/user_images:/app/user_images # necessary for user image persistence on container image updates
|
||||
depends_on:
|
||||
- mariadb
|
||||
- jaeger # optional
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
for i in $(env | grep MY_APP_)
|
||||
for i in $(env | grep VITE_)
|
||||
do
|
||||
key=$(echo $i | cut -d '=' -f 1)
|
||||
value=$(echo $i | cut -d '=' -f 2-)
|
||||
|
||||
Reference in New Issue
Block a user