Open parleer opened 4 years ago
Hello. This is not bug. This is the expected behaviour with Gitlab, GitHub and Bitbucket repositories. The source and dist are almost the same (files can be excluded from the dist with .gitattributes).
Your need is to serve custom artefacts. Gitlab made a great work for that with the Composer Packages Repository feature. https://docs.gitlab.com/ee/user/packages/composer_repository/ You can use Satis to mirror the Gitlab package repository of if necessary.
Describe the bug When pointing satis to a Gitlab repo, it chooses a dist url that mirrors the source url instead of finding the Gitlab Release and using the dist zip artifact.
To Reproduce Make your
satis.json
look like this;Then run
satis build satis.json
and satis will create a packages.json that looks like this:Expected behavior
The dist is supposed to be a distributable build of my app, NOT the source code version stored in git. The dist version's scripts are minified, css is build from sass, and various other things have been optimized. The dist version is stored as a zip artifact referenced by the Gitlab Release.
The above dist.url is simply an API call to Gitlab to generate a zip of the files as they appear within the git repo!
I expected satis to use the carefully constructed zip distributable that's associated with the Release. In my case, the url points to a Gitlab-CI artifact: