File tree 8 files changed +63
-86
lines changed
8 files changed +63
-86
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+
3
+ name : CI
4
+ on :
5
+ push :
6
+ branches :
7
+ - master
8
+ pull_request : {}
9
+
10
+ jobs :
11
+ lint :
12
+ name : Lint
13
+ runs-on : ubuntu-latest
14
+ steps :
15
+ - name : Checkout the source code
16
+ uses : actions/checkout@v2
17
+
18
+ - name : Run the custom linter
19
+ run : ./lint.sh
20
+
21
+ build :
22
+ name : Build images
23
+ runs-on : ubuntu-latest
24
+ needs : [lint]
25
+
26
+ # Use the same job to build all Linux-based images
27
+ strategy :
28
+ matrix :
29
+ image :
30
+ - linux
31
+ - linux-micro
32
+
33
+ steps :
34
+ - name : Checkout the source code
35
+ uses : actions/checkout@v2
36
+
37
+ - name : Build the Docker image
38
+ run : docker build -t ghcr.io/${{ github.repository }}/${{ matrix.image }}:latest ${{ matrix.image }}/
39
+
40
+ - name : Authenticate with GitHub Container Registry
41
+ uses : docker/login-action@v1
42
+ with :
43
+ registry : ghcr.io
44
+ username : ${{ github.repository_owner }}
45
+ password : ${{ secrets.GITHUB_TOKEN }}
46
+ if : github.event_name == 'push' && github.ref == 'refs/heads/master'
47
+
48
+ - name : Upload the Docker image to GitHub Container Registry
49
+ run : docker push ghcr.io/${{ github.repository }}/${{ matrix.image }}:latest
50
+ if : github.event_name == 'push' && github.ref == 'refs/heads/master'
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -3,11 +3,19 @@ set -euo pipefail
3
3
IFS=$' \n\t '
4
4
export LC_ALL=C
5
5
6
+ PACKAGES_FILES=(
7
+ linux/packages.txt
8
+ linux-micro/packages.txt
9
+ )
10
+
6
11
# Ensure packages lists are sorted
7
- for file in packages; do
8
- cat " ${file} .txt" | sort -u > " /tmp/sorted-${file} .txt"
9
- if ! diff -u " /tmp/sorted-${file} .txt" " ${file} .txt" ; then
10
- echo " Lint error: ${file} .txt is not sorted"
12
+ for file in ${PACKAGES_FILES[@]} ; do
13
+ # Replace / with - in the file path to avoid creating subdirs.
14
+ sorted_file=" /tmp/sorted-${file/ \/ / -} "
15
+
16
+ cat " ${file} " | sort -u > " ${sorted_file} "
17
+ if ! diff -u " ${sorted_file} " " ${file} " ; then
18
+ echo " Lint error: ${file} is not sorted"
11
19
exit 1
12
20
fi
13
21
done
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
1
# escape=`
2
-
3
- ARG BASE_IMAGE_VER=:1803
4
-
5
- FROM mcr.microsoft.com/windows/servercore${BASE_IMAGE_VER}
2
+ FROM mcr.microsoft.com/windows/servercore:ltsc2019
6
3
7
4
# Install the Visual C++ Build tools
8
5
#
Load Diff This file was deleted.
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments