Skip to content

Create scripts for the server jar #85

Closed

Description

@edgan

A script to make the running of the server a little easier. The more you make the process convenient the more people will want to use the software.

People could write their own scripts, but why force everyone to do that. It is even worse if they keep upgrading by downloading the next version.

As for the filename changing with version numbers, I would create a symlink to the actual file via automation. Alternatively you could use a wildcard like ClipCascade-Server.-*.jar.

You would probably also then want to make a ClipCascade-Server-3.0.2.tar.gz instead of just the jar stand-alone.

Symlink:

ln -s ClipCascade-Server-3.0.2_JRE-17.jar ClipCascade-Server.jar

server.sh for Linux and macOS:

#!/bin/bash

java -jar ClipCascade-Server.jar $@

server.bat for Windows:

java.exe -jar ClipCascade-Server.jar %*

Activity

  1. edgan commented on Feb 3, 2025

    @edgan
    Author

    Yet another idea would be to add support for sourcing the environment variables.

    With bash that would be something like:

    #!/bin/bash
    
    source .env
    
    java -jar ClipCascade-Server.jar $@
    

    .env:

    CC_MAX_MESSAGE_SIZE_IN_MiB='1'
    CC_ALLOWED_ORIGINS='*'
    CC_P2P_ENABLED='false'
    CC_SIGNUP_ENABLED='false'
    CC_PORT='8080'
    

    You could probably make something like this for Windows too. Though it will probably be easier with Powershell.

  2. Repository owner locked and limited conversation to collaborators on Feb 4, 2025
  3. converted this issue into a discussion #90 on Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions