# How do I enable SSL support for the tomcat plugin

**URL:** <https://discuss.gradle.org/t/how-do-i-enable-ssl-support-for-the-tomcat-plugin/4377>\
**Category:** Old Forum Archive\
**Created:** [December 22, 2011, 6:56am UTC](https://discuss.gradle.org/t/how-do-i-enable-ssl-support-for-the-tomcat-plugin/4377 "2011-12-22T06:56:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mansour](https://avatars.discourse-cdn.com/v4/letter/m/7cd45c/32.png) [@Mansour](https://discuss.gradle.org/u/Mansour)\
**Post date:** [December 22, 2011, 6:56am UTC](https://discuss.gradle.org/t/how-do-i-enable-ssl-support-for-the-tomcat-plugin/4377/1 "2011-12-22T06:56:00Z")

</div>

My first day using gradle. I was able to install tomcat plugin [https://github.com/bmuschko/gradle-tomcat-plugin](https://github.com/bmuschko/gradle-tomcat-plugin)

Now I need to enable SSL port. The documentation for the plugin

“enableSSL: Determines whether the HTTPS connector should be created (defaults to false).”

How do I use “Convention properties”. Any example ?

---

<div class="post-metadata">

**Author:** ![bmuschko1](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/bmuschko1/32/7194_2.png) [@bmuschko1](https://discuss.gradle.org/u/bmuschko1)\
**Post date:** [December 22, 2011, 12:16pm UTC](https://discuss.gradle.org/t/how-do-i-enable-ssl-support-for-the-tomcat-plugin/4377/2 "2011-12-22T12:16:00Z")

</div>

For understanding the concept of convention properties in general the following links will help you understand them:

[ConventionProperty DSL](http://www.gradle.org/current/docs/dsl/org.gradle.api.dsl.ConventionProperty.html)[Gradle Plugin Conventions: Groovy Magic Explained](http://java.dzone.com/articles/gradle-plugin-conventions)

To enable SSL simply use the task name of the Tomcat plugin you are trying to use and and assign the value of the property you want to set within a closure or directly with the dot notation. Here are two examples:

```gradle
tomcatRun {
    enableSSL = true
}

```

```gradle
[tomcatRun, tomcatStop]*.enableSSL = true

```

I will add an example to the documentation soon.

---

<div class="post-metadata">

**Author:** ![Mansour](https://avatars.discourse-cdn.com/v4/letter/m/7cd45c/32.png) [@Mansour](https://discuss.gradle.org/u/Mansour)\
**Post date:** [December 23, 2011, 12:48am UTC](https://discuss.gradle.org/t/how-do-i-enable-ssl-support-for-the-tomcat-plugin/4377/3 "2011-12-23T00:48:00Z")

</div>

That did the trick. Thank you.
