Define Let’s Encrypt SSL to Tomcat

cd /etc/letsencrypt/live/exampledomain.comlsopenssl pkcs12 -export -out bundle.pfx -inkey privkey.pem -in cert.pem lsmv bundle.pfx /opt/tomcat/bundle.pfx ll /opt/tomcat/bundle.pfx ll /opt/tomcat/cd /opt/tomcat/confnano server.xml<Connector protocol=”org.apache.coyote.http11.Http11NioProtocol” port=”8443″ maxThreads=”2048″ scheme=”https” secure=”true” acceptCount=”2048″ SSLEnabled=”true” clientAuth=”false” keystoreType=”PKCS12″ keystoreFile=”/opt/tomcat/bundle.pfx” keystorePass=”YOURPASSWORD” sslProtocol=”TLS” />chown tomcat:tomcat /opt/tomcat/bundle.pfx systemctl restart tomcat

Maven ile manifest.mf ayarları

<build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>2.3.2</version> <configuration> <source>1.7</source> <target>1.7</target> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> </plugin> <plugin> <artifactId>maven-assembly-plugin</artifactId> <configuration> <archive> <manifest> <addClasspath>true</addClasspath> <classpathPrefix>lib/</classpathPrefix> <mainClass>my.main.class.Main</mainClass> </manifest> </archive> <descriptorRefs> <descriptorRef>jar-with-dependencies</descriptorRef> </descriptorRefs> </configuration> <executions> <execution> <id>make-assembly</id> <!– this is used for inheritance merges –> <phase>package</phase> <!– bind to the packaging phase –> <goals> <goal>single</goal> Devamı…

Spring MVC 4 ile örnek bir proje yapalım

Aslında şu sıralar çok yoğunum öyle böyle değil. Sıkıntılar dertler tepemde kara bulutlar gibi dolaşmaktan vazgeçmiyorlar ama yine de benim gibi bir manyağı durdurmaya güçleri yetmez. Hayat her zaman insanın yüzüne gülmez bazen okkalı bir tokat ta vurur ama öldürmeyen acı güçlendirir. Bu yüzden kodlamaya devam ediyoruz. Zaten iyi zamanda herkes kod yazar. Önemli olan kafada bir milyon şey varken kod yazabilmek. Bunu başarmak her yiğidin harcı değildir. Neyse konumuza dönelim. Bu yazı dizimizde sizinle örnek bir Spring MVC uygulaması yapacağız. Sonra bunu herhangi bir servera deploy edeceğiz ve tabiki SVN ve GIT üzerinden paylaşacağız. SVN server olarak Google Code, GIT olarak da Github kullanacağız arkadaşlar. Zaten o kısma gelince daha detaylı anlatacağım. Şimdilik kısaca üzerinden geçtim sadece. (daha&helliip;)