setup mysql

This commit is contained in:
c9s 2022-05-03 16:23:10 +08:00
parent c869bac166
commit 9b5ba3780c
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54

View File

@ -15,8 +15,13 @@ jobs:
matrix: matrix:
redis-version: redis-version:
- 6.2 - 6.2
env:
DB_DATABASE: bbgo
DB_USER: root
DB_PASSWORD: root
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/cache@v2 - uses: actions/cache@v2
@ -28,7 +33,12 @@ jobs:
restore-keys: | restore-keys: |
${{ runner.os }}-go- ${{ runner.os }}-go-
- name: Setup redis - name: Set up MySQL
run: |
sudo /etc/init.d/mysql start
mysql -e 'CREATE DATABASE ${{ env.DB_DATABASE }};' -u${{ env.DB_USER }} -p${{ env.DB_PASSWORD }}
- name: Set up redis
uses: shogo82148/actions-setup-redis@v1 uses: shogo82148/actions-setup-redis@v1
with: with:
redis-version: ${{ matrix.redis-version }} redis-version: ${{ matrix.redis-version }}