unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
* Easy DigitalOcean setup?
@ 2020-11-09 22:28 raingloom
  2020-11-09 22:40 ` Joshua Branson
  2020-11-10  7:22 ` Easy DigitalOcean setup? Reza Alizadeh Majd
  0 siblings, 2 replies; 7+ messages in thread
From: raingloom @ 2020-11-09 22:28 UTC (permalink / raw)
  To: help-guix

[-- Attachment #1: Type: text/plain, Size: 1115 bytes --]

I've been stuck on trying to "infect" an Ubuntu VPS with Guix for a
while. It keeps failing on the bootloader setup step and it does so in
a way that somehow nukes the `guix` command, but the store remains.

At press time, my config was the one attached.

As I'm a caveperson who never owned a single UEFI machine, I'm a bit
stumped as to what the absolute heck the nature of the error might be:
```
# guix system init /etc/config.scm /
...bunch of build stuff, and then:
guix system: error:
'/gnu/store/0az53wrhxvhpkm80pmfyzw607y0qas9n-grub-efi-2.04/sbin/grub-install
--boot-directory //boot --bootloader-id=Guix --efi-directory
//boot/efi' exited with status 1; output follows:

  /gnu/store/0az53wrhxvhpkm80pmfyzw607y0qas9n-grub-efi-2.04/sbin/grub-install:
  error:
  /gnu/store/0az53wrhxvhpkm80pmfyzw607y0qas9n-grub-efi-2.04/lib/grub/i386-pc/modinfo.sh
  doesn't exist. Please specify --target or --directory.
```

I found two existing guides, but one requires adding an extra block
device and other shenanigans, and the other mentions some alarmingly
outdated version numbers, so I don't trust either of them.

[-- Attachment #2: blue.scm --]
[-- Type: text/x-scheme, Size: 2561 bytes --]

(use-modules (gnu) (gnu system nss))

(use-service-modules
 admin
 networking
 ssh)

(use-package-modules
 bootloaders
 certs
 gnome
 networking
 ssh)

(operating-system
 (host-name "blue")
 (timezone "Europe/Budapest")
 (locale "en_US.utf8")
 (keyboard-layout (keyboard-layout "us"))
 ;; Use the UEFI variant of GRUB with the EFI System
 ;; Partition mounted on /boot/efi.
 (bootloader (bootloader-configuration
				  (bootloader grub-efi-bootloader)
				  (target "/boot/efi")
				  (keyboard-layout keyboard-layout)))
 (file-systems (append
					 (list (file-system
							  (device (file-system-label "cloudimg-rootfs"))
							  (mount-point "/")
							  (type "ext4"))
							 (file-system
							  (device
								(file-system-label "UEFI"))
							  (mount-point "/boot/efi")
							  (type "vfat")))
					 %base-file-systems))

 ;; Create user `bob' with `alice' as its initial password.
 (users (cons (user-account
					(name "user")
					(password (crypt "alice" "$6$abc"))
					(group "users")
					(supplementary-groups '("wheel" "netdev")))
				  %base-user-accounts))

 ;; This is where we specify system-wide packages.
 (packages (append (list
						  ;; for HTTPS access
						  nss-certs
						  ;; for user mounts
						  gvfs)
						 %base-packages))

 (services (append (list
						  (service unattended-upgrade-service-type)
						  (static-networking-service
							"eth0" "206.189.49.189"
							#:netmask "255.255.240.000"
							#:gateway "000.000.000.000"
							#:name-servers '("84.200.69.80" "84.200.70.40"))
						  ;(service dhcp-client-service-type)
						  (service openssh-service-type
									  (openssh-configuration
										(openssh openssh-sans-x)))
						  (service
							yggdrasil-service-type
							(yggdrasil-configuration
							 (log-to 'stdout)
							 (log-level 'debug)
							 (autoconf? #f)
							 (config-file "/etc/yggdrasil-secret.conf")
							 (json-config
							  '((peers . #(;; Baden-Baden, IONOS, operated by
												;; [jcgruenhage](https://jcg.re/)
												"tcp://82.165.69.111:61216"
												"tcp://[2001:8d8:1800:8224::1]:61216"
												;; Praha, ITLDC, operated by
												;; [Revertron](https://github.com/Revertron)
												"tcp://195.123.245.146:7743"
												"tcp://[2a05:9403::8b]:7743"
												;; Praha, vpsFree, operated by @ehmry
												"tcp://37.205.14.171:46370"
												"tcp://[2a03:3b40:fe:ab::1]:46370")))))))
						 %base-services))
 ;; Allow resolution of '.local' host names with mDNS.
 (name-service-switch %mdns-host-lookup-nss))

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Easy DigitalOcean setup?
  2020-11-09 22:28 Easy DigitalOcean setup? raingloom
@ 2020-11-09 22:40 ` Joshua Branson
  2020-11-09 23:02   ` Jérémy Korwin-Zmijowski
  2020-11-10  7:22 ` Easy DigitalOcean setup? Reza Alizadeh Majd
  1 sibling, 1 reply; 7+ messages in thread
From: Joshua Branson @ 2020-11-09 22:40 UTC (permalink / raw)
  To: raingloom; +Cc: help-guix


You might try using a linode VPS.  That's what I'm using.  There is a
guide in the cookbook that shows you how to set it up. :)

-- 
Joshua Branson
Sent from Emacs and Gnus
https://gnucode.me
https://video.hardlimit.com/accounts/joshua_branson/video-channels
"You can have whatever you want, as long as you help enough other people get what they want." - Zig Ziglar


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Easy DigitalOcean setup?
  2020-11-09 22:40 ` Joshua Branson
@ 2020-11-09 23:02   ` Jérémy Korwin-Zmijowski
  2020-11-10 18:39     ` David Dashyan
  0 siblings, 1 reply; 7+ messages in thread
From: Jérémy Korwin-Zmijowski @ 2020-11-09 23:02 UTC (permalink / raw)
  To: Joshua Branson, raingloom; +Cc: help-guix

[-- Attachment #1: Type: text/plain, Size: 735 bytes --]

Le lundi 09 novembre 2020 à 17:40 -0500, Joshua Branson a écrit :
> You might try using a linode VPS.  That's what I'm using.  There is a
> guide in the cookbook that shows you how to set it up. :)
> 

Hey Raingloom !

I just played with Guix and DigitalOcean last couple of days.
If it's what you are looking for :

On my personal Ubuntu laptop, where I use Guix as a package manager, I
generated a compressed guix system image with :

$ guix system disk-image -t qcow2 do-conf.scm --image-size=5G

Then I uploaded the resulting image (i.e.
/gnu/store/f34vzy15zzk739l6gimkj5l4sn3brski-image.qcow2) as a custom
image on DigitalOcean.

Finally I create a droplet with this custom image and voilà !

Easy peasy.

Hope it will help!



[-- Attachment #2: do-conf.scm --]
[-- Type: text/x-scheme, Size: 875 bytes --]

(use-modules (gnu))

(use-service-modules ssh networking)
(use-package-modules screen ssh certs version-control)

(operating-system
 (host-name "doguix")
 (timezone "Europe/Paris")
 (locale "fr_FR.utf8")
 (packages (cons* screen git nss-certs %base-packages))
 (bootloader (bootloader-configuration
	      (bootloader grub-bootloader)
	      (target "/dev/vda")))
 (file-systems (cons (file-system
		      (mount-point "/")
		      (device "/dev/vda1")
		      (type "ext4"))
                     %base-file-systems))
 (services
  (append
   (list      
    (service dhcp-client-service-type)
    (service openssh-service-type
	     (openssh-configuration
	      (openssh openssh-sans-x)
	      (permit-root-login 'without-password)
	      (authorized-keys
	       `(("root" ,(local-file "/home/jeko/.ssh/id_ed25519.pub"))))
	      (port-number 2222))))
   %base-services)))

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Easy DigitalOcean setup?
  2020-11-09 22:28 Easy DigitalOcean setup? raingloom
  2020-11-09 22:40 ` Joshua Branson
@ 2020-11-10  7:22 ` Reza Alizadeh Majd
  1 sibling, 0 replies; 7+ messages in thread
From: Reza Alizadeh Majd @ 2020-11-10  7:22 UTC (permalink / raw)
  To: raingloom; +Cc: help-guix

On Mon, 9 Nov 2020 23:28:02 +0100
raingloom <raingloom@riseup.net> wrote:

> I've been stuck on trying to "infect" an Ubuntu VPS with Guix for a
> while. It keeps failing on the bootloader setup step and it does so in
> a way that somehow nukes the `guix` command, but the store remains.
> 
> At press time, my config was the one attached.
> 
> As I'm a caveperson who never owned a single UEFI machine, I'm a bit
> stumped as to what the absolute heck the nature of the error might be:
> ```
> # guix system init /etc/config.scm /
> ...bunch of build stuff, and then:
> guix system: error:
> '/gnu/store/0az53wrhxvhpkm80pmfyzw607y0qas9n-grub-efi-2.04/sbin/grub-install
> --boot-directory //boot --bootloader-id=Guix --efi-directory
> //boot/efi' exited with status 1; output follows:
> 
>   /gnu/store/0az53wrhxvhpkm80pmfyzw607y0qas9n-grub-efi-2.04/sbin/grub-install:
>   error:
>   /gnu/store/0az53wrhxvhpkm80pmfyzw607y0qas9n-grub-efi-2.04/lib/grub/i386-pc/modinfo.sh
>   doesn't exist. Please specify --target or --directory.
> ```
> 
> I found two existing guides, but one requires adding an extra block
> device and other shenanigans, and the other mentions some alarmingly
> outdated version numbers, so I don't trust either of them.

Hi, 

Having a similar experience about transforming a Debian droplet to Guix
on digitalocean, we provided a document for that. maybe that would also
helps you

https://wiki.pantherx.org/Installation-digital-ocean/

Regards
Reza

-- 
Reza Alizadeh Majd
PantherX Team
https://www.pantherx.org/


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Easy DigitalOcean setup?
  2020-11-09 23:02   ` Jérémy Korwin-Zmijowski
@ 2020-11-10 18:39     ` David Dashyan
  2020-11-10 18:47       ` Confusing typo (was: Easy DigitalOcean setup?) David Dashyan
  0 siblings, 1 reply; 7+ messages in thread
From: David Dashyan @ 2020-11-10 18:39 UTC (permalink / raw)
  To: Jérémy Korwin-Zmijowski; +Cc: help-guix, Joshua Branson

[-- Attachment #1: Type: text/plain, Size: 576 bytes --]


Hello raingloom!

I've recently mutated one of Digitalocean debian machines using method
provided by Reza in this thread I think there .  I would check
bootloader config -- I think you should have "/dev/vda" there.

By the way Jérémy!  Did It work for you with dhcp-client??? I thought
you need to use static networking.

I am asking because I've recently was automating droplets deployment by
quering digitalocean's metadata service to find out the network
configuration.

P.S. yggdrasil! That is an interesting piece of software!

-- 
David aka zzappie

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Confusing typo (was: Easy DigitalOcean setup?)
  2020-11-10 18:39     ` David Dashyan
@ 2020-11-10 18:47       ` David Dashyan
  2020-11-11 12:33         ` Efraim Flashner
  0 siblings, 1 reply; 7+ messages in thread
From: David Dashyan @ 2020-11-10 18:47 UTC (permalink / raw)
  To: David Dashyan; +Cc: help-guix, Joshua Branson


David Dashyan writes:

> I've recently mutated one of Digitalocean debian machines using method
> provided by Reza in this thread I think there .  I would check
> bootloader config -- I think you should have "/dev/vda" there.

Missed this typo, sorry… It should have been:

I've recently mutated one of Digitalocean debian machines using method
provided by Reza in this thread.  I would check bootloader config -- I
think you should have "/dev/vda" there.

-- 
David aka zzappie


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Confusing typo (was: Easy DigitalOcean setup?)
  2020-11-10 18:47       ` Confusing typo (was: Easy DigitalOcean setup?) David Dashyan
@ 2020-11-11 12:33         ` Efraim Flashner
  0 siblings, 0 replies; 7+ messages in thread
From: Efraim Flashner @ 2020-11-11 12:33 UTC (permalink / raw)
  To: David Dashyan; +Cc: help-guix, Joshua Branson

[-- Attachment #1: Type: text/plain, Size: 958 bytes --]

On Tue, Nov 10, 2020 at 09:47:00PM +0300, David Dashyan wrote:
> 
> David Dashyan writes:
> 
> > I've recently mutated one of Digitalocean debian machines using method
> > provided by Reza in this thread I think there .  I would check
> > bootloader config -- I think you should have "/dev/vda" there.
> 
> Missed this typo, sorry… It should have been:
> 
> I've recently mutated one of Digitalocean debian machines using method
> provided by Reza in this thread.  I would check bootloader config -- I
> think you should have "/dev/vda" there.
> 

Checking my Debian droplet:
(ins)efraim@E5400 ~$ ssh do1 lsblk
NAME   MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
vda    254:0    0  25G  0 disk
└─vda1 254:1    0  25G  0 part /


-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2020-11-11 12:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-09 22:28 Easy DigitalOcean setup? raingloom
2020-11-09 22:40 ` Joshua Branson
2020-11-09 23:02   ` Jérémy Korwin-Zmijowski
2020-11-10 18:39     ` David Dashyan
2020-11-10 18:47       ` Confusing typo (was: Easy DigitalOcean setup?) David Dashyan
2020-11-11 12:33         ` Efraim Flashner
2020-11-10  7:22 ` Easy DigitalOcean setup? Reza Alizadeh Majd

unofficial mirror of help-guix@gnu.org 

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://yhetil.org/guix-user/0 guix-user/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 guix-user guix-user/ https://yhetil.org/guix-user \
		help-guix@gnu.org
	public-inbox-index guix-user

Example config snippet for mirrors.
Newsgroups are available over NNTP:
	nntp://news.yhetil.org/yhetil.gnu.guix.user
	nntp://news.gmane.io/gmane.comp.gnu.guix.user


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git