Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
geosphere-mapserver
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
cspp_geo
geosphere
geosphere-mapserver
Commits
0d53482a
Commit
0d53482a
authored
5 years ago
by
David Hoese
Browse files
Options
Downloads
Patches
Plain Diff
Change tile generation to default to /data directory for output
parent
eb98aa4d
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
tile_gen/README.md
+1
-5
1 addition, 5 deletions
tile_gen/README.md
tile_gen/run.sh
+11
-5
11 additions, 5 deletions
tile_gen/run.sh
with
12 additions
and
10 deletions
tile_gen/README.md
+
1
−
5
View file @
0d53482a
...
...
@@ -10,9 +10,5 @@ docker push gitlab.ssec.wisc.edu:5555/cspp_geo/cspp-geo-web-viewer/tile_gen:late
## Usage
```
bash
docker run
-
p
8888:80
-d
gitlab.ssec.wisc.edu:5555/cspp_geo/cspp-geo-web-viewer/
mapserver
:latest
docker run
-
d
---rm
--network
cspp-geo-rabbit
--cpus
2
--name
cspp-geo-tilegen-g16-radf
-e
AMQPFIND_TOPIC
=
"data.goes.g16.abi.radf.l1b.geotiff.complete"
-v
cspp-geo-abi-l1b-geotiffs:/data
gitlab.ssec.wisc.edu:5555/cspp_geo/cspp-geo-web-viewer/
tile_gen
:latest
```
Then the main mapserv CGI script can be accessed with:
http://localhost:8888/cgi-bin/mapserv
This diff is collapsed.
Click to expand it.
tile_gen/run.sh
+
11
−
5
View file @
0d53482a
...
...
@@ -15,9 +15,6 @@
# Verify that the data mount is available
test
-d
"/data"
# Change to /data volume to write our output
test
-d
"/dst"
export
AMQPFIND_ARGS
=
${
AMQPFIND_ARGS
:-
"-H cspp-geo-rabbit -X satellite -u guest -p guest"
}
export
AMQPSEND_ARGS
=
${
AMQPSEND_ARGS
:-
"-H cspp-geo-rabbit -X satellite -u guest -p guest"
}
export
AMQPFIND_TOPIC
=
${
AMQPFIND_TOPIC
:-
'data.goes.*.abi.*.l1b.geotiff.complete'
}
...
...
@@ -26,7 +23,7 @@ export TILE_ARGS=${TILE_ARGS:-""}
export
TMPDIR
=
${
TMPDIR
:-
"/dst/tmp"
}
run_tile_gen
()
{
if
[
$#
-ne
5
]
;
then
if
[
[
$#
-ne
5
]
]
;
then
echo
"Unexpected number of arguments (expected 5): $#"
return
1
fi
...
...
@@ -40,15 +37,24 @@ run_tile_gen() {
# convert path from a relative path to an absolute path
path
=
"/data/
${
path
}
"
# if /dst isn't defined then use /data
if
[[
-d
"/dst"
]]
;
then
dst_dir
=
"/dst"
else
dst_dir
=
"/data"
fi
# update shapefile in a temporary directory
# and resample geotiff if necessary
# FUTURE: TileDB will be updated in-place
# generate_tiles.py will make a temporary directory
out_dir
=
"
/
dst/tiles/
${
satellite_family
}
/
${
satellite_id
}
/
${
instrument
}
"
out_dir
=
"
${
dst
_dir
}
/tiles/
${
satellite_family
}
/
${
satellite_id
}
/
${
instrument
}
"
mkdir
-p
${
out_dir
}
python3 generate_tiles.py
${
TILE_ARGS
}
-p
${
G2G_PRODUCTS
}
--
${
out_dir
}
${
path
}
# OUT/<product>/<product>.shp
glob_pattern
=
"
${
out_dir
}
/*/*.shp"
# Remove the /data prefix
glob_pattern
=
"
${
glob_pattern
/
${
dst_dir
}
\//
}
"
amqpsend_topic
=
"data.
${
satellite_family
}
.
${
satellite_id
}
.
${
instrument
}
.
${
data_type
}
.l1b.tiledb.complete"
json_info
=
"{path:
${
glob_pattern
}
, satellite_family:
${
satellite_family
}
, satellite_ID:
${
satellite_id
}
, instrument:
${
instrument
}
, data_type:
${
data_type
}
}"
...
...
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