IdeaPad duet으로 개발 환경을 조성

IdeaPad duet은 좋다.



평소 메인 머신으로 Macbook Pro 13 인치를 사용하고 있지만, 가지고 다니기에는 조금 무겁기 때문에 서브 기계를 원한다고 생각했던 곳에서 발견한 이쪽의 상품
Chromebook은 지금까지 사용한 적이 없었지만 Linux 환경을 사용할 수 있다는 점에서 구입했습니다.



주제



모처럼 Linux를 사용할 수 있기 때문에 약간의 개발 환경을 정돈했다
굳이 로그도 남기 때문에 잘 안되는 사람은 참고로 해 주세요
$ uname -a
Linux penguin 5.4.40-04224-g891a6cce2d44 #1 SMP PREEMPT Tue Jun 23 20:13:49 PDT 2020 aarch64 GNU/Linux

위의 결과를 보면 알 수 있듯이 CPU 아키텍처가 x86이 아닌 ARM입니다.

AWS CLI v2



참고: AWS CLI v2 now available for Linux ARM

$ curl -O 'https://awscli.amazonaws.com/awscli-exe-linux-aarch64.zip'
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 28.7M  100 28.7M    0     0  3687k      0  0:00:07  0:00:07 --:--:-- 3914k

$ unzip awscli-exe-linux-aarch64.zip
# 結果は省略

$ sudo ./aws/install
You can now run: /usr/local/bin/aws --version

$ aws --version
aws-cli/2.0.45 Python/3.7.3 Linux/5.4.40-04224-g891a6cce2d44 exe/aarch64.debian.10

Google Cloud SDK



참고: Google Cloud SDK for ARM architecture

$ sudo apt -y update && sudo apt -y upgrade 
Get:1 https://deb.debian.org/debian buster InRelease [122 kB]
Get:2 https://deb.debian.org/debian-security buster/updates InRelease [65.4 kB]
Ign:3 https://storage.googleapis.com/cros-packages/84 buster InRelease
Get:4 https://storage.googleapis.com/cros-packages/84 buster Release [3,119 B]
Get:5 https://storage.googleapis.com/cros-packages/84 buster Release.gpg [819 B]
Get:6 https://deb.debian.org/debian buster/main arm64 Packages [7,736 kB]
Get:7 https://storage.googleapis.com/cros-packages/84 buster/main arm64 Packages [16.1 kB]
Get:8 https://deb.debian.org/debian buster/main Translation-en [5,968 kB]
Get:9 https://deb.debian.org/debian-security buster/updates/main arm64 Packages [219 kB]                                                              
Get:10 https://deb.debian.org/debian-security buster/updates/main Translation-en [122 kB]                                                             
Fetched 14.3 MB in 12s (1,217 kB/s)                                                                                                                   
Reading package lists... Done
Building dependency tree       
Reading state information... Done
30 packages can be upgraded. Run 'apt list --upgradable' to see them.
N: Repository 'https://deb.debian.org/debian buster InRelease' changed its 'Version' value from '10.4' to '10.5'
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages will be upgraded:

$ sudo apt-get update && sudo apt-get install google-cloud-sdk
Hit:1 https://deb.debian.org/debian buster InRelease
Hit:2 https://deb.debian.org/debian-security buster/updates InRelease
Ign:3 https://storage.googleapis.com/cros-packages/84 buster InRelease
Get:4 https://packages.cloud.google.com/apt cloud-sdk InRelease [6,349 B]
Hit:5 https://storage.googleapis.com/cros-packages/84 buster Release
Get:6 https://packages.cloud.google.com/apt cloud-sdk/main arm64 Packages [76.3 kB]
Fetched 82.7 kB in 3s (32.8 kB/s) 
Reading package lists... Done
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  python3-crcmod
Suggested packages:
  google-cloud-sdk-app-engine-java google-cloud-sdk-app-engine-python google-cloud-sdk-pubsub-emulator google-cloud-sdk-bigtable-emulator
  google-cloud-sdk-datastore-emulator kubectl
The following NEW packages will be installed:
  google-cloud-sdk python3-crcmod
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 69.9 MB of archives.
After this operation, 399 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 https://packages.cloud.google.com/apt cloud-sdk/main arm64 google-cloud-sdk all 308.0.0-0 [69.9 MB]
Get:2 https://deb.debian.org/debian buster/main arm64 python3-crcmod arm64 1.7+dfsg-1+b1 [19.0 kB]
Fetched 69.9 MB in 16s (4,339 kB/s)                                                                                                                   
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package python3-crcmod.
(Reading database ... 33282 files and directories currently installed.)
Preparing to unpack .../python3-crcmod_1.7+dfsg-1+b1_arm64.deb ...
Unpacking python3-crcmod (1.7+dfsg-1+b1) ...
Selecting previously unselected package google-cloud-sdk.
Preparing to unpack .../google-cloud-sdk_308.0.0-0_all.deb ...
Unpacking google-cloud-sdk (308.0.0-0) ...
Setting up python3-crcmod (1.7+dfsg-1+b1) ...
Setting up google-cloud-sdk (308.0.0-0) ...
Processing triggers for man-db (2.8.5-2) ...

$ gcloud --version
Google Cloud SDK 308.0.0
alpha 2020.08.28
beta 2020.08.28
bq 2.0.60
core 2020.08.28
gsutil 4.53
kubectl 1.15.11

VSCode



불행히도 VSCode는 공식적으로 ARM을 지원하지 않으므로 커뮤니티 빌드 버전을 사용해야합니다.

Visual Studio Code for Chromebooks and Raspberry Pi


이 페이지의 the Releases page 링크에서 GitHub까지 날 수 있습니다.

현재 (2020/09/02)에서는 30-Mar-20가 최신 릴리스이지만 20-Jan-20을 Linux 폴더에 다운로드

처음에는 30-Mar-20를 설치해 보았지만 VSCode 플러그인을 넣지 못했습니다.
TypeScript 오류가 있었기 때문에 포기했습니다.



이 페이지의 다음 페이지 code-oss_1.42.0-1579483079_arm64.deb
다운로드 한 파일 .deb 파일을 두 번 클릭하여 실행하면 설치가 완료됩니다.

$ code-oss --version
1.42.0
e107e5c5bf3e22dc63884aa11a410d33f96daad2
arm64

Golang



릴리스 페이지에서 ARM용 다운로드 링크 받기

Downloads - The Go Programming Language



이번에는이 중에서 ArchARMv8go1.15.1.linux-arm64.tar.gz를 사용합니다.

$  wget https://golang.org/dl/go1.15.1.linux-arm64.tar.gz
--2020-09-02 22:17:04--  https://golang.org/dl/go1.15.1.linux-arm64.tar.gz
Resolving golang.org (golang.org)... 172.217.161.241, 2404:6800:400a:806::2011
Connecting to golang.org (golang.org)|172.217.161.241|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://dl.google.com/go/go1.15.1.linux-arm64.tar.gz [following]
--2020-09-02 22:17:06--  https://dl.google.com/go/go1.15.1.linux-arm64.tar.gz
Resolving dl.google.com (dl.google.com)... 172.217.26.110, 2404:6800:400a:807::200e
Connecting to dl.google.com (dl.google.com)|172.217.26.110|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 97722202 (93M) [application/octet-stream]
Saving to: ‘go1.15.1.linux-arm64.tar.gz’

go1.15.1.linux-arm64.tar.gz           100%[========================================================================>]  93.19M  3.26MB/s    in 24s     

2020-09-02 22:17:30 (3.93 MB/s) - ‘go1.15.1.linux-arm64.tar.gz’ saved [97722202/97722202]

$ sudo tar -C /usr/local/ -zxf go1.15.1.linux-arm64.tar.gz 

$ /usr/local/go/bin/go version
go version go1.15.1 linux/arm64

PATH가 통과하지 않았기 때문에 ~/.bashrc에 추가하고 쉘을 다시 시작합니다.

$ cat .bashrc | grep PATH
export PATH=$PATH:/usr/local/go/bin

$ exec $SHELL -l 

$ go version
go version go1.15.1 linux/arm64

좋은 웹페이지 즐겨찾기