Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
osmaxx
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ifs
geometalab
osmaxx
Commits
fa25ca6e
Commit
fa25ca6e
authored
3 years ago
by
Nicola Jordan
Browse files
Options
Downloads
Patches
Plain Diff
added gdal docker build
parent
cdc8d234
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
docker-helper-images/gdal-docker/README.md
+52
-0
52 additions, 0 deletions
docker-helper-images/gdal-docker/README.md
docker-helper-images/gdal-docker/build_geometa_gdal.sh
+14
-4
14 additions, 4 deletions
docker-helper-images/gdal-docker/build_geometa_gdal.sh
with
66 additions
and
4 deletions
docker-helper-images/gdal-docker/README.md
0 → 100644
+
52
−
0
View file @
fa25ca6e
The version downloaded apparently doesn't yield the correct version when using releases, therefore
a change in
`gdal/docker/ubuntu-full/bh-gdal.sh`
might be needed:
```
bash
# ...
# comment out
# wget -q "https://github.com/${GDAL_REPOSITORY}/archive/${GDAL_VERSION}.tar.gz" \
# -O - | tar xz -C gdal --strip-components=1
# removes the "v"
GDAL_V
=
${
GDAL_VERSION
#?
}
wget
-q
"https://github.com/
${
GDAL_REPOSITORY
}
/releases/download/v
${
GDAL_V
}
/gdal-
${
GDAL_V
}
.tar.gz"
\
-O
- |
tar
xz
-C
gdal
--strip-components
=
1
# ...
```
**and replace**
in
`ubunutu-full/Dockerfile`
:
```
dockerfile
ARG
WITH_FILEGDB=
```
with
```
dockerfile
ARG
WITH_FILEGDB=1
```
**if issues with libjxl, checkout specific version**
:
ie. ->
`&& git checkout v0.6.1`
```
dockerfile
# Build libjxl
RUN
.
/buildscripts/bh-set-envvars.sh
\
&&
git clone https://github.com/libjxl/libjxl.git
\
&&
cd
libjxl
\
&&
git checkout v0.6.1
\
&&
git submodule update
--init
--recursive
\
&&
mkdir
build
\
&&
cd
build
\
&&
cmake
-DCMAKE_INSTALL_PREFIX
=
/usr
-DCMAKE_BUILD_TYPE
=
Release
-DBUILD_TESTING
=
OFF ..
\
&&
make
-j
$(
nproc
)
\
&&
make
-j
$(
nproc
)
install
\
&&
make
install
DESTDIR
=
"/build_thirdparty"
\
&&
cd
../..
\
&&
rm
-rf
libjxl
```
\ No newline at end of file
This diff is collapsed.
Click to expand it.
docker-helper-images/gdal-docker/build_geometa_gdal.sh
+
14
−
4
View file @
fa25ca6e
...
@@ -6,12 +6,18 @@ set -e
...
@@ -6,12 +6,18 @@ set -e
GDAL_VERSION
=
"3.4.1"
GDAL_VERSION
=
"3.4.1"
PROJ_VERSION
=
"8.2.1"
PROJ_VERSION
=
"8.2.1"
echo
"if this script fails, please clone the right version of GDAL sources"
echo
"ie."
# if not cloned already, clone it:
# if not cloned already, clone it:
git clone git@github.com:OSGeo/gdal.git gdal
||
true
echo
"git clone git@github.com:OSGeo/gdal.git gdal"
echo
"cd gdal"
echo
"git pull"
echo
"git checkout v
${
GDAL_VERSION
}
"
echo
echo
"then try again"
echo
cd
gdal/docker
cd
gdal/gdal/docker
git pull
# python:3 -> 08.2021 = bullseye (debian)
# python:3 -> 08.2021 = bullseye (debian)
WITH_PDFIUM
=
1
WITH_FILEGDB
=
1
BASE_IMAGE
=
"ubuntu:20.04"
TARGET_BASE_IMAGE
=
"ubuntu:20.04"
TARGET_IMAGE
=
"geometalab/gdal:full"
ubuntu-full/build.sh
--release
--gdal
v
${
GDAL_VERSION
}
--proj
${
PROJ_VERSION
}
WITH_PDFIUM
=
1
WITH_FILEGDB
=
1
BASE_IMAGE
=
"ubuntu:20.04"
TARGET_BASE_IMAGE
=
"ubuntu:20.04"
TARGET_IMAGE
=
"geometalab/gdal:full"
ubuntu-full/build.sh
--release
--gdal
v
${
GDAL_VERSION
}
--proj
${
PROJ_VERSION
}
...
@@ -22,3 +28,7 @@ WITH_PDFIUM=1 WITH_FILEGDB=1 BASE_IMAGE="ubuntu:20.04" TARGET_BASE_IMAGE="ubuntu
...
@@ -22,3 +28,7 @@ WITH_PDFIUM=1 WITH_FILEGDB=1 BASE_IMAGE="ubuntu:20.04" TARGET_BASE_IMAGE="ubuntu
docker push
"geometalab/gdal:full-v
${
GDAL_VERSION
}
"
docker push
"geometalab/gdal:full-v
${
GDAL_VERSION
}
"
docker run
--rm
-it
"geometalab/gdal:full-v
${
GDAL_VERSION
}
"
ogrinfo
--formats
|
grep
-i
gdb
docker run
--rm
-it
"geometalab/gdal:full-v
${
GDAL_VERSION
}
"
ogrinfo
--formats
|
grep
-i
gdb
echo
"image built"
echo
"geometalab/gdal:full-v
${
GDAL_VERSION
}
"
echo
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment