-
Notifications
You must be signed in to change notification settings - Fork 574
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 ItchySats App #1149
Add ItchySats App #1149
Conversation
This comment has been minimized.
This comment has been minimized.
a0a82e2
to
35453b2
Compare
- ${APP_DATA_DIR}/data:/data | ||
command: | ||
- --maker=mainnet.itchysats.network:9999 | ||
- --maker-id=7e35e34801e766a6a29ecb9e22810ea4e3476c2b37bf75882edf94a68b1d9607 |
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.
What is this id used for?
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 the maker's public key which is needed to have an encrypted connection with the maker behind mainnet.itchysats.network:9999
.
ba78533
to
48c7970
Compare
I've force-pushed after rebasing against the recent umbrel |
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 looks great guys, some minor tweaks required.
Btw, I'm unable to test this on my mainnet node, when I try to install I get:
umbrel@umbrel-mainnet:~/umbrel $ ./scripts/app install itchysats
Setting up data dir for app itchysats...
sending incremental file list
sent 126 bytes received 13 bytes 278.00 bytes/sec
total size is 654 speedup is 4.71
Pulling images for app itchysats...
Pulling web ... done
Starting app itchysats...
Creating itchysats_web_1 ... error
ERROR: for itchysats_web_1 Cannot start service web: OCI runtime create failed: invalid mount {Destination:data Type:bind Source:/var/lib/docker/volumes/3373facda23457bc501bfff215d91789cc1ee4f20c043d4b929bed56fc691305/_data Options:[rbind]}: mount destination data not absolute: unknown
ERROR: for web Cannot start service web: OCI runtime create failed: invalid mount {Destination:data Type:bind Source:/var/lib/docker/volumes/3373facda23457bc501bfff215d91789cc1ee4f20c043d4b929bed56fc691305/_data Options:[rbind]}: mount destination data not absolute: unknown
ERROR: Encountered errors while bringing up the project.
I was however able to succesfully install on my testnet node, so seems like I'm hitting some strange Docker bug and not an issue with your app specifically. Just checking you were able to install ok?
Also are you able to allow edits from maintainers so I can push to this PR branch?
Edit: Also one other thing, I noticed there's no authentication, so currently any user on the local network, or anyone that gets access to the users remote Tor address, can open positions and withdraw funds from the users account. We pass in an $APP_PASSWORD
env var that is a 128 bit random hex string unique to each app which apps can optionally use to add authentication. The plain text password will be show to the user in the dashboard for them to easily copy/paste it in when opening the app. I think ItchySats should make use of this, or alternatively implement some other type of custom auth. In it's current state it's quite risky, e.g a user that shares a screenshot of ItchySats on Twitter when accessing over Tor (and therefore accidentily leaking their Tor hidden service address) could have their account drained.
apps/registry.json
Outdated
"developer": "ItchySats", | ||
"website": "https://itchysats.network", | ||
"dependencies": [ | ||
"bitcoind", |
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 doesn't directly depend on bitcoind right? Only indirectly via Electrum? If so we can remove this dependency.
"bitcoind", |
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.
templates/torrc-apps-3-sample
Outdated
|
||
# itchysats Hidden Service | ||
HiddenServiceDir /var/lib/tor/app-itchysats | ||
HiddenServicePort 80 <app-itchysats-ip>:<app-itchysats-port> |
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 should be the port on the container not on the host.
HiddenServicePort 80 <app-itchysats-ip>:<app-itchysats-port> | |
HiddenServicePort 80 <app-itchysats-ip>:8000 |
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.
scripts/configure
Outdated
@@ -218,6 +218,8 @@ APP_SYNCTHING_PORT="8384" | |||
APP_SYNCTHING_SYNC_PORT="22000" | |||
APP_UPTIME_KUMA_PORT="8385" | |||
APP_UPTIME_KUMA_IP="10.21.21.62" | |||
APP_ITCHYSATS_IP="10.21.21.63" |
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.
There is an IP collision with $APP_RIDE_THE_LIGHTNING_BOLTZ_IP
in master here.
APP_ITCHYSATS_IP="10.21.21.63" | |
APP_ITCHYSATS_IP="10.21.21.64" |
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.
Also where's the best place to DM you guys for some more general questions on ItchySats? |
Also what license is the ItchySats codebase licensed under? Currently I don't see a license file on your repo. |
Seems like the volume issue is that this line https://github.com/itchysats/itchysats/blob/61c7bcbb322ab4adc43c199210a423287862a8d1/Dockerfile#L13 should be Fixed here: get10101/itchysats#971 |
Hitting this trying to open a position: Is that expected currently if the app is still in testing and you don't have a lot of funds on the maker node or is something wrong? Also seeing lots of stuff like this spamming the logs:
|
Hi @lukechilds thanks for reviewing our PR. I've fixed your comments in separate commits. Regarding the authentication: that's a good point. We do have a ticket for this get10101/itchysats#609 . Do you want this in the first release or is ok if we postpone it for the next release?
You can find us on matrix: https://matrix.to/#/#comit-hermes:matrix.org or reach us via telegram https://t.me/joinchat/ULycH50PLV1jOTI0
This looks correct and maybe we should better displayed the "No Liquidity" error a warning and not as an error: We are testing with safe amounts at the moment: $100-$1000 and the taker will create a new offer after a few seconds. The error below (Announcement not found) was not expected :/ It looks like there was a DNS error on your machine?
Let me get back to you on that. Should be an open source license. p.s. merry christmas :) |
Hi @lukechilds, thanks for giving ItchySats a try. We have 3 versions running. As far as I remember, we started with version v0.4.8 but then upgraded to v0.4.9. All three version were running without any issues. Regarding the DNS errors: it looks weird but I think we have seen this before. Regarding authentication: I would opt for a nginx proxy using
@klochowicz : please enable edits for maintainers |
971: Fix volume path r=bonomat a=lukechilds Using the relative path like this instead of an abolute path when trying to start a container I just get the error: ``` ERROR: for itchysats_web_1 Cannot start service web: OCI runtime create failed: invalid mount {Destination:data Type:bind Source:/var/lib/docker/volumes/3373facda23457bc501bfff215d91789cc1ee4f20c043d4b929bed56fc691305/_data Options:[rbind]}: mount destination data not absolute: unknown ERROR: for web Cannot start service web: OCI runtime create failed: invalid mount {Destination:data Type:bind Source:/var/lib/docker/volumes/3373facda23457bc501bfff215d91789cc1ee4f20c043d4b929bed56fc691305/_data Options:[rbind]}: mount destination data not absolute: unknown ERROR: Encountered errors while bringing up the project. ``` It seems like only certain versions of Docker fail without this, I can get your current Docker image to run on some machines but not others without this change. However with this change it runs correctly on all of my machines. Related: getumbrel/umbrel#1149 (review) Co-authored-by: Luke Childs <[email protected]>
Thanks! You too, hope you guys had a great Christmas!
To be honest it's up to you guys but I'd strongly advise adding some sort of basic auth to the initial release. Or atleast showing a big warning that this is an initial beta release with no auth if you decide not to. This sounds like a great compromise though:
Re DNS
I haven't changed any DNS settings. I just remembered some users had some issues with the mempool app that were resolved by changing Docker DNS settings. Sounds like this could be related. Let me try the proposed fix and see if that resolves the ItchySats issue. |
Also re this:
Assuming that version is maker specific? Cos this PR currently includes |
sorry, I meant Umbrel version. |
Ah got it. Btw just seen you have |
Ok so this #1076 (comment) fixed the DNS issue for me, so seems unrelated to ItchySats and some sort of internal Umbrel DNS issue. Looking into it. Opened a position! Exciting stuff 🚀 |
Re
yes indeed: @itchymax / @klochowicz please upgrade to 0.3.2.
Great that it worked and let's go Bitcoin ! 🚀 |
Also guys, looks like you are generating the seed randomly on first start. This is fine, but we also expose |
That's cool. I've created a ticket for this: get10101/itchysats#978 |
@bonomat just FYI the DNS issue seems like a DNS issue on my network unrelated to ItchySats and Umbrel. Viewing https://outcome.observer/h00.ooo/x/BitMEX/BXBT in my browser on my workstation on the same network as my Umbrel gives this error: Changing to a different network or using Tor Browser allows me to view the price feed correctly. You said you had reports of this issue before, maybe there is some sort of problem with the DNS configuration of the price feed server causing it to not work with some ISPs? Any ideas? |
42b6e9e
to
64d6a05
Compare
@lukechilds with upgrading to version I just tested upgrading my umbrel and it worked fine displaying the password/username in the appstore. I think with adding this we should be able to merge. Please let me know if there is anything else needed :) |
Includes using `$APP_PASSWORD` to restrict access to ItchySats within Umbrel by basic auth.
64d6a05
to
2109004
Compare
@lukechilds @itchymax @bonomat Unfortunately I don't seem to be able to allow pushing to this branch as the PR was created from org repo instead of personal one. I can resubmit the PR from a personal github account to allow this, but I'm not sure if it's worth the effort? |
@klochowicz ah yes, just seen this isaacs/github#1681 that sucks. Ok no worries, no need for a new PR, good to keep the history here, I can just submit a PR to your org repo if I need to do any changes. |
@scratchscratchscratchy awesome! Testing 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.
Tested and working great. Amazing stuff guys, really excited to ship this!
App Submission
App name
ItchySats
Version
v0.3.0
One line description of the app
Peer-2-peer derivatives on Bitcoin
Summary of the app
ItchySats enables peer-2-peer CFD trading on Bitcoin using DLCs (discreet log contracts). No account needed, no trusted third-party - just you and your keys.
This is beta software. We tested it on test- and mainnet, but there are no guarantees that it will always behave as expected.
Please be mindful with how much money you trust the application with.
CFDs trading is inherently risky, be sure to read up on it before using this application.
That said: This is pretty awesome, go nuts!
Limitations of the mainnet beta:
We are woking hard on perpetual positions and allowing sell positions.
Update to be expected soon!
Developer name
ItchySats
Developer website
https://itchysats.network
Source code link
https://github.com/itchysats/itchysats
Support link
https://github.com/itchysats/itchysats/issues
Requires
256x256 SVG icon
Itchilogo.svg.zip
(as zip as svgur.com is over quota and does not work now...)
Gallery images
(3 screenshots with captions)
"Start it. Trade! It’s that simple"
"Bitcoin CFDs without a middle-man"
"No accounts, just you and your keys!"
I have tested my app on: