By following this guide, you will learn how to create a dedicated testing environment using your personal GitLab account. This will allow you to test changes to the WikiSuite installer (WikiSuite packages) and verify that the changes work as expected before being deployed to packages.wikisuite.org.
Now leave your project as is; we'll come back to it later...
Important :
During the creation of the key, you will provide certain necessary information for its generation. Ensure that you do not have a key created with the same information you are providing. This could lead to pipeline errors when using the key on GitLab.
Open your teminal and enter the following command:
gpg --full-generate-key --openpgp
This command generates a key pair that consists of a public and a private key. A series of prompts directs you through the process:
Please select what kind of key you want: (1) RSA and RSA (default) (2) DSA and Elgamal (3) DSA (sign only) (4) RSA (sign only) (14) Existing key from card Your selection?
Choose An RSA/RSA key that allows you not only to sign communications, but also to encrypt files.
RSA keys may be between 1024 and 4096 bits long. What keysize do you want? (3072)
You can take the default value.
Please specify how long the key should be valid. 0 = key does not expire <n> = key expires in n days <n>w = key expires in n weeks <n>m = key expires in n months <n>y = key expires in n years Key is valid for?
Is this correct? (y/N)
Enter y to finish the process.
GnuPG needs to construct a user ID to identify your key. Real name: your real name Email address: example@gmail.com Comment: your comment
Change (N)ame, (C)omment, (E)mail or (O)kay/(Q)uit?
Enter the letter O to continue if all entries are correct.
Important :
You will be asked for a passphrase to create your key. Note that the GPG key should not have a passphrase, leave it blank whenever prompted.
We need to generate a lot of random bytes. It is a good idea to perform some other action (type on the keyboard, move the mouse, utilize the disks) during the prime generation; this gives the random number generator a better chance to gain enough entropy. Please enter the passphrase to protect your key:
After that, the key is created and some information is displayed in the terminal
public and secret key created and signed. pub rsaXXXX 2023-11-30 [SC] xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx uid your real name <example@gmail.com> sub rsaXXXX 2023-11-30 [E]
Be sure to keep your uid (in our example: your real name <example@gmail.com>), it will be useful to you later.
gpg --output private.pgp --armor --export-secret-key "your uid"
This will generate a private.pgp file containing your private key. Please make sure to not store/commit the private key into the source tree.
Now, let's get back to your project.
git checkout -b main
git add . git commit -m "a message"
git push origin main
or
git push --set-upstream origin main
if the branch does not exist on your GitLab repository.
After commit and push, once the pipilines have passed, the packages are automatically built by Gitlab-CI, then hosted on Gitlab-Pages. The access link for the packages is available under the "Deploy > Pages" section of your GitLab project.
The final step is to modify the wikisuite-installer script so that it can point to your project.
if your link is: https://my-ws-packages-test.gitlab.io
WIKISUITE_DEV_INSTALL_FROM_FOLDER="https://my-ws-packages-test.gitlab.io"
git add wikisuite-installer git commit -m "Update wikisuite-installer" git push origin main
1. How to test.
2. Revert all your changes and update your repository with wikisuite-packages