-
Notifications
You must be signed in to change notification settings - Fork 97
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
Differentiate ISO types: dev or release #295
Conversation
Release build: '/vagrant/build.sh' or '/vagrant/build.sh release'. Development build: '/vagrant/build.sh dev'. A release image is to be used by cold storage operators who do not need to have access to an interactive shell. For a release image to boot into a root shell successfully, an SCSI/ATA hard drive needs to be available, with a partition '/dev/sda1' used as persistent storage for the cold wallet. The partition can be formatted in ext3 or vfat for example. The device node '/dev/sda1' is required to give the operators a seamless experience when booting up the system. A few other files, including the HSM world and encrypted secrets, and compiled subzero code (in .jar and signed .sar), are not checked in to the project repository, and need to be added to their appropriate locations (please refer to README.md) before building a release image that will work out of the box. A development image is to be used by subzero developers for HSM and cold wallet development. A developer can boot into an interactive root shell without performing the above mentioned steps. The HSM software is automatically installed in the development image, but a developer needs to manually set up persistent storage for the cold wallet, put .jar and .sar files to appropriate filesystem locations, and execute them accordingly, for development and testing.
live-usb-creator/README.md
Outdated
|
||
## Writing image to USB drive | ||
|
||
1. Identify device path to disk (such as `/dev/disk3`) with `diskutil list external physical` | ||
2. Unmount all volumes on that disk with `diskutil unmountDisk /dev/disk3` | ||
3. Identify the “raw” device path by replacing `disk` with `rdisk` in the device path. (E.g. `/dev/disk3` becomes `/dev/rdisk3`.) This speeds up writes by 3–4× in very informal testing. | ||
3. Write ISO to that “raw” device path with `sudo dd bs=1m if=boot.iso of=/dev/rdisk5`. Remember that on MacOS you can check in on progress by sending SIGINFO with Ctrl+T. (Takes about 30 minutes in one test.) | ||
3. Write ISO to that “raw” device path with `sudo dd bs=1m if=boot.iso of=/dev/rdisk3`. Remember that on MacOS you can check in on progress by sending SIGINFO with Ctrl+T. (Takes about 3 minutes in one test.) |
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 would put this as /dev/rdiskN
, since the N is going to be different for everyone / on each run.
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 idea. (I was intending to keep the changes to README small with this PR, and disk3
is a more consistent name in the context. But I think it's good to be more rigorous here.)
live-usb-creator/README.md
Outdated
be added to their appropriate locations before building a release image | ||
that will work out of the box. | ||
|
||
* `data_app_subzero/` should contain `subzero-cli.jar`, |
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.
The way this is written, it sounds like you need to put data_app_subzero
on /dev/sda1, which isn't true.
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 good feedback. I will re-write the paragraph in a (hopefully) clearer way.
live-usb-creator/README.md
Outdated
without performing the above mentioned steps. The HSM software is | ||
automatically installed in the development image, but a developer needs | ||
to manually set up persistent storage for the cold wallet, put .jar and | ||
.sar files to appropriate filesystem locations, and execute them |
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.
you shouldn't need to move any .jar
or .sar
files around.
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.
* Release build: `build.sh` or `build.sh release`. | ||
|
||
A release image is to be used by cold storage operators who do not need | ||
to have access to an interactive shell. For a release image to boot into |
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 PR doesn't remove the interactive shell (#239). Might be worth clarifying here that the interactive shell is available for debugging purpose, but the default behavior is different between release and 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.
It's a great point.
Thank alokmenghrajani and oreparaz for their feedback.
Nice, hopefully this makes development easier. Thanks @syncom |
Release build: '/vagrant/build.sh' or '/vagrant/build.sh release'.
Development build: '/vagrant/build.sh dev'.
A release image is to be used by cold storage operators who do not need to
have access to an interactive shell. For a release image to boot into a
root shell successfully, an SCSI/ATA hard drive needs to be available, with
a partition '/dev/sda1' used as persistent storage for the cold wallet. The
partition can be formatted in ext3 or vfat for example. The device node
'/dev/sda1' is required to give the operators a seamless experience when
booting up the system. A few other files, including the HSM world and
encrypted secrets, and compiled subzero code (in .jar and signed .sar), are
not checked in to the project repository, and need to be added to their
appropriate locations (please refer to README.md) before building a release
image that will work out of the box.
A development image is to be used by subzero developers for HSM and cold
wallet development. A developer can boot into an interactive root shell
without performing the above mentioned steps. The HSM software is
automatically installed in the development image, but a developer needs to
manually set up persistent storage for the cold wallet, put .jar and
.sar files to appropriate filesystem locations, and execute them
accordingly, for development and testing.