LooPyGen CLI Image for Server Applications
258
A Docker image of LooPyGen's python and node backend to be run as a headless application on a server.
The aim is to provide LooPyGen as a CLI client for use in servers with dApps. As with the UI version, this requires a MetaMask or GameStopNFT wallet to run transfers.
It also requires storing private keys on the server, so it would be wise to use a dev wallet and only fund it with just enough for whatever transactions it would be performing. Although we encrypt the keys and store them in a Docker volume, you still need to pass a passphrase for the key file in a command argument or custom dotenv setup to automate the process.
Please make sure you understand the implications before moving forward with a server implementation, and that we never recommend using your main wallet for this kind of usage.
Notes:
docker image prunedocker volume prune./loopygen-cli.sh bash--configpass $(echo -n "passphrase" | basenc --base64)
If you plan to run the headless version in order to take advantage of server processing resources, such as high quality video or GIF collections, then you will need to make a collections folder available to the container on the server that includes your traits and source layers.
The easiest way to do this is to run the LooPyGen GUI locally to create and setup your collection files. Then you can copy your local collections folder to the server. If you keep the folder named collections and run the loopygen-cli.sh script at the same folder level, the container will automaticaly have access to the files.
For instance, your folder structure should look like this:
appdir/
├ collections/
└ loopygen-cli.sh
Download the script from GitHub with to your local working directory
# using wGET
$ wget -O ./loopygen-cli.sh https://github.com/sk33z3r/LooPyGen/blob/main/cli.sh && chmod +x loopygen-cli.sh
# using cURL
$ curl https://github.com/sk33z3r/LooPyGen/blob/main/cli.sh -o loopygen-cli.sh && chmod +x loopygen-cli.sh
Pull the latest image
$ ./loopygen-cli.sh update
Run a command
$ ./loopygen-cli.sh {command}
Replace {command} with one of the below commands.
Encrypt your mint configuration
encrypt --mint
Encrypt your transfer configuration
encrypt --transfer
Basic run:
generate --count XXX
Delete previously generated images before generating a new set:
generate --empty --count XXX
Start generating from a specific ID number:
generate --count XXX --id YY
If you have a beefy computer, you can try to generate images simultaneously to speed up the process:
generate --count XXX --threaded
Basic run, after generating images:
metadata
Delete previously generated metadata before generating a new set:
metadata --empty
Batch mint a collection:
mint --name <my_nft_collection> --amount 1
Mint a specific set of IDs:
mint --name <my_nft_collection> --start <startID> --end <endID> --amount 1
Mint a single CID:
mint --cid Qmau1Sx2hLTkLmXsu2dD28yMZtL3Pzs2uKqP2MeHZPm93V --amount 100
Test run a mint (shows only what the script would do, but doesn't actually do it):
mint --name <my_nft_collection> --testmint --amount 100
To scan CID files, input a path relative to your working directory.
The file must be at your current level or lower, and not outside of the directory. For instance, ../other-dir/somefile would not work.
CIDv0:
cid ./relative/path/to/file
CIDv1:
cid --cid-version=1 ./relative/path/to/file
Content type
Image
Digest
Size
92.5 MB
Last updated
over 4 years ago
docker pull sk33z3r/loopygen-cli