-
Notifications
You must be signed in to change notification settings - Fork 20
Fix for saving in rpm, deb and docker repo/registries #84
Conversation
.travis.yml
Outdated
- mkdir opt | ||
- cp target/debug/weldr opt | ||
# Use the same docker image as much as possible | ||
- docker run -v "$(pwd):/src/" cdrx/fpm-centos:7 -s dir -t deb -v 0.1.0 -n weldr -C /src opt/weldr |
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.
Should we replace the 0.1.0
version with $TRAVIS_TAG
?
The user of docker here is fine with me. I originally thought it was going to be slow and was going to suggest doing something like if [ -n "$TRAVIS_TAG" ]; then something when tag set; fi
but it looks quite fast.
However, now that I think about it we want to deploy the static binary version via cargo build --target x86_64-unknown-linux-musl --release
. That is going to take a long time.
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.
$TRAVIS_TAG
Oh, I missed that, actually I was using $(cargo pkgid| awk -F'#' {'print $2'})
in my sample branch.
if [ -n "$TRAVIS_TAG" ];
yes, this makes more sense
x86_64-unknown-linux-musl
yes, looks like (ref).
Should I use the gnu
for now?
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.
x86_64-unknown-linux-musl
yes, looks like (ref).
Should I use the gnu for now?
The musl build target works fine. See the DOCKER.md. If that is not working though, we can do a normal release cargo build --release
and store that resulting binary in the deb/rpm package.
@maniankara This looks great! I made a comment about the |
@hjr3 packagecloud looks better and I didnt get access to docker hub. My user account there is same as in here. |
@maniankara ya let me know. if that does not work, i will just create an organization and go from there. maybe i should create the org now? cc @yanns |
@hjr3 if you find time, an organization would be nice. |
@maniankara @yanns i created https://hub.docker.com/u/weldr/dashboard/ and added you both as admins |
Looks much better now ! |
- Use x86_64 tag for docker container
This looks great. I will change the packagecloud repo to an org and that looks to be it. Is there anything else left to do? |
Yes. The binary is not statically linked. I can fix that quickly but, seems there might be support for x86_64 linux musl after all. |
Ah, I forgot the docker authentication part, the user/password needs to be somehow encrypted. |
@maniankara I looked at https://github.com/rust-lang/rust/blob/master/.travis.yml and they do the musl stuff within docker as well. I know https://github.com/emk/rust-musl-builder is a pretty popular docker image that has rust and musl. That also reminds me, we should only deploy from the stable build that has a tag. We can encrypt private variables for the docker user/pass via the travis gem. Read https://docs.travis-ci.com/user/environment-variables/#Defining-encrypted-variables-in-.travis.yml for more details. I looked and packagecloud.io does not have "organizations". I created a new weldr user and we should put the rpm/deb files at https://packagecloud.io/weldr/weldr . You are already a collaborator. I am removing https://packagecloud.io/hjr3/weldr |
- also for docker builds
…testing purposes.
This is great. Now
Yes, this has been the case, if you think something is missing, please feel free to point out :)
Yes, I know about this and that's how the packagecloud thing works. However, I think you could add the credentials to
Same, please suggest how to handle credentials here as well. |
ping @hjr3 |
@maniankara sorry for the delay! I was out of commission for a while and still catching up.
I should have worded this better. The I think I understand what you mean with regards to credentials. I will push a commit shortly. |
@hjr3 Ah. Alright. Now I got the idea. |
@hjr3 If you think we are done with this PR, I have recently learnt rust (starting with Tokio). What do you think would be a good bug to start with. I took a look at all of the open ones, some seemed to be old (not needed anymore?), linked (ordered) etc. Please suggest :) |
Merged as 45dccf0 |
@maniankara thank you so much for helping with this PR. If you want to work on something small, I think one of the items in #55 is an easy to place to start. That code is in https://github.com/hjr3/weldr/blob/master/src/proxy.rs in the form of simple functions. Maybe section 3.2.1 or 3.2.4? |
@maniankara i landed a big PR today that unlocks a lot of progress. I added some more help wanted issues to the list. |
Fix for #70.
Here are the some assumptions which needs to be modification:
maniankara/weldr
which needs to be changed.all
deb
andx86_64
rpm
. E.g. travis log, please comment.