mirror of
https://github.com/frappe/frappe_docker.git
synced 2026-06-25 16:55:08 +00:00
Update Deploy_Traefik_and_MariaDB.yml
This commit is contained in:
parent
946afcd4d7
commit
4ebfd1cb57
1 changed files with 43 additions and 25 deletions
68
.github/workflows/Deploy_Traefik_and_MariaDB.yml
vendored
68
.github/workflows/Deploy_Traefik_and_MariaDB.yml
vendored
|
|
@ -10,35 +10,53 @@ jobs:
|
||||||
- label-1
|
- label-1
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: checkout Script content
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v2 # checkout the repository content
|
||||||
|
|
||||||
|
- name: setup python
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: '3.10' # install the python version needed
|
||||||
|
|
||||||
|
- name: install dependicese
|
||||||
|
run: |
|
||||||
|
python -m pip install --upgrade pip
|
||||||
|
pip install -r requirements.txt
|
||||||
|
pip install PyGithub
|
||||||
|
- name: fintechsys/docker_compose.py # run main.py
|
||||||
|
# env:
|
||||||
|
# SOME_SECRET: ${{ secrets.SOME_SECRET }}
|
||||||
|
run: python fintechsys/docker_compose.py
|
||||||
|
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
# - name: Set up Docker
|
# - name: Set up Docker
|
||||||
# uses: actions/setup-docker@v4
|
# uses: actions/setup-docker@v4
|
||||||
# with:
|
# with:
|
||||||
# dockerfile: Dockerfile # Path to your Dockerfile if you have one
|
# dockerfile: Dockerfile # Path to your Dockerfile if you have one
|
||||||
|
|
||||||
- name: Create directory
|
- name: Create directory
|
||||||
run: mkdir ~/gitops
|
run: mkdir ~/gitops
|
||||||
|
|
||||||
- name: Create traefik.env file
|
- name: Create traefik.env file
|
||||||
run: |
|
run: |
|
||||||
echo 'TRAEFIK_DOMAIN=${{secrets.TRAEFIK_DOMAIN}}' > ~/gitops/traefik.env
|
echo 'TRAEFIK_DOMAIN=${{secrets.TRAEFIK_DOMAIN}}' > ~/gitops/traefik.env
|
||||||
echo 'EMAIL=f.alfalahi@fintechsys.net' >> ~/gitops/traefik.env
|
echo 'EMAIL=f.alfalahi@fintechsys.net' >> ~/gitops/traefik.env
|
||||||
echo 'HASHED_PASSWORD='$(openssl passwd -apr1 ${{secrets.TRAEFIK_PASSWORD}} | sed 's/\$/\\\$/g') >> ~/gitops/traefik.env
|
echo 'HASHED_PASSWORD='$(openssl passwd -apr1 ${{secrets.TRAEFIK_PASSWORD}} | sed 's/\$/\\\$/g') >> ~/gitops/traefik.env
|
||||||
|
|
||||||
- name: Docker Compose up for Traefik
|
- name: Docker Compose up for Traefik
|
||||||
run: |
|
run: |
|
||||||
docker-compose --project-name traefik \ runs-on: self-hosted
|
docker-compose --project-name traefik \ runs-on: self-hosted
|
||||||
--env-file ~/gitops/traefik.env \
|
--env-file ~/gitops/traefik.env \
|
||||||
-f overrides/compose.traefik.yaml \
|
-f overrides/compose.traefik.yaml \
|
||||||
-f overrides/compose.traefik-ssl.yaml up -d
|
-f overrides/compose.traefik-ssl.yaml up -d
|
||||||
|
|
||||||
- name: Create mariadb.env file
|
- name: Create mariadb.env file
|
||||||
run: echo "DB_PASSWORD=${{secrets.MARIADB_PASSWORD}}" > ~/gitops/mariadb.env
|
run: echo "DB_PASSWORD=${{secrets.MARIADB_PASSWORD}}" > ~/gitops/mariadb.env
|
||||||
|
|
||||||
- name: Deploy MariaDB container
|
- name: Deploy MariaDB container
|
||||||
run: |
|
run: |
|
||||||
docker-compose --project-name mariadb \
|
docker-compose --project-name mariadb \
|
||||||
--env-file ~/gitops/mariadb.env \
|
--env-file ~/gitops/mariadb.env \
|
||||||
-f overrides/compose.mariadb-shared.yaml up -d
|
-f overrides/compose.mariadb-shared.yaml up -d
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue