File tree Expand file tree Collapse file tree 3 files changed +22
-12
lines changed Expand file tree Collapse file tree 3 files changed +22
-12
lines changed Original file line number Diff line number Diff line change @@ -66,28 +66,34 @@ function set_arch_os() {
66
66
armv7l)
67
67
current_arch=" armv7l"
68
68
oses=" ubuntu debian"
69
+ os_family=" linux"
69
70
;;
70
71
aarch64)
71
72
current_arch=" aarch64"
72
73
oses=" ubuntu debian"
74
+ os_family=" linux"
73
75
;;
74
76
ppc64el|ppc64le)
75
77
current_arch=" ppc64le"
76
78
oses=" ubuntu debian"
79
+ os_family=" linux"
77
80
;;
78
81
s390x)
79
82
current_arch=" s390x"
80
83
oses=" ubuntu debian"
84
+ os_family=" linux"
81
85
;;
82
86
amd64|x86_64)
83
87
case $( uname) in
84
88
MINGW64* |MSYS_NT* )
85
89
current_arch=" x86_64"
86
90
oses=" windows"
91
+ os_family=" windows"
87
92
;;
88
93
* )
89
94
current_arch=" x86_64"
90
95
oses=" ubuntu alpine debian"
96
+ os_family=" linux"
91
97
;;
92
98
esac
93
99
;;
Original file line number Diff line number Diff line change @@ -76,17 +76,11 @@ print_alpine_ver() {
76
76
EOI
77
77
}
78
78
79
- # Print the maintainer
80
- print_maint () {
81
- cat >> $1 << -EOI
82
- LABEL org.opencontainers.image.authors="[email protected] "
83
- EOI
84
- }
85
-
86
79
# Print the locale and language
87
80
print_lang_locale () {
88
81
cat >> $1 << -EOI
89
82
ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8'
83
+
90
84
EOI
91
85
}
92
86
@@ -159,6 +153,7 @@ print_env() {
159
153
cat >> $1 << -EOI
160
154
161
155
ENV JAVA_VERSION ${jver}
156
+
162
157
EOI
163
158
}
164
159
403
398
print_cmd () {
404
399
# for version > 8, set CMD["jshell"] in the Dockerfile
405
400
above_8=" ^(9|[1-9][0-9]+)$"
406
- if [[ " ${version} " =~ ${above_8} ]]; then
401
+ if [[ " ${version} " =~ ${above_8} && " ${package} " == " jdk " ]]; then
407
402
cat >> $1 << -EOI
408
403
CMD ["jshell"]
409
404
EOI
@@ -425,7 +420,6 @@ generate_dockerfile() {
425
420
echo -n " Writing ${file} ... "
426
421
print_legal ${file} ;
427
422
print_${os} _ver ${file} ${bld} ${btype} ;
428
- print_maint ${file} ;
429
423
print_lang_locale ${file} ;
430
424
print_${os} _pkg ${file} ;
431
425
print_env ${file} ${bld} ${btype} ;
Original file line number Diff line number Diff line change @@ -31,10 +31,20 @@ function print_annotate_cmd() {
31
31
32
32
# The manifest tool expects "amd64" as arch and not "x86_64"
33
33
march=$( echo ${arch_tag} | awk -F' :' ' { print $2 }' | awk -F' -' ' { print $1 }' )
34
- if [ ${march} == " x86_64" ]; then
34
+ case ${march} in
35
+ x86_64)
35
36
march=" amd64"
36
- fi
37
- echo " \" ${manifest_tool} \" manifest annotate ${main_tag} ${arch_tag} --os ${os} --arch ${march} " >> ${man_file}
37
+ ;;
38
+ aarch64)
39
+ march=" arm64"
40
+ ;;
41
+ armv7l)
42
+ march=" arm"
43
+ ;;
44
+ * )
45
+ ;;
46
+ esac
47
+ echo " \" ${manifest_tool} \" manifest annotate ${main_tag} ${arch_tag} --os ${os_family} --arch ${march} " >> ${man_file}
38
48
}
39
49
40
50
# Space separated list of tags
You can’t perform that action at this time.
0 commit comments