Skip to content
This repository has been archived by the owner on Jul 11, 2022. It is now read-only.

Commit

Permalink
fixed an issue with installing nitrod
Browse files Browse the repository at this point in the history
Signed-off-by: Jason McCallister <jason@craftcms.com>
  • Loading branch information
jasonmccallister committed Aug 7, 2020
1 parent 4cd2ead commit d74a0d0
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 7 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Release Notes for Craft Nitro

### Unreleased

## Fixed
- Fixed an issue that occurred when creating new machines.

### 1.0.0-RC1 - 2020-08-07

## Added
Expand Down
9 changes: 2 additions & 7 deletions internal/cmd/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,11 +142,6 @@ runcmd:
- cp /etc/skel/.bash_logout /home/ubuntu/.bash_logout
- sed -i 's|#force_color_prompt=yes|force_color_prompt=yes|g' /home/ubuntu/.bashrc
- chown -R ubuntu:ubuntu /home/ubuntu/
- curl -s https://api.github.com/repos/craftcms/nitro/releases/latest | grep "browser_download_url" | grep "nitrod_linux_x86_64" | cut -d : -f 2,3 | tr -d \" | wget --directory-prefix=/tmp -qi -
- cd /tmp && tar xfz /tmp/nitrod_linux_x86_64.tar.gz
- mv /tmp/nitrod /usr/sbin/
- mv /tmp/nitrod.service /etc/systemd/system/
- systemctl daemon-reload
- systemctl start nitrod
- systemctl enable nitrod
- wget https://raw.githubusercontent.com/craftcms/nitro/master/nitrod.sh -O /tmp/nitrod.sh
- bash /tmp/nitrod.sh
`
18 changes: 18 additions & 0 deletions nitrod.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash

# download the
curl -s https://api.github.com/repos/craftcms/nitro/releases/latest \
| grep "browser_download_url" \
| grep "nitrod_linux_x86_64" \
| cut -d : -f 2,3 | tr -d \" \
| wget --directory-prefix=/tmp -qi -

# move nitrod into place
cd /tmp && tar xfz /tmp/nitrod_linux_x86_64.tar.gz
mv /tmp/nitrod /usr/sbin/
mv /tmp/nitrod.service /etc/systemd/system/

# setup the service
systemctl daemon-reload
systemctl start nitrod
systemctl enable nitrod

0 comments on commit d74a0d0

Please # to comment.