Giter Club home page Giter Club logo

stork's People

Contributors

ajcamilo avatar bertranda avatar dajester2013 avatar dependabot[bot] avatar gitblit avatar jjlauer avatar lodrantl avatar mikegager avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

stork's Issues

stork-fabric-deploy on windows ?

I went more in deep into your project and wanted to test stork-fabric-deploy. I only see a Linux command line tool for this command where other commands have a windows batch equivalent (http://puu.sh/gkq8i/69273c738b.png). I imagine because it use ssh to push etc. Do you think that there is a way to use stork-fabric-deploy from a windows dev environnement to a linux prod test env ?

Add gradle plugin

It would be good to have this also available as a Gradle plugin :)

No server.out log file

I am using the plugin to package an application. The problem I am having is that it seems to want to create a server.out log file. I really don't need this file. Is there a way of telling the script not to create a server.out file?

Add support for `--add-opens` JVM option

Starting from JDK 9 we may need to add option --add-opens to the application, but if user has JDK 8 installed it won't launch because JDK 8 is not aware of such option.

Status of project? No commits in almost an year.

Due to having an issue with the maven plugin with a java 11 target app I realized that there are no commits in master over the last year. Is the project still maintained?

Do you need help with anything?

stork-deploy: Warn on deploy of existing version

If attempting to deploy a production version (e.g. no -SNAPSHOT) at end of a tarball then warn if it already exists on target server. Add a command-line option of --force or -f to force a re-deploy of an existing version.

[: Illegal number: 09:52:08:460 when using JAVA_TOOL_OPTIONS with a java agent

We are using Datadog java agent in JAVA_TOOL_OPTIONS environment variable:
export JAVA_TOOL_OPTIONS="-javaagent:dd-java-agent.jar -Ddd.writer.type=LoggingWriter"

This means that when stork tries to discover java versions, the java version parsing algorithm sometimes fails due to the extra output from datadog java agent:

❯ export JAVA_TOOL_OPTIONS="-javaagent:dd-java-agent.jar -Ddd.writer.type=LoggingWriter" 
❯ java -version 2>&1 | grep "version" | awk '{print $3}' | tr -d \" 
10:16:24:649
10:16:24:650
10:16:24:650
22.0.1

If the output from datadog java agent is the last and not the java version, the bash script fails with:

❯ ./stork-demo-hellod        
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
./stork-demo-hellod: 496: [: Illegal number: 14:14:03:228
Unable to find Java runtime on system with version >= 1.6
Try running 'sudo apt-get install openjdk-6-jre-headless' or
Visit http://java.com to download and install one for your system

install fails on Windows

Environment:

  • java 8
  • jooby 2.8.10
  • Windows 10
  • maven 3.6.3

This error occurred after packaging a Jooby app which uses the jooby-stork plugin
https://github.com/jooby-project/jooby/blob/2.x/pom.xml#L151
which uses stork 3.1.0

Steps:

jooby create test --stork
cd stork
  • in stork.yml
platforms: [ WINDOWS ]
  • package
mvn clean package
  • extract /target/test-1.0.0.stork.zip and run
\bin\test.bat --install

Expected Result:

  • The application is installed and can then be started using the start command.

Actual Result:

bin\test64.exe is not compatible with the version of Windows you're running. 
Check your computer's system information and then contact the software publisher.

undeploy/uninstall

I was testing stork and I did a few deploys to a server. Is there a way to uninstall all or some specific versions?

Add files to conf/

How can I add files to conf/
I tried to create src/main/conf/foo.conf to see if it was packed in tar.gz

Need a step by step usage manual.

Hi,

I'm trying to figure out how to generate a systemd init script using Stork, but I can't figure out how to use it. Would it be possible to have a step by step manual on how to proceed?

I have akamai-cefconnector, a java program that need to be run as a service (daemon) on Linux.

Folder structure is :

./bin/CEFConnector-1.6.0.jar
./config/[CEFConnector.properties, log4j2.xml]
./lib
./logs

I just need to generate the systemd init script to operationalise it.

Thank you!

systemd instead of init

Hello,

I'm very interested in trying this one on my production servers for deploying, however I wonder if it was possible to choose between init and systemd, as my target is RHEL.

I'm using type: CONSOLE, so my service only has :

[Unit]
Description=myapp sample application
After=syslog.target network.target

[Service]
ExecStart=/opt/folder/myapp/bin/myapp

[Install]
WantedBy=multi-user.target

I think we should add Restart=always and of course application must be configure with working_dir_mode: APP_HOME !

Still need to find how to configure for type: DAEMON.

Other things that would be cool:

  • chosse target folder, with default to /opt
  • allow local deploy without sshing to the same server

What do you think ?

Can we implement stork plugin with spring boot application

I am trying to implement stork in my spring boot application. I am passing my main class method in stork configuration file (.yml). Stork files are getting generated. When I am trying to install and start the application. It is saying "noclassdeffounderror". It is not able to find the main class.

Add platform_configurations section to README

It took me quite a while to figure out how to specify a user and group for the generated systemd service file in the stork.yml launcher definition. I eventually found it in one of the example files, but it doesn't appear to be documented anywhere.

Here's the example I found, but I don't know if this is all of the available options for this section:

platform_configurations:
  LINUX:
    daemon_method: NOHUP
    user: "daemon"
    group: "daemon"
  
  MAC_OSX:
    user: "_daemon"
    group: "_daemon"
  
  WINDOWS:
    daemon_method: JSLWIN

Spring Boot demo start failure on macOS Mojave

A Spring Boot demo & stork is attached.
Pack with the command $./mvnw clean package is ok.
The jar file can be run by $java -jar xxx.jar, but the stork script failure to start.
The error info is :

$ ./target/stork/bin/hello-server --run
Error: Could not find or load main class com.example.demo.DemoApplication

Could anyone help me, thank your!
demo.zip

Retain option missing on stork-deploy > 2.7.0

Hi Joe,

how are you doing :-)

I started using stork-deploy to deploy our java apps and I really like it. It's so simple. Single dependency is Java. Goodbye ansible 👍

I found a minor issue with the current version of stork-deploy. The changelog states (for version 2.6.0)

stork-deploy: New retain option to only retain a specified number of past versions after a successful deploy.

but the option is missing when looking in the code. The DeployOptions class has already the field, but the DeployMain class is missing the parameter.

I could provide a PR if you like containing that little fix.

Cheers,
Marvin

Multiple Java Args

When we need to pass multiple java arguments, should they be all specified in a single set of quotes, or as a comma separated list in square brackets?

java_args: "-Dtest=foo -Dopt2=abc"

or

java_args: ["-Dtest=foo", "-Dopt2=abc"]

Failed start on MacOS Catalina

When setting memory by percentage of system, program can't start and report below error:

Unable to detect system memory to set java max memory

It seems that on Catalina below line is incorrect:

local mem_bytes=`sysctl -a 2>/dev/null | grep "hw.memsize" | head -n 1 | awk -F'=' '{print $2}'`

should it be the same as freebsd?

local mem_bytes=`sysctl -a 2>/dev/null | grep "hw.memsize" | head -n 1 | awk -F'[:=]' '{print $2}'`

Path problem when using --start

I am trying to use stork 2.0.0 in a ninja framework/maven based API project deployed to a staging environment on Ubuntu 14.04 with stork-deploy. When the application is about to start (at deploy or started by hand) I get the following errors:

Starting ContactApi: /opt/ContactAPI/current/bin/ContactApi: 806: /opt/ContactAPI/current/bin/ContactApi: cannot create /opt/ContactAPI/current//opt/ContactAPI/current/log/ContactApi.out: Directory nonexistent   
/opt/ContactAPI/current/bin/ContactApi: 808: /opt/ContactAPI/current/bin/ContactApi: cannot create /opt/ContactAPI/current//opt/ContactAPI/current/log/ContactApi.out: Directory nonexistent   
failed

The application is currently a snapshot version. Running it with "./ContactAPI --run" in the "/opt/ContactAPI/current/bin" directory is working fine. "./ContactAPI --start" in the same directory is showing the behaviour above.

Starting it in "/opt/ContactAPI/current" with "bin/ContactAPI --start" is also working nicely as well as a "bin/ContactAPI --stop".

Starting it with "service ContactAPI start" is showing the same errors.

I have no idea where to search for this problem. Any idea/hint?

Where is the gradle plugin?

Hi,
Migrating from maven to gradle, and tried the plugin isn't found

CONFIGURE FAILED in 1s
Plugin [id: 'com.fizzed.stork', version: '2.8.0'] was not found in any of the following sources:

- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (could not resolve plugin artifact 'com.fizzed.stork:com.fizzed.stork.gradle.plugin:2.8.0')
  Searched in the following repositories:
    Gradle Central Plugin Repository

Deployment issue

Hi
When deploying I get the following error on my VSTS CI server:
2018-07-25T20:35:17.4860494Z [ERROR] Unable to cleanly deploy 2018-07-25T20:35:17.4874552Z com.fizzed.blaze.ssh.SshException: Auth fail 2018-07-25T20:35:17.4890901Z at com.fizzed.blaze.ssh.impl.JschConnect.tryToUnwrap(JschConnect.java:369) 2018-07-25T20:35:17.4904381Z at com.fizzed.blaze.ssh.impl.JschConnect.doRun(JschConnect.java:356) 2018-07-25T20:35:17.4918699Z at com.fizzed.blaze.ssh.impl.JschConnect.doRun(JschConnect.java:50) 2018-07-25T20:35:17.4931760Z at com.fizzed.blaze.core.Action.runResult(Action.java:33) 2018-07-25T20:35:17.4944694Z at com.fizzed.blaze.core.Action.run(Action.java:39) 2018-07-25T20:35:17.4958020Z at com.fizzed.stork.deploy.Targets.sshConnect(Targets.java:71) 2018-07-25T20:35:17.4971056Z at com.fizzed.stork.deploy.Targets.connect(Targets.java:46) 2018-07-25T20:35:17.4984250Z at com.fizzed.stork.deploy.Deployer.deploy(Deployer.java:47) 2018-07-25T20:35:17.4997774Z at com.fizzed.stork.deploy.DeployMain.run(DeployMain.java:160) 2018-07-25T20:35:17.5010432Z at com.fizzed.stork.deploy.DeployMain.main(DeployMain.java:33) 2018-07-25T20:35:17.5023154Z Caused by: com.jcraft.jsch.JSchException: Auth fail 2018-07-25T20:35:17.5036770Z at com.jcraft.jsch.Session.connect(Session.java:519) 2018-07-25T20:35:17.5049415Z at com.fizzed.blaze.ssh.impl.JschConnect.doRun(JschConnect.java:342) 2018-07-25T20:35:17.5062275Z ... 8 common frames omitted

What can the issue be? I can scp files to the server, so SSH is configured correctly.

mv: ‘../current/log’ and ‘../vserver/log’ are the same file

Hello Everyone,

I upgraded to stork v3.0.0 after moving to java11 for a new project.

The first deployment worked, however now after the second deployment the following error occurs:
mv: ‘../current/log’ and ‘../vserver/log’ are the same file

Can someone please advise me how to fix it?

Incorporate JSL 0.99w

Not sure what version it was introduced in, but 0.99w supports Windows Registry keys used by Adopt OpenJDK.

downgrade

Sometimes after the new deploy, we find out that new version has a nasty bug and we need to downgrade to the previous version. I'd love to have the option to select the previous version.

Thank you.

Temp dir permissions w/ multiple deploy users

When multiple users do deploys, they are unable to overwrite each other in the /tmp directory. Workround is to manually clean up the /tmp/stork-deploy directory on the target beforehand. Long term fix is to do a better job of having each user clean this after themselves after a deploy and switching to random temp directories.

stork-fabric-deploy only work the first call, crash on second one

I tested stork-fabric-deploy from a linux env to a linux env.
stork-fabric-deploy -H [email protected] --assembly target/test-1.0-SNAPSHOT.tar.gz

This work well the first time. The second push from serv1 to serv2 I got an error :

run: mkdir "test-1.0-SNAPSHOT"
run: rsync -at "/opt/test/version-1.0-20150303041435/" "/tmp/test-1.0-SNAPSHOT/" --exclude="conf" --exclude="data" --exclude="log" --exclude="run"
[localhost] local: expect -c 'exp_internal 0; set timeout 20; spawn rsync -avrtc --exclude=conf --delete --force -e "ssh -oStrictHostKeyChecking=no -p 22" work/test-1.0-SNAPSHOT/ [email protected]:/tmp/test-1.0-SNAPSHOT/; expect "?assword:"; send "123456\n"; expect eof'
/bin/sh: 1: expect: not found
Fatal error: local() encountered an error (return code 127) while executing 'expect -c 'exp_internal 0; set timeout 20; spawn rsync -avrtc --exclude=conf --delete --force -e "ssh -oStrictHostKeyChecking=no -p 22" work/test-1.0-SNAPSHOT/ [email protected]:/tmp/test-1.0-SNAPSHOT/; expect "?assword:"; send "123456\n"; expect eof''

The folder is created into the /opt/.. but seems like as there is an existing current symlink it was blocking.
the server is password protected so it ask me for the password when i used the command.

I also noticed things that i don't really agree with :
For example i noticed that you use the /tmp folder to extract the pushed tar but then don't remove it. So it can be easily explore from a hacker for example.
Second point is that the project is store in the /opt. It should be cool if we can configure that.

In my case i am using an environnement that is multi user. By that i mean i am developping an admin panel and push this panel to a server where other users have php file and can easily explore the hard disk.
I try to protect my file from reading and being potentially accessed by others. Having this tmp folder containing all those dangerous information and not cleaned just afraid me.
The /opt folder have the right to be read by other. (even if we can chmod o-rwx on in the project folder).
But this is another problem. The main problem is that stork-fabric-deploy only work the first time i execute the command.

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.