-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathfirst_post_copy.html
213 lines (200 loc) · 11.7 KB
/
first_post_copy.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
<!DOCTYPE html>
<html lang="en-US">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="author" content="Luca Moiana" />
<meta name="copyright" content="Luca Moiana" />
<meta name="description" content="I’ve always followed QuantumGIS (recently QGIS) but only after the last release, 2.0 Dufour, I decided to use it as my main GIS software, at home. I even participated to a QGIS workshop at GFOSS DAY 2013, and I was really impressed by QGIS easy web-mapping capabilities, through ...
" />
<meta name="twitter:creator" content="@lucamoiana">
<meta property="og:type" content="article" />
<meta name="twitter:card" content="summary">
<meta name="keywords" content=", Test, " />
<meta property="og:title" content="first_post_copy "/>
<meta property="og:url" content="/first_post_copy.html" />
<meta property="og:description" content="I’ve always followed QuantumGIS (recently QGIS) but only after the last release, 2.0 Dufour, I decided to use it as my main GIS software, at home. I even participated to a QGIS workshop at GFOSS DAY 2013, and I was really impressed by QGIS easy web-mapping capabilities, through ..." />
<meta property="og:site_name" content="need GIS?" />
<meta property="og:article:author" content="Luca Moiana" />
<meta property="og:article:published_time" content="2014-12-13T18:32:00+01:00" />
<meta name="twitter:title" content="first_post_copy ">
<meta name="twitter:description" content="I’ve always followed QuantumGIS (recently QGIS) but only after the last release, 2.0 Dufour, I decided to use it as my main GIS software, at home. I even participated to a QGIS workshop at GFOSS DAY 2013, and I was really impressed by QGIS easy web-mapping capabilities, through ...">
<title>first_post_copy · need GIS? - Luca Moiana
</title>
<link href="//netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/css/bootstrap-combined.min.css" rel="stylesheet">
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.1/css/font-awesome.css" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="/theme/css/pygments.css" media="screen">
<link rel="stylesheet" type="text/css" href="/theme/tipuesearch/tipuesearch.css" media="screen">
<link rel="stylesheet" type="text/css" href="/theme/css/elegant.css" media="screen">
<link rel="stylesheet" type="text/css" href="/theme/css/custom.css" media="screen">
</head>
<body>
<nav class="navbar navbar-inverse navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="/">need GIS?</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav navbar-right">
<li ><a href="">Home</a></li>
<li ><a href="/categories.html">Categories</a></li>
<li ><a href="/tags.html">Tags</a></li>
<li ><a href="/archives.html">Archives</a></li>
</ul>
</div><!--/.nav-collapse -->
</div>
</nav>
<div class="container-fluid">
<div class="row-fluid">
<div class="span1"></div>
<div class="span10">
<article>
<div class="row-fluid">
<header class="page-header span10 offset2">
<h1><a href="/first_post_copy.html"> first_post_copy </a></h1>
</header>
</div>
<div class="row-fluid">
<div class="span8 offset2 article-content">
<p>I’ve always followed QuantumGIS (recently QGIS) but only after the last release, 2.0 Dufour, I decided to use it as my main GIS software, at home.</p>
<p>I even participated to a QGIS workshop at GFOSS DAY 2013, and I was really impressed by QGIS easy web-mapping capabilities, through Lizmap plugin.</p>
<p>While recently many web-mapping services, such as ArcGIS online, CartoDB or Mapbox, are giving everyone the web-map experience, I wanted to go hardcore and put up my own web server. In order to do that without spendig lots of money, I found out about AWS free options, but I recently I got a 0.41 cent billin.</p>
<p>So, First thing first, you wanna start running a ec2 micro instance on AWS.</p>
<p>Go to the web-site and follow instruction.
Select the “Free tier only” flag on the left pane.
Then select Ubuntu 12.04, I was only able to have this thing running so I accept any review to the article for a better understanding.
On “Step 5: Tag Instance” For the instance tag, I simply selected “GeoServerTest”
On “Step 6: “Configure Security Group” Just be sure to add SSH, HTTP and HTTPS to the protocol options and leaving the parameters untouched, they come andy to log into the remote server and do cool stuff…
When presented create a new security key and save it to a folder, I choose to save the .pem file into Documentsec2 for the name, I didn’t get creative and used “GeoServerTest”
Finally, cross your fingers and press launch Instance</p>
<p>[REFERENCE]</p>
<p>At this point you should be able to view your instance running…then what??
Now we need to ssh into the instance and install some GIS software.
In order to ssh from the terminale, you want to highlight the instance in AWS control panel and copy “Public DNS”, something that looks like this:</p>
<p>ec2-54-xxx-xx-xx.eu-west-1.compute.amazonaws.com</p>
<p>Now that you now where to ssh, don’t wait and open the terminal!
navigate to the folder with .pem file</p>
<blockquote>
cd Dcuments\ec2</blockquote>
<p>before using .pem file you need to change file permission using this command</p>
<blockquote>
chmod -R 700 GeoServerTest.pem</blockquote>
<p>[REFERENCE]</p>
<p>Now you can finally ssh into your instance typing:</p>
<blockquote>
ssh -i Geoserver5.pem <a class="reference external" href="mailto:ubuntu@ec2-54-194-39-18.eu-west-1.compute.amazonaws.com">ubuntu@ec2-54-194-39-18.eu-west-1.compute.amazonaws.com</a></blockquote>
<p>and then you wanna make sure everything is up to date typing:</p>
<blockquote>
sudo apt-get update</blockquote>
<p>Then you need all the pretty little thing that make run on a server, so go ahead and type:</p>
<blockquote>
apt-get install apache2 php5 curl php5-curl php5-sqlite php5-gd</blockquote>
<p>It’s now time for the first test, go to your browser and enter your instance address:</p>
<blockquote>
ec2-54-XXX-XX-XX.eu-west-1.compute.amazonaws.com</blockquote>
<p>The answer should be pretty straightforward:
It works!</p>
<p>To install the sweet GIS pieces, you need to add a repository, with this line:</p>
<blockquote>
sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable</blockquote>
<p>After that you can update:</p>
<blockquote>
sudo apt-get update</blockquote>
<p>And install qgis on the server:</p>
<blockquote>
sudo apt-get install qgis</blockquote>
<p>And then the map-server:</p>
<blockquote>
sudo apt-get install qgis-mapserver libapache2-mod-fcgid</blockquote>
<p>Now we need to move to the var/www folder to install the lizmap-web-client</p>
<blockquote>
MYAPP=lizmap-web-client
VERSION=2.9
wget <a class="reference external" href="https://github.com/3liz/lizmap-web-client/archive/$VERSION.zip">https://github.com/3liz/lizmap-web-client/archive/$VERSION.zip</a></blockquote>
<p>Ok, now we need to unzip the file and so…we need to install unzip capabilities to the server:</p>
<blockquote>
sudo apt-get install unzip</blockquote>
<p>Unzip the software:</p>
<blockquote>
unzip $VERSION.zip</blockquote>
<p>Delete the temporary archive:</p>
<blockquote>
rm $VERSION.zip</blockquote>
<p>and move deep into the client folder:</p>
<blockquote>
cd /var/www/$MYAPP-$VERSION
chown :www-data temp/ lizmap/var/ lizmap/www lizmap/install/qgis/edition/ -R
chmod 775 temp/ lizmap/var/ lizmap/install/qgis/edition/ -R</blockquote>
<p>Now you can type in your browser address bar :</p>
<blockquote>
<a class="reference external" href="http://ec2-54-XXX-XX-XX.eu-west-1.compute.amazonaws.com/lizmap-web-client-2.9/lizmap/www/">http://ec2-54-XXX-XX-XX.eu-west-1.compute.amazonaws.com/lizmap-web-client-2.9/lizmap/www/</a></blockquote>
<p>and see the example page.</p>
<p>[REFERENCE]</p>
<p>Assuming you created a map on QGIS and then prepared the necessary files using LizMap, you are now ready to publish a map.</p>
<p>[REFERENCE]</p>
<p>You need to use a FTP software, such as Filezilla.
Open it, go to preferences select SFTP from the left panel, press “Add key..” button and select your .pem file, It will ask you to transform in a different format, continue and save the file on the usual ec2 director.
Create a new connection, enter the server public DNS, use ubuntu as user, select SFTP as connection type and normal, don’t enter any password.
[REFERENCE]</p>
<p>You may think that this is it but, if you try and upload the map files, you’ll get a permission error.
Enter the terminal and ssh into the running instance, create a folder to host the files:</p>
<blockquote>
mkdir var/www/maps</blockquote>
<p>Take care of the permissions:</p>
<blockquote>
sudo chown ubuntu:ubuntu /var/www/maps</blockquote>
<p>this will allow Filezilla to transfer files.
[REFERENCE]</p>
<hr/>
</div>
<section>
<div class="span2" style="float:right;font-size:0.9em;">
<h4>Published</h4>
<time pubdate="pubdate" datetime="2014-12-13T18:32:00+01:00">Dec 13, 2014</time>
<h4>Category</h4>
<a class="category-link" href="/categories.html#test-ref">Test</a>
<h4>Connect</h4>
<a href="http://twitter.com/lucamoiana" title="My Twitter Profile" class="sidebar-social-links" target="_blank">
<i class="fa fa-twitter sidebar-social-links"></i></a>
<a href="http://github.com/LucaMoiana" title="My Github Profile" class="sidebar-social-links" target="_blank">
<i class="fa fa-github sidebar-social-links"></i></a>
<a href="https://it.linkedin.com/pub/luca-moiana/3/266/592" title="My Linkedin Profile" class="sidebar-social-links" target="_blank">
<i class="fa fa-linkedin sidebar-social-links"></i></a>
<a href="mailto:[email protected]" title="My Email Address" class="sidebar-social-links" target="_blank">
<i class="fa fa-envelope sidebar-social-links"></i></a>
<a href="href="skype:lucamoiana?call"" title="My Skype Profile" class="sidebar-social-links" target="_blank">
<i class="fa fa-skype sidebar-social-links"></i></a>
</div>
</section>
</div>
</article>
</div>
<div class="span1"></div>
</div>
</div>
<div id="push"></div>
<footer>
<div id="footer">
<ul class="footer-content">
<li class="elegant-power">Powered by <a href="http://getpelican.com/" title="Pelican Home Page">Pelican</a>. Theme: <a href="http://oncrashreboot.com/pelican-elegant" title="Theme Elegant Home Page">Elegant</a> by <a href="http://oncrashreboot.com" title="Talha Mansoor Home Page">Talha Mansoor</a></li>
</ul>
</div>
</footer> <script src="http://code.jquery.com/jquery.min.js"></script>
<script src="//netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/js/bootstrap.min.js"></script>
<script>
function validateForm(query)
{
return (query.length > 0);
}
</script>
</body>
<!-- Theme: Elegant built for Pelican
License : http://oncrashreboot.com/pelican-elegant -->
</html>