-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitpod.yml
63 lines (58 loc) · 1.83 KB
/
.gitpod.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
image: gitpod/workspace-dotnet:latest
tasks:
- name: MySQL
init: docker pull mysql:5
command: |
if [ $(docker ps -a -q -f name=mysql-server) ]; then
echo "Starting existing MySQL container..."
docker start mysql-server
else
echo "Creating and starting a new MySQL container..."
docker run --name mysql-server -e MYSQL_ROOT_PASSWORD=password -p 3306:3306 \
--health-cmd='mysqladmin ping --silent' \
--health-interval=10s \
--health-timeout=5s \
--health-retries=5 \
mysql:5
fi
- name: API
before: cd backend/Discapp.API
init: |
dotnet tool install --global dotnet-ef
dotnet restore
command: |
while ! docker inspect --format='{{.State.Health.Status}}' mysql-server | grep -q healthy; do
echo "Waiting for MySQL to be healthy..."
sleep 3
done
export PATH="$PATH:/home/gitpod/.dotnet/tools"
dotnet ef database update
dotnet watch run
- name: Worker
before: cd backend/Discapp.Worker
init: dotnet restore
command: |
while ! docker inspect --format='{{.State.Health.Status}}' mysql-server | grep -q healthy; do
echo "Waiting for MySQL to be healthy..."
sleep 3
done
dotnet watch run
openMode: split-right
- name: Frontend
before: cd frontend
init: |
npm i -g @ionic/cli
npm ci
command: |
echo "VITE_VINYL_API_URL=$(gp url 5132)" > .env.local
echo "VITE_BETA_BANNER=\"Development mode inside Gitpod\"" >> .env.local
npm i -g @ionic/cli
ionic serve
openMode: tab-after
ports:
- name: App
port: 8100
visibility: public
- name: Scraper
port: 5132
visibility: public