Deploying the plugin via ZIP¶
Context¶
QGIS Isogeo plugin installation directory
C:\Users\%userprofile%\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\isogeo_search_engine
/home/%userprofile%/.local/share/QGIS/QGIS3/profiles/default/python/plugins/isogeo_search_engine
Many of the settings for using the Isogeo plugin are stored in the plugin's installation directory. This is particularly the case for :
- the
client_secrets.json
file used forauthentication (in the_auth
subfolder) - quicksearches and default searches written to a
quicksearches.json
file (in the_user
subfolder) - database connections configured in the
db_connections.json
file (in the_user
subfolder)
In addition, the QGIS extension manager allows you to install a plugin from a .zip
archive. In the case of an organization with a large number of Isogeo plugin end-users, it is therefore possible to save them from having to make certain settings themselves, which are common to all users.
Let's take the following example
A user X is responsible for distributing the QGIS Isogeo plugin to a dozen users belonging to his organization:
- the
client_secrets.json
authentication file is probably common to the entire organization - the data accessed by end users via the Isogeo plugin is stored in a single database to which all users have access
- some of this data is likely to be useful to all users
In this case, user X can :
- authenticate the plugin with the
client_secrets.json
common to the entire organization - configure the connection to the organization's database in the
db_connections.json
file - save quick searches encompassing metadata on data useful to all users
Once this has been done, user X can generate a .zip
file from the plugin's installation directory on his workstation and distribute it to the ten or so end-users, who will not have to authenticate themselves, configure the database connection or save certain quick searches.
How to proceed¶
-
Install the plugin and authenticate by entering the location of the
client_secrets.json
file supplied by the Isogeo team. The file is copied to the_auth
folder in the plugin installation directory on the user's workstation. -
On the same workstation, configure the:
- by saving quick searches
- by setting a default search
- by configuring database connections in the
_user/db_connections.json
file
-
On the same workstation, create a
.zip
archive from the plugin installation directory:This
.zip
archive contains theclient_secrets.json
,quicksearches.json
anddb_connections.json
files resulting from the first two steps. -
Distribute the
.zip
archive thus created to other users, who will be able to install the QGIS Isogeo plugin directly from theisogeo_search_engine.zip
file ("Install/Manage extensions" menu >"Install from ZIP" tab).For users who install the plugin in this way, authentication will be automatic (without having to go through the authentication form), as the
client_secrets.json
file will already be present in the_auth
folder of the Isogeo plugin.