Skip to content

Commit

Permalink
Merge pull request #274 from dhanyn10/docker
Browse files Browse the repository at this point in the history
update, change db
  • Loading branch information
dhanyn10 committed Jun 8, 2024
2 parents 3f9dfba + e2edce8 commit 9db8a3a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,13 @@ on:
jobs:

build:
if: github.actor != 'dependabot[bot]'
environment: open_ecommerce
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: change env
sed -i "s/RAJAONGKIR_API_KEY=.*/RAJAONGKIR_API_KEY=${{ secrets.RAJAONGKIR_API_KEY }}/g" .env.docker
cat .env.docker
- name: set env
run: sed -i "s/RAJAONGKIR_API_KEY=.*/RAJAONGKIR_API_KEY=${{ secrets.RAJAONGKIR_API_KEY }}/g" .env.docker
- name: Run docker-compose
run: docker-compose up -d
- name: Sleep for 10s
Expand All @@ -24,4 +25,4 @@ jobs:
- name: database migration with docker
run: docker exec oe-web php artisan migrate
- name: database seed with docker
run: docker exec oe-web php artisan db:seed
run: docker exec oe-web php artisan db:seed
7 changes: 3 additions & 4 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,12 @@ services:
APP_KEY: base64:dUU/tjDaLvZv2ChevcXI87IBIoIK9DA4o/UGt5aAa3E=

db:
image: mariadb:10.11-jammy
container_name: oe-db
image: mysql
command: --default-authentication-plugin=mysql_native_password
restart: always
environment:
MYSQL_ROOT_PASSWORD: password
MYSQL_DATABASE: open_ecommerce
MARIADB_ROOT_PASSWORD: password
MARIADB_DATABASE: open_ecommerce

adminer:
container_name: oe-adminer
Expand Down

0 comments on commit 9db8a3a

Please sign in to comment.