Giter Site home page Giter Site logo

timxi / sbt-native-packager-examples Goto Github PK

View Code? Open in Web Editor NEW

This project forked from muuki88/sbt-native-packager-examples

0.0 2.0 0.0 2.16 MB

A set of sbt-native-pakager examples

License: Apache License 2.0

Scala 97.97% Shell 0.22% HTML 1.55% JavaScript 0.26%

sbt-native-packager-examples's Introduction

Goal

This is a small collection of sbt-native-packager examples. Each example is very small and should be easy to understand. Pick the ones you need and tailor your packaging process.

Not all examples are 100% tested. Just open an issue if something doesn't work

Examples

Currently all examples are tested for Debian only. Feel free to correct and contribute.

Application configuration

Your application has an external configuration, which you want to change and the application should pick up this changes.

Requirements

How it's done

Typesafe config uses the system property config.file to pass in a configuration location. So you don't need to add a folder to the classpath, which could be a potential security risk.

Project

You can find a working example at application-conf

Log4j configuration

This is related to the Application configuration. This time we use log4j.

Requirements

  • Linux OS (debian/rpm)
  • Log4j 2 (works in a similar way with 1.x)

How it's done

Log4j uses the system property log4j.configurationFile to pass in a configuration location. So you don't need to add a folder to the classpath, which could be a potential security risk.

Log4j 2 as also a cool auto reconfigurate feature, which can come in very handy.

Project

You can find a working example at log4j-conf

Custom Startup Parameters

A small example how to configure your startup parameters with SBT Native Packager. You'll see how to add java system properties and application arguments. We also change the -Xmx and -Xms settings.

Requirements

  • Linux OS (debian/rpm)

How it's done

Create a file src/templates/etc-default and fill it with the content you need.

Project

You can find a working example at startscript-parameters

Links

sbt-native-packager-examples's People

Contributors

muuki88 avatar hstraub avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.