Staging Environment
The staging environment is used for testing and validating changes before deployment to production.
Key Features:
- Isolated environment mirroring production
- Automated testing pipelines
- Performance monitoring
- Rollback capabilities
Staging Process:
- Put your code in the
./live
folder
- Use the staging command:
./stage.sh testing
- Put your secret token in the
.secret
file in the current directory, or specify it on the command line as the second parameter
Example Output:
[2025-10-14 20:35:22] Starting backup of ./live
[2025-10-14 20:35:22] Creating tar file: testing_staging.tar.gz
[2025-10-14 20:35:22] Tar file created successfully: testing_staging.tar.gz
[2025-10-14 20:35:22] Uploading testing_staging.tar.gz to https://www.gensoftware.dev/upload.php
File uploaded successfully as testing_staging.tar.gz
[2025-10-14 20:35:22] Upload completed successfully
[2025-10-14 20:35:22] Cleaning up local tar file
[2025-10-14 20:35:22] Backup process completed successfully
Pulling Staged Codebase:
To pull the staged codebase on the live server:
- Create a directory called
live
- Install the
pull.sh
script using deploy
- Execute
./pull.sh testing
with your secret token in .secret
or passing it as parameter 2
- The payload will be downloaded and expanded into
./live
This process allows code to be pulled by remote servers from the staging server which is used during rapid development phases to quickly stage alpha and beta code. Scripts should be written after the pull, or the pull.sh
modified to then move the code into its correct locations.
Uploading Files
Learn how to upload files to our system securely and efficiently.
Supported Formats:
- Images: JPG, PNG, GIF, WebP
- Documents: PDF, DOC, DOCX
- Archives: ZIP, TAR, GZ
- Code files: All common programming languages
Upload Process:
- Navigate to the upload section
- Select files or drag and drop
- Choose appropriate category
- Click upload and monitor progress
Command Line Upload:
The command follows this format:
curl -X POST -H "Authorization: Bearer wFCh1LW" -F "file=@text.xt" -F "name=test.xt" https://www.gensoftware.dev/upload.php
This takes test.xt
and uploads it to the staging server as test.xt
under the account owning the bearer token. This allows files to be provided to GEN from any system with CURL which is pretty much all of them, even embedded linux and this can be used for diagnostics, logfiles, datafiles, any information that you need to feedback. GEN use this feature in alpha/beta testing to pass back debug data or error capture data, such as error logs and the like.
Best Practices:
- Compress large files before uploading
- Use descriptive filenames
- Verify file integrity after upload
- Organize files in logical folders
Deploy Script Manager
Manage deployment scripts with ease using our Deploy Script Manager.
USAGE:
deploy <command> [options] [arguments]
COMMANDS:
list
- List available scripts from the repository
install <script>
- Install/update a script
reinstall <script>
- Force reinstall a script (bypass version check)
remove <script>
- Remove an installed script
force-remove <script>
- Force remove script (ignores tracking file)
update [script]
- Update all scripts or a specific script
upgrade
- Upgrade the deploy manager itself
installed
- Show currently installed scripts
OPTIONS:
-d, --directory DIR
- Install scripts to specific directory (default: current)
-h, --help
- Show this help message
EXAMPLES:
deploy list
- Show available scripts
deploy install setip
- Install the setip script
deploy install setip toast
- Install multiple scripts
deploy reinstall setip
- Force reinstall setip script
deploy remove setip
- Remove the setip script
deploy force-remove setip
- Force remove (ignores tracking issues)
deploy update
- Update all installed scripts
deploy update setip
- Update only the setip script
deploy upgrade
- Upgrade deploy manager itself
deploy installed
- Show what scripts are installed
Installation:
The first time you use this script, it will automatically install to the appropriate location:
- Linux: /usr/bin/deploy (requires sudo)
- macOS: /usr/local/bin/deploy (requires sudo)
- Windows: Not supported (requires bash environment)