Skip to content

Azure Functions

yucwan edited this page Nov 26, 2019 · 4 revisions

Maven Central

<plugin>
    <groupId>com.microsoft.azure</groupId>
    <artifactId>azure-functions-maven-plugin</artifactId>
    <version>[Use the latest version above]</version>
</plugin>

Prerequisites

Tool Required Version
JDK 1.8
Maven 3.0 and above
.Net Core SDK Latest version
Azure Functions Core Tools 2.0 and above

Note: See how to install Azure Functions Core Tools - 2.x

Common Questions

Q: Can I upload other static content, e.g. HTML files, as part of the function deployment?

A: You can achieve this by adding configurations for the maven-resources-plugin. For example:

<plugin>
  <artifactId>maven-resources-plugin</artifactId>
  <executions>
    <execution>
      <id>copy-resources</id>
      <phase>package</phase>
      <goals>
        <goal>copy-resources</goal>
      </goals>
      <configuration>
        <overwrite>true</overwrite>
        <outputDirectory>${stagingDirectory}</outputDirectory>
        <resources>         
          ...         
          <!-- Your static resources -->
          <resource>
            <directory>${project.basedir}/src/main/resources</directory>
            <includes>
              <include>www/**</include>
            </includes>
          </resource>
        </resources>
      </configuration>
    </execution>
    ...
  </executions>
</plugin>
Clone this wiki locally