Update 8 files
- /home/.chezmoiscripts/universal/run_onchange_before_05-install-homebrew.tmpl - /home/.chezmoiscripts/universal/run_onchange_before_09-ensure-node-version.tmpl - /home/.chezmoitemplates/universal/common-dependencies - /home/.chezmoiscripts/universal/run_onchange_before_09-node-version.tmpl - /home/.chezmoiscripts/universal/run_onchange_before_09-install-go.tmpl - /home/.chezmoiscripts/universal/run_onchange_before_11-install-docker.tmpl - /home/.chezmoiscripts/universal/run_onchange_before_91-configure-gpg.tmpl - /home/.chezmoiscripts/_universal/run_onchange_before_05-install-homebrew.tmpl
This commit is contained in:
parent
d1065b9114
commit
655009acb5
6 changed files with 32 additions and 3 deletions
|
@ -0,0 +1,22 @@
|
|||
{{- if (ne .host.distro.family "windows") -}}
|
||||
#!/usr/bin/env bash
|
||||
|
||||
{{ includeTemplate "universal/profile-before" }}
|
||||
{{ includeTemplate "universal/logg-before" }}
|
||||
|
||||
### Ensure Go is installed
|
||||
if ! command -v go > /dev/null; then
|
||||
if command -v brew; then
|
||||
logg 'Installing `go` via Homebrew'
|
||||
brew install go || GO_EXIT_CODE=$?
|
||||
if [ -n "$GO_EXIT_CODE" ]; then
|
||||
logg error '`go` was not successfully installed via Homebrew'
|
||||
fi
|
||||
else
|
||||
logg '`brew` is unavailable. Cannot use it to perform a system installation of node.'
|
||||
fi
|
||||
else
|
||||
logg '`go` is available'
|
||||
fi
|
||||
|
||||
{{ end -}}
|
|
@ -96,8 +96,12 @@ if [ ! -d /Applications ] || [ ! -d /System ]; then
|
|||
sudo git clone https://github.com/google/gvisor.git /usr/local/src/gvisor
|
||||
cd /usr/local/src/gvisor
|
||||
sudo mkdir -p bin
|
||||
sudo make copy TARGETS=runsc DESTINATION=bin/
|
||||
sudo cp ./bin/runsc /usr/local/bin
|
||||
# Wait 3 minutes for build to finish, and if it does not use Go
|
||||
sudo timeout 180 make copy TARGETS=runsc DESTINATION=bin/
|
||||
if [ -f ./bin/runsc ]; then
|
||||
sudo cp ./bin/runsc /usr/local/bin
|
||||
else
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ ! -f /etc/docker/daemon.json ]; then
|
||||
|
|
|
@ -9,7 +9,9 @@ if [ -n "$KEYID" ] && command -v gpg > /dev/null; then
|
|||
if [ ! -d "$HOME/.gnupg" ]; then
|
||||
mkdir "$HOME/.gnupg"
|
||||
fi
|
||||
chown -R "$(whoami)" "$HOME/.gnupg/"
|
||||
chown "$(whoami)" "$HOME/.gnupg"
|
||||
chmod 700 "$HOME/.gnupg"
|
||||
chown -Rf "$(whoami)" "$HOME/.gnupg/"
|
||||
find "$HOME/.gnupg" -type f -exec chmod 600 {} \;
|
||||
find "$HOME/.gnupg" -type d -exec chmod 700 {} \;
|
||||
if [ ! -f "$HOME/.gnupg/gpg.conf" ]; then
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
"curl"
|
||||
"expect"
|
||||
"git"
|
||||
"go"
|
||||
"grep"
|
||||
"gnupg2"
|
||||
"jq"
|
||||
|
|
Loading…
Reference in a new issue