Skip to content

Instantly share code, notes, and snippets.

@satoryu
Last active May 29, 2019 08:05
Show Gist options
  • Save satoryu/9dcfbde295c818686b84e75c6199959f to your computer and use it in GitHub Desktop.
Save satoryu/9dcfbde295c818686b84e75c6199959f to your computer and use it in GitHub Desktop.

Visual Studio Code Remote Development

Reference

Work log

Just Performed Remote Development Container - Open Directory:

Setting up container for folder: /Users/tatsuya.b.sato/Projects/private/vscode-remote-try-node
Run: docker build -f /Users/tatsuya.b.sato/Projects/private/vscode-remote-try-node/.devcontainer/Dockerfile -t vsc-vscode-remote-try-node-f5e8e3ca5ecca6760b6ed5ef9750b38c /Users/tatsuya.b.sato/Projects/private/vscode-remote-try-node/.devcontainer
Sending build context to Docker daemon  4.096kB
Step 1/9 : FROM node:10
10: Pulling from library/node
c5e155d5a1d1: Downloading [>                                                  ]  457.4kB/45.34MBlling fs layer
4250b3117dca: Pulling fs layer
221d80d00ae9: Downloading [>                                                  ] c5e155d5a1d1: Downloading [=>                                                 ]  924.3kB/45.34MBwnloading [=>                                                 ] c5e155d5a1d1: Pull complete 221d80d00ae9: Pull complete 4250b3117dca: Pull complete 3b7ca19181b2: Pull complete 425d7b2a5bcc: Pull complete 69df12c70287: Pull complete ad53476a61f2: Pull complete 204bb8bac4a1: Pull complete Digest: sha256:c5e919a89352d3ce6a883dde54a5d51dde12229c2d11088593cd1f3efefcc16e
Status: Downloaded newer image for node:10
---> 5a401340b79f
Step 2/9 : ENV DEBIAN_FRONTEND=noninteractive
---> Running in 63df763b9f57
Removing intermediate container 63df763b9f57
---> c0c2f08eb98a
Step 3/9 : RUN apt-get update    && apt-get -y install --no-install-recommends apt-utils 2>&1
---> Running in 6ff82446c6d8
Ign:1 http://deb.debian.org/debian stretch InRelease
Get:2 http://security.debian.org/debian-security stretch/updates InRelease [94.3 kB]
Get:3 http://deb.debian.org/debian stretch-updates InRelease [91.0 kB]
Get:4 http://deb.debian.org/debian stretch Release [118 kB]
Get:5 http://deb.debian.org/debian stretch Release.gpg [2434 B]
Get:6 http://security.debian.org/debian-security stretch/updates/main amd64 Packages [492 kB]
Get:7 http://deb.debian.org/debian stretch-updates/main amd64 Packages [27.2 kB]
Get:8 http://deb.debian.org/debian stretch/main amd64 Packages [7082 kB]
Fetched 7907 kB in 2s (2714 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
  libapt-inst2.0
The following NEW packages will be installed:
  apt-utils libapt-inst2.0
0 upgraded, 2 newly installed, 0 to remove and 3 not upgraded.
Need to get 602 kB of archives.
After this operation, 1607 kB of additional disk space will be used.
Get:1 http://deb.debian.org/debian stretch/main amd64 libapt-inst2.0 amd64 1.4.9 [192 kB]
Get:2 http://deb.debian.org/debian stretch/main amd64 apt-utils amd64 1.4.9 [410 kB]
debconf: delaying package configuration, since apt-utils is not installed
Fetched 602 kB in 0s (4071 kB/s)
Selecting previously unselected package libapt-inst2.0:amd64.
(Reading database ... 29980 files and directories currently installed.)
Preparing to unpack .../libapt-inst2.0_1.4.9_amd64.deb ...
Unpacking libapt-inst2.0:amd64 (1.4.9) ...
Selecting previously unselected package apt-utils.
Preparing to unpack .../apt-utils_1.4.9_amd64.deb ...
Unpacking apt-utils (1.4.9) ...
Setting up libapt-inst2.0:amd64 (1.4.9) ...
Setting up apt-utils (1.4.9) ...
Processing triggers for libc-bin (2.24-11+deb9u4) ...
Removing intermediate container 6ff82446c6d8
---> cd8ac159de06
Step 4/9 : RUN apt-get install -y git procps
---> Running in 7d8cb314e1bc
Reading package lists...
Building dependency tree...
Reading state information...
git is already the newest version (1:2.11.0-3+deb9u4).
procps is already the newest version (2:3.3.12-3+deb9u1).
0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
Removing intermediate container 7d8cb314e1bc
---> 1f1135711642
Step 5/9 : RUN rm -rf /opt/yarn-*     && rm -f /usr/local/bin/yarn     && rm -f /usr/local/bin/yarnpkg     && apt-get install -y curl apt-transport-https lsb-release     && curl -sS https://dl.yarnpkg.com/$(lsb_release -is | tr '[:upper:]' '[:lower:]')/pubkey.gpg | apt-key add - 2>/dev/null     && echo "deb https://dl.yarnpkg.com/$(lsb_release -is | tr '[:upper:]' '[:lower:]')/ stable main" | tee /etc/apt/sources.list.d/yarn.list     && apt-get update     && apt-get -y install --no-install-recommends yarn
---> Running in bfa4be5dd6f8
Reading package lists...
Building dependency tree...
Reading state information...
curl is already the newest version (7.52.1-5+deb9u9).
Suggested packages:
  lsb
The following NEW packages will be installed:
  apt-transport-https distro-info-data lsb-release
0 upgraded, 3 newly installed, 0 to remove and 3 not upgraded.
Need to get 204 kB of archives.
After this operation, 322 kB of additional disk space will be used.
Get:1 http://deb.debian.org/debian stretch/main amd64 apt-transport-https amd64 1.4.9 [171 kB]
Get:2 http://deb.debian.org/debian stretch/main amd64 distro-info-data all 0.36 [5810 B]
Get:3 http://deb.debian.org/debian stretch/main amd64 lsb-release all 9.20161125 [27.1 kB]
Fetched 204 kB in 0s (2231 kB/s)
Selecting previously unselected package apt-transport-https.
(Reading database ... 30111 files and directories currently installed.)
Preparing to unpack .../apt-transport-https_1.4.9_amd64.deb ...
Unpacking apt-transport-https (1.4.9) ...
Selecting previously unselected package distro-info-data.
Preparing to unpack .../distro-info-data_0.36_all.deb ...
Unpacking distro-info-data (0.36) ...
Selecting previously unselected package lsb-release.
Preparing to unpack .../lsb-release_9.20161125_all.deb ...
Unpacking lsb-release (9.20161125) ...
Setting up apt-transport-https (1.4.9) ...
Setting up distro-info-data (0.36) ...
Setting up lsb-release (9.20161125) ...
OK
deb https://dl.yarnpkg.com/debian/ stable main
Hit:1 http://security.debian.org/debian-security stretch/updates InRelease
Ign:2 http://deb.debian.org/debian stretch InRelease
Hit:3 http://deb.debian.org/debian stretch-updates InRelease
Hit:4 http://deb.debian.org/debian stretch Release
Get:5 https://dl.yarnpkg.com/debian stable InRelease [13.3 kB]
Get:7 https://dl.yarnpkg.com/debian stable/main all Packages [8706 B]
Get:8 https://dl.yarnpkg.com/debian stable/main amd64 Packages [8706 B]
Fetched 30.7 kB in 0s (49.9 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
Recommended packages:
  nodejs
The following NEW packages will be installed:
  yarn
0 upgraded, 1 newly installed, 0 to remove and 3 not upgraded.
Need to get 837 kB of archives.
After this operation, 5001 kB of additional disk space will be used.
Get:1 https://dl.yarnpkg.com/debian stable/main amd64 yarn all 1.16.0-1 [837 kB]
Fetched 837 kB in 0s (2950 kB/s)
Selecting previously unselected package yarn.
(Reading database ... 30135 files and directories currently installed.)
Preparing to unpack .../archives/yarn_1.16.0-1_all.deb ...
Unpacking yarn (1.16.0-1) ...
Setting up yarn (1.16.0-1) ...
Removing intermediate container bfa4be5dd6f8
---> 0e4c723947e8
Step 6/9 : RUN npm install -g eslint
---> Running in 0cefe5f05696
/usr/local/bin/eslint -> /usr/local/lib/node_modules/eslint/bin/eslint.js
+ eslint@5.16.0
added 117 packages from 70 contributors in 8.21s
Removing intermediate container 0cefe5f05696
---> 51817ac0a6b7
Step 7/9 : RUN apt-get autoremove -y     && apt-get clean -y     && rm -rf /var/lib/apt/lists/*
---> Running in aa3b6ce05141
Reading package lists...
Building dependency tree...
Reading state information...
0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
Removing intermediate container aa3b6ce05141
---> 951d5b2a40e9
Step 8/9 : ENV DEBIAN_FRONTEND=dialog
---> Running in e7d169e31fb9
Removing intermediate container e7d169e31fb9
---> 3d5053f7d0fc
Step 9/9 : ENV SHELL /bin/bash
---> Running in 81ca3a913913
Removing intermediate container 81ca3a913913
---> b1f06072d438
Successfully built b1f06072d438
Successfully tagged vsc-vscode-remote-try-node-f5e8e3ca5ecca6760b6ed5ef9750b38c:latest
Run: docker run -a STDOUT -a STDERR -p 127.0.0.1:3000:3000 --mount type=bind,source=/Users/tatsuya.b.sato/Projects/private/vscode-remote-try-node,target=/workspaces/vscode-remote-try-node -v /Users/tatsuya.b.sato/.gitconfig:/root/.gitconfig -l vsch.quality=insider -l vsch.local.folder=/Users/tatsuya.b.sato/Projects/private/vscode-remote-try-node -l vsch.remote.devPort=9753 vsc-vscode-remote-try-node-f5e8e3ca5ecca6760b6ed5ef9750b38c /bin/sh -c echo Container started ;  while sleep 1; do :; done
Container started
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 test -d /root/.vscode-server-insiders
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 test -d /root/.vscode-remote
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 /bin/sh -c set -o noclobber ; mkdir -p '/root/.vscode-server-insiders/data/Machine' && { > '/root/.vscode-server-insiders/data/Machine/.writeMachineSettingsMarker' ; } 2> /dev/null
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 /bin/sh -c (cat /etc/os-release || cat /usr/lib/os-release) 2>/dev/null
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 test -d /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5
Installing VS Code Server for commit a429fd13565d3392c87e31228ec9e8a2bf3708d5
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 mkdir -p /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5_1559095374738
Run: docker cp /var/folders/_l/9yzlbg193032kq9tqz206j4j_d7vyd/T/vsch/a429fd13565d3392c87e31228ec9e8a2bf3708d5/vscode-server-linux-x64.tar.gz f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066:/root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5_1559095374738
Run: docker exec -w /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5_1559095374738 f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 tar --no-same-owner -xf vscode-server-linux-x64.tar.gz --strip-components 1
Run: docker exec -w /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5_1559095374738 f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 rm vscode-server-linux-x64.tar.gz
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 mv -n /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5_1559095374738 /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 test -d /root/.vscode-server-insiders/extensions
Run: docker exec -w /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5 -e VSCODE_AGENT_FOLDER=/root/.vscode-server-insiders f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5/server.sh  --install-extension dbaeumer.vscode-eslint --force
Remote configuration data at /root/.vscode-server-insiders
Installing extensions...
Installing extension 'dbaeumer.vscode-eslint' v1.9.0...
Extension 'dbaeumer.vscode-eslint' v1.9.0 was successfully installed.
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 /bin/sh -c set -o noclobber ; mkdir -p '/root/.vscode-server-insiders/data/Machine' && { > '/root/.vscode-server-insiders/data/Machine/.postCreateCommandMarker' ; } 2> /dev/null
Run: docker exec f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 test -f /root/.vscode-server-insiders/.postCreateCommandMarker
Run: docker exec -w /workspaces/vscode-remote-try-node f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 /bin/sh -c yarn install
yarn install v1.16.0
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
Done in 3.44s.
Run: docker exec -w /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5 -u 0 f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 /bin/sh -c command -v git >/dev/null 2>&1 && git config --system credential.helper '!f() { command -v code-insiders >/dev/null 2>&1 && code-insiders --gitCredential $*; }; f' || true
Run: docker exec -w /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5 f124d2d75059395955703ab3c645db06dbfa514f36a1a533d65c0cff19579066 /bin/sh -c PATH="/root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5/bin:$PATH" VSCODE_AGENT_FOLDER='/root/.vscode-server-insiders' /root/.vscode-server-insiders/bin/a429fd13565d3392c87e31228ec9e8a2bf3708d5/server.sh  --port 9753
Remote configuration data at /root/.vscode-server-insiders


*
* Visual Studio Code Server
*
* Reminder: You may only use this software with Visual Studio family products,
* as described in the license https://aka.ms/vscode-remote/license
*


IP Address: 172.17.0.2
Extension host agent listening on 9753


--------------------------
Published Ports:
3000/tcp -> 127.0.0.1:3000
--------------------------

==> Received a management connection
==> Received an extension host connection.
==> Using UI language: en
bash: cannot set terminal process group (-1): Inappropriate ioctl for device
bash: no job control in this shell
mesg: ttyname failed: Inappropriate ioctl for device
==> Received a management connection
==> Received a management connection
  • found /root/.vscode-server-insiders/
    • includes some codes in node.js.
  • ❓ Questions
    • when installed?
    • what dependencies required for running the server ?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment