-
-
Notifications
You must be signed in to change notification settings - Fork 440
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add .gitlab-ci.yml #2345
add .gitlab-ci.yml #2345
Conversation
Sounds awesome! 👍 |
Can gitlab upload to bintray? I'd rather just bring this internal. I don't want to promote anyone else's builds because users don't have a good way to trust the contents. We don't have signed builds set up yet but it is on the roadmap |
Can we upload his build to our releases at least for the moment? Releases are manually uploaded anyway. We could include ubuntu builds for ourselves, Travis can handle docker container as well. |
So whats the difference between gitlab and github? |
@Daenyth Yes. I've had it do that for a couple of my other projects. It's as simple as calling the API command via @tooomm I could, but I'm much less familiar w/ Travis, and I already have GitLab CI fully working. Plus, almost none of the work I've done to get it working is transferable to Travis. @woogerboy21 The main difference is that GitLab can be self-hosted, like mine is. It also has its own self-contained CI system, and has unlimited private repos. |
(don't merge this yet; i'm making a few improvements which will make it easier to add automatic uploads and non-debian oses later) |
I'm not sure what to do with this PR. I'm hesitant to start using another service until we all talk about it as a team. |
Eh, it's really up to you guys. I have a personal gitlab server in house that I use for smaller projects and copies of repo's from github so I can go either way. By no means am I an expert with it. |
Looks like this currently depends on #2351. |
Is there hosted gitlab CI we can use? I'm not interested in hosting it myself and I'd like a service just so I can trust their security rather than a one-person owned server somewhere |
there is, yes: https://gitlab.com (you have to sign up before it shows the gitlab ui) |
I saw gitlab had issues a few weeks ago and I'd rather avoid them for now, especially if we're using their hosting services... |
.gitlab-ci.yml
Outdated
script: | ||
- mkdir build || true # allowed to fail | ||
- cd build | ||
- cmake .. -DWITH_SERVER=1 -DCMAKE_BUILD_TYPE=Release -DPACKAGE_GENERATOR=DEB |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you update this to use -DCPACK_GENERATOR
instead of -DPACKAGE_GENERATOR
as implemented in #2373? Thank you
I think it's would be nice to get this merged in anyway. It's a step forward towards providing linux packages for any recent distro. |
(there are still a few minor changes I'd like to make before this gets merged) |
What changes are still necessary here? |
There are still a few problems with this:
I'd like to get these done before merging. I'll be able to work on this again today, so hopefully it won't take too long. |
Is there an error message? The debug builds have more strict cflags and also provide the unit tests |
|
Probably these files contains the exact error |
I would assume so, but getting at those files is an issue, since it's only happening in CI. |
after fixing a couple of the other issues from above, the cmake error went away. |
fix artifact selection fix rpm builds mostly fix debian builds (still have cmake issue) update to conform with Cockatrice#2373 combined rc and debug stages (more efficient as one stage) add unused deploy section (can be finished/configured later)
.gitlab-ci.yml
Outdated
- mkdir build || true # allowed to fail | ||
- cd build | ||
- cmake .. -DWITH_SERVER=1 -DCMAKE_BUILD_TYPE=Release -DCPACK_GENERATOR=DEB | ||
- make package -j2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use -j
instead of -j2
to match threads to the number of cores instead of always 2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't you mkdir -p build
instead of the || true aspect?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will -j
automatically make use of all cores @Daenyth ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I use -j2
here because Gitlab Runner will starve the rest of the server if I don't limit the number of jobs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Daenyth so is this statement on the top of our compiling wiki still correct and useful then?
https://github.com/Cockatrice/Cockatrice/wiki/Compiling-Cockatrice-(Linux)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not so useful. Want to remove it and change all the j
s?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not so useful. Want to remove it and change all the js?
did so for mac and linux compiling wiki
Comments from dae and zach on this section still stand.^^
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mkdir -p build
Oh, duh. Dunno why I did it the other way.
- apt-get -o dir::cache::archives="cache" install -y qt5-default qttools5-dev qttools5-dev-tools | ||
- apt-get -o dir::cache::archives="cache" install -y qtmultimedia5-dev libqt5multimedia5-plugins | ||
- apt-get -o dir::cache::archives="cache" install -y libqt5svg5-dev libqt5sql5-mysql | ||
- apt-get -o dir::cache::archives="cache" install -y libqt5websockets5-dev |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason to do multiple commands here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mostly so it looks nice in the yml. Splitting it up doesn't have any real impact on performance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
.gitlab-ci.yml
Outdated
<<: *install_requirements_16xx | ||
<<: *artifacts_deb | ||
<<: *cache | ||
# <<: *bintray_releases_deb |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔪 this isn't coming back
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch
.gitlab-ci.yml
Outdated
|
||
#=================================== DEPLOY =================================== | ||
|
||
# deploy_to_bintray: # currently unused; requires some config |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔪
simplify `mkdir` command remove bintray deploy
I'm still a fan of this, though it looks like the windows builds failed due to the issue we had in our appveyor config. If you merge in master it should build ok. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks ok, release builds works fine and seems to produce working artifacts.
Ubuntu 16.10 and Debian Stretch debug builds are broken because of #2343, but that can only be fixed by the ubuntu/debian maintainers by updating the packages in their distro to actually working versions.
Ubuntu bug report: https://bugs.launchpad.net/ubuntu/+source/protobuf/+bug/1643959
Debian bug report: currently not reported, nobody sane wants to mess with their archaic bugreport tool.
Should we |
I can add the code to upload to github on tags and hand over the repo on my instance to one of you guys, if you'd like it to do so. Otherwise, the builds produced by my instance would have to be manually uploaded to github. |
I'd merge this as it is by now; i suppose user or developer-provided builds will be considered "unofficial" by now as per #2345 (comment) |
Where should my developer build be linked? Do we want to link them from a wiki page with the appropriate warnings about how these builds are unsupported? |
For now let's go with that |
Here's the wiki page: https://github.com/Cockatrice/Cockatrice/wiki/Unofficial-Developer-Builds The download links automatically link to the newest artifacts built from |
* revert #2345 * remove gitlab yml
* move db udpate (Cockatrice#4015) * Remove gitlab config (Cockatrice#4037) * revert Cockatrice#2345 * remove gitlab yml * fix message when moving cards to bottom of library (Cockatrice#4006) * Change method of opening directories to be the same for all oses, including linux (Cockatrice#4046) * add opening directory in file browser to linux this uses QDesktopServices to open the url "file://[location]" by default this is "file://$HOME/.local/share/Cockatrice/Cockatrice/pics/CUSTOM" any distro that has a file browser should have an accompanying mime type specifying the file handler for the file:// protocol using the inode/directory mime type see https://specifications.freedesktop.org/shared-mime-info-spec/shared-mime-info-spec-latest.html if a user were to have removed their mime database this will not work and it will fail with nothing but a log message, this would be rare and not worth checking in my opinion * make opening directories the same for all oses * sort headers * Made user information window resizable (Cockatrice#4009) * Added horizontal layout and stretch for player icon (Cockatrice#4052) * Fix unresolved symbols when link tests to system libgtest-dev (Cockatrice#4055) * Enable parallel compilation. (Cockatrice#4057) * travis: update macos 10.15 images (Cockatrice#4059) * Fix release tests (Cockatrice#4063) Co-authored-by: tooomm <tooomm@users.noreply.github.com> Co-authored-by: Lee Tran <54418451+LeeTranMN@users.noreply.github.com> Co-authored-by: ebbit1q <ebbit1q@gmail.com> Co-authored-by: awlangham <awlangham@gmail.com>
This adds a configuration file for GitLab CI.
This commit is necessary so that binaries compiled on my GitLab instance have the same commit hash as those compiled on Travis.
I will be compiling binaries for any OS where there is a docker image and no TravisCI support. (Currently Ubuntu 16.04 & 16.10)