[Oskari-user] Oskarin tuotantopalvelimen asennus

Mäkinen Sami (MML) sami.makinen at maanmittauslaitos.fi
Wed Jan 16 06:09:17 PST 2019


Hi,

Lets use english on the mailing list. The question was if the Jetty-zip downloadable from Oskari.org is usable in production as is. You can mostly use the packaging of zip file in production, but I heavily recommend creating a server extension for building a customized app: http://oskari.org/documentation/backend/setup-server-extension This will makes upgrading easier. When you compile the extension it provides oskari-map.war and transport.war that you can just copy to the Jetty/webapps replacing the default ones.

With the recent versions of Oskari it's encouraged to make a similar extension for the frontend. Here's an example of a custom frontend: https://github.com/nls-oskari/pti-frontend The documentation is a bit lacking for this, but the interesting part is that your own custom code is in your own repository and you just include the bits from Oskari-frontend that you need by referencing them in the applications minifierAppsetup,json with "oskari-frontend" prefix like here: https://github.com/nls-oskari/pti-frontend/blob/master/applications/paikkatietoikkuna.fi/full-map/minifierAppSetup.json#L17. The "magic" that makes this work is having Oskari-frontend repository cloned next to your own repository when building the frontend (https://github.com/nls-oskari/pti-frontend/blob/master/package.json#L10) and it's all explained on the README.md: https://github.com/nls-oskari/pti-frontend/blob/master/README.md That being said you can skip the minifierAppsetup.json part for new apps and just starting using this kind of main.js https://github.com/kartat-tampere/tampere-frontend/blob/master/apps/geoportal/main.js which uses imports to bring code in to your app. Actually running the build with minifierAppsetup.json creates a main.js that you can start using instead of the JSON-file.

Most of our systems use nginx in front of Jetty (here's an example config: https://github.com/oskariorg/sample-configs/tree/master/nginx  ). Note that you can just configure the TLS-certificate on nginx and pass the http-requests to Jetty to separate the concerns. We have environments running the Oskari-server, transport and included geoserver on a single Jetty and environments where all of these have their own Jetty instance. Both work so it's up to you if you want to split the webapps on multiple Jettys or not. Having them on the same Jetty means that they all go down if you need to restart the service, but having them on multiple Jettys means a bit more work and you need something like nginx to forward the requests to different instances.

So to summarize:

-          create a server-extension for custom server code (even if you don't have custom code having a customized default view is good enough reason to do this)

-          consider creating a frontend-extension (if you need any customization)

-          consider if you want to have clients directly connect to Jetty or having nginx/apache httpd or similar in between.

-          setup TLS (https)

-          If you use the included GeoServer change the credentials and/or block access to it from the internet

-          Change the credentials for default users in Oskari

I guess that's mostly it.

BR,
       Sami

Lähettäjä: Oskari-user [mailto:oskari-user-bounces at lists.osgeo.org] Puolesta Jere Grönman (TAU)
Lähetetty: 15. tammikuuta 2019 15:47
Vastaanottaja: Oskari-user at lists.osgeo.org
Aihe: [Oskari-user] Oskarin tuotantopalvelimen asennus

Hei

Meillä on käynnissä Tampreen yliopistossa peltodata-hanke, jossa olemme testauksessa käyttäneet Oskari-alustaa. Nyt saimme uutta palvelinrautaa ja ajateltiin tehdä Oskarista oikea tuotantoversio.

Mikä olisi paras tapa tehdä virallinen Oskari-tuotantoversio? Onko jetty-zipin käyttö riittävää vai pitääkö ladata githubista eri komponentit?

Terveisin Jere Grönman
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/oskari-user/attachments/20190116/1ee511c2/attachment.html>


More information about the Oskari-user mailing list