Skip to content

Commit 097bd4d

Browse files
Remove postgresql13 from Ubuntu list of servicesDefine appveyor.yml before_build script for Ubuntu
1 parent f00121c commit 097bd4d

File tree

1 file changed

+37
-30
lines changed

1 file changed

+37
-30
lines changed

appveyor.yml

Lines changed: 37 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -29,43 +29,14 @@ matrix:
2929
fast_finish: true
3030

3131
for:
32-
-
32+
- # Visual Studio 2019
3333
matrix:
3434
only:
3535
- image: Visual Studio 2019
3636
services:
3737
- postgresql13
38-
- docker
3938
# REF: https://github.com/docascode/docfx-seed/blob/master/appveyor.yml
4039
before_build:
41-
- sh: |
42-
# Pull Azure Cosmos Emulator Docker image
43-
echo "Pulling Azure Cosmos Emulator Docker image for Linux ..."
44-
./pull-docker-azure-cosmos-emulator-linux.sh
45-
46-
# Start Azure Cosmos Emulator container
47-
echo "Running Azure Cosmos Emulator Docker container ..."
48-
nohup ./run-docker-azure-cosmos-emulator-linux.sh &
49-
50-
# Wait for Docker container being started in the background
51-
echo "Waiting 60 seconds before trying to download Azure Cosmos Emulator SSL certificate ..."
52-
sleep 60
53-
54-
# Print the background process output to see whether there are any errors
55-
if [ -f "./nohup.out" ]; then
56-
echo "--- BEGIN CONTENTS OF NOHUP.OUT ---"
57-
cat ./nohup.out
58-
echo "--- END CONTENTS OF NOHUP.OUT ---"
59-
fi
60-
61-
# Install SSL certificate to be able to access the emulator
62-
echo "Installing Azure Cosmos Emulator SSL certificate ..."
63-
sudo ./install-azure-cosmos-emulator-linux-certificates.sh
64-
- pwsh: |
65-
# Start Azure Cosmos Emulator on Windows
66-
if ($isWindows) {
67-
.\start-cosmos-db-emulator.ps1
68-
}
6940
- pwsh: |
7041
if (-Not $env:APPVEYOR_PULL_REQUEST_TITLE) {
7142
# https://dotnet.github.io/docfx/tutorial/docfx_getting_started.html
@@ -77,6 +48,11 @@ for:
7748
if ($lastexitcode -ne 0) {
7849
throw "docfx install failed with exit code $lastexitcode."
7950
}
51+
- pwsh: |
52+
# Start Azure Cosmos Emulator on Windows
53+
if ($isWindows) {
54+
.\start-cosmos-db-emulator.ps1
55+
}
8056
after_build:
8157
- pwsh: |
8258
CD ./docs
@@ -124,6 +100,37 @@ for:
124100
on:
125101
branch: /release\/.+/
126102
appveyor_repo_tag: true
103+
- # Ubuntu
104+
matrix:
105+
only:
106+
- image: Ubuntu
107+
services:
108+
- docker
109+
before_build:
110+
- sh: |
111+
# Start Azure Cosmos Emulator on Linux
112+
# Pull Azure Cosmos Emulator Docker image
113+
echo "Pulling Azure Cosmos Emulator Docker image for Linux ..."
114+
./pull-docker-azure-cosmos-emulator-linux.sh
115+
116+
# Start Azure Cosmos Emulator container
117+
echo "Running Azure Cosmos Emulator Docker container ..."
118+
nohup ./run-docker-azure-cosmos-emulator-linux.sh &
119+
120+
# Wait for Docker container being started in the background
121+
echo "Waiting 60 seconds before trying to download Azure Cosmos Emulator SSL certificate ..."
122+
sleep 60
123+
124+
# Print the background process output to see whether there are any errors
125+
if [ -f "./nohup.out" ]; then
126+
echo "--- BEGIN CONTENTS OF NOHUP.OUT ---"
127+
cat ./nohup.out
128+
echo "--- END CONTENTS OF NOHUP.OUT ---"
129+
fi
130+
131+
# Install SSL certificate to be able to access the emulator
132+
echo "Installing Azure Cosmos Emulator SSL certificate ..."
133+
sudo ./install-azure-cosmos-emulator-linux-certificates.sh
127134
128135
build_script:
129136
- pwsh: |

0 commit comments

Comments
 (0)