-
Notifications
You must be signed in to change notification settings - Fork 55
Improved documentation for Ubuntu15+ installations #39
Changes from 3 commits
916e285
9bd0e2c
cfdfa4e
e4dcae7
7810179
129e7c5
1a61271
39d1d30
bf1ba71
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,20 +3,37 @@ | |
> NOTE: These instructions are valid for Ubuntu versions using `systemd` init | ||
> system. | ||
|
||
Run the following commands: | ||
## TL;DR | ||
1. Get the latest [release](https://github.com/Azure/azurefile-dockervolumedriver/releases) | ||
2. Put the binary into `/usr/bin/azurefile-dockervolumedriver` | ||
3. Get the .default and .service files from the .tar.gz file and deploy them | ||
4. Reload systemd | ||
|
||
## In-depth walkthrough | ||
To ssh onto machines created with the `docker-machine` commands, you'll probably need to ssh via `docker-machine ssh [machinename]` to perform the following. | ||
|
||
0. `sudo -s` | ||
0. Download the binary from “Releases” tab of the repo to `/opt/bin/`: `wget -qO/usr/bin/azurefile-dockervolumedriver [url]` | ||
0. Make it executable: `chmod +x /usr/bin/azurefile-dockervolumedriver` | ||
0. Download the tar.gz from "Releases" tab of the repo | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. unfortunately the tar.gz contains the source code, not the binary. people shouldn't be downloading the source tree to set up this project. |
||
+ Currently this would be `wget https://github.com/Azure/azurefile-dockervolumedriver/archive/0.2.1.tar.gz` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. also I'm 100% sure somebody will copy paste this even 2 years later :) so let's not hardcode version number. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would normally change README's with latest instructions - happy to do that in future to make other folk's experience easier. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @stephlocke our releases (build+versioning) happen fairly automated. It would be preferable to not to introduce any human intervention. :-) |
||
0. Extract and copy the extracted files to `/usr/bin/azurefile-dockervolumedriver`: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is not quite accurate, we have a single file. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sorry, left the remnant in - should be changed to "Extract the files so we can get the relevant config files we need later" |
||
+ Decompress the archive: `tar -xvf 0.2.1.tar.gz` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. still against hardcoding versions |
||
0. Download the binary from the "Releases" tab of the repo to `/usr/bin/azurefile-dockervolumedriver` | ||
+ Use wget: `wget -qO/usr/bin/azurefile-dockervolumedriver https://github.com/Azure/azurefile-dockervolumedriver/releases/download/0.2.1/azurefile-dockervolumedriver` | ||
+ Make it executable `chmod +x /opt/bin/azurefile-dockervolumedriver` | ||
0. Save the `.default` file to `/etc/default/azurefile-dockervolumedriver` | ||
+ Copy the file: `cp azurefile-dockervolumedriver-0.2.1/contrib/init/systemd/azurefile-dockervolumedriver.default /etc/default/azurefile-dockervolumedriver` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this is wgettable as well from the file's raw.github.com URL. I don't think the users should be downloading the entire tar.gz. Also, if we document it like this, we'll be have to support this library structure (or docs will get broken). There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it's important users know where to get the files - not least because they might end up with the wrong copies from the init folder. If you think that it's easier for them to get the file from the git dirs that's fine - although you'd still have an issue with restricted folder structures? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. it's just generally the instructions did not seem complicated to me at all (perhaps because I'm the author of the project of course). However I think we can just clarify the file paths in the original version, but I'm a bit against providing full There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fair enough - can we simply refer to the directory they should be in ie There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @stephlocke yeah |
||
0. Edit `/etc/default/azurefile-dockervolumedriver` with your Azure Storage Account credentials. | ||
+ Edit in vi (or another editor): `vi /etc/default/azurefile-dockervolumedriver` | ||
+ Use ESC, :, x, ENTER to save an exit if you use vi | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 😢 this should not be here There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Lol, again aiming at people not comfortable with linux but who are trying to do Docker anyway, to reduce their hurdles to adopting the plugin. I'm a nano fan myself - happy to change to that ;) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
...should probably not begin with this tool. :-) It is a bit an advanced tooling for a beginner. I don't think we should mention a particular text editor. If we go down that way in all our docs, things will get fairly obfuscated. |
||
0. Save the `.service` file to `/etc/systemd/system/azurefile-dockervolumedriver.service` | ||
+ Make the requisite directories if they don't exist: `mkdir /etc/systemd && mkdir /etc/systemd/system` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. it will be there on ubuntu 16.x (this doc is designed for that version at least) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The default image used by docker-machine for azure is 15.04 o_O It's also the one MSFT sign off the ODBC 13 driver against. I think that's a nuts decision, but I'm not gonna argue with them all who made those decisions! It was just another hiccup needing to be taken into account through the "common" path if one used Docker docs to get started, as opposed to the Docker image in Azure. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @stephlocke default image of docker-machine is 15.04 everywhere. you can override it with ODBC driver has nothing to do this project unfortunately. I suggest you just create a VM with 16.04 and find your way from there. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. these can be briefly done as |
||
+ Copy the relevant file: `cp azurefile-dockervolumedriver-0.2.1/contrib/init/systemd/azurefile-dockervolumedriver.service /etc/systemd/system/` | ||
0. Run `systemctl daemon-reload` | ||
0. Run `systemctl enable azurefile-dockervolumedriver` | ||
0. Run `systemctl start azurefile-dockervolumedriver` | ||
0. Check status via `systemctl status azurefile-dockervolumedriver` | ||
|
||
Try by creating a volume and running a container with it: | ||
To test, from your base machine i.e. not inside your docker-machine, try by creating a volume and running a container with it: | ||
|
||
docker volume create -d azurefile --name myvol -o share=myvol | ||
docker run -i -t -v myvol:/data busybox | ||
|
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'm sorry but
docker-machine
has no place in this project. There are far too many ways to create a Docker engine on Azure and adding this will create more confusion.