macOS fixes

This commit is contained in:
Brian Zalewski 2023-08-30 17:01:07 -04:00 committed by GitHub
parent 495a8babd2
commit fcb03102ec
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 26 additions and 22 deletions

View file

@ -5,6 +5,7 @@ Create issue about setting up completions - https://github.com/rsteube/lazycompl
This page outlines various projects and tasks that we are currently working on. Creating a GitHub issue for each of these items would be overkill. This page outlines various projects and tasks that we are currently working on. Creating a GitHub issue for each of these items would be overkill.
- Integrate Sheldon
- Add Mamba - Add Mamba
- https://containertoolbx.org/install/ - https://containertoolbx.org/install/
- https://github.com/todotxt/todo.txt-cli - https://github.com/todotxt/todo.txt-cli

View file

@ -287,7 +287,6 @@ softwareGroups:
- goto - goto
- gping - gping
- gum - gum
- hishtory
- hoard - hoard
- htmlq # htmlq is used by the the Firefox script - htmlq # htmlq is used by the the Firefox script
- hyperfine - hyperfine
@ -1549,6 +1548,8 @@ softwareGroups:
note: Might only be needed in headless scenarios since Android Studio will download the tools note: Might only be needed in headless scenarios since Android Studio will download the tools
- pkg: editly - pkg: editly
note: Editly NPM package is failing to install on macOS. Attempts to compile with node-gyp and fails. note: Editly NPM package is failing to install on macOS. Attempts to compile with node-gyp and fails.
- pkg: hishtory
note: Erroring out - waiting on an alternate installation method like Homebrew to be released
- pkg: metasploit - pkg: metasploit
note: Determine whether or not this will be flagged by management settings note: Determine whether or not this will be flagged by management settings
- pkg: rancher-desktop - pkg: rancher-desktop

View file

@ -53,10 +53,10 @@ if command -v rclone > /dev/null; then
{{- if and (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID"))) (env "CLOUDFLARE_R2_ID")) (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET"))) (env "CLOUDFLARE_R2_SECRET")) (ne .user.cloudflare.r2 "") }} {{- if and (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID"))) (env "CLOUDFLARE_R2_ID")) (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET"))) (env "CLOUDFLARE_R2_SECRET")) (ne .user.cloudflare.r2 "") }}
logg info 'Removing ~/.config/rclone/rclone.conf INSTALL DOCTOR managed block' logg info 'Removing ~/.config/rclone/rclone.conf INSTALL DOCTOR managed block'
CONFIG_FILE="${XDG_CONFIG_HOME:-$HOME/.config}/rclone/rclone.conf" CONFIG_FILE="${XDG_CONFIG_HOME:-$HOME/.config}/rclone/rclone.conf"
if cat "$CONFIG_FILE" | grep '# INSTALL DOCTOR MANAGED S3'; then if cat "$CONFIG_FILE" | grep '# INSTALL DOCTOR MANAGED S3 START'; then
# TODO: Remove old block # TODO: Remove old block
START_LINE="$(echo `grep -n -m 1 "# INSTALL DOCTOR MANAGED S3" "$CONFIG_FILE" | cut -f1 -d ":"`)" START_LINE="$(echo `grep -n -m 1 "# INSTALL DOCTOR MANAGED S3 START" "$CONFIG_FILE" | cut -f1 -d ":"`)"
END_LINE="$(echo `grep -n -m 1 "# INSTALL DOCTOR MANAGED S3" "$CONFIG_FILE" | cut -f1 -d ":"`)" END_LINE="$(echo `grep -n -m 1 "# INSTALL DOCTOR MANAGED S3 END" "$CONFIG_FILE" | cut -f1 -d ":"`)"
if command -v gsed > /dev/null; then if command -v gsed > /dev/null; then
gsed -i "$START_LINE,$END_LINEd" "$CONFIG_FILE" gsed -i "$START_LINE,$END_LINEd" "$CONFIG_FILE"
else else
@ -65,7 +65,7 @@ if command -v rclone > /dev/null; then
fi fi
logg info 'Adding ~/.config/rclone/rclone.conf INSTALL DOCTOR managed block' logg info 'Adding ~/.config/rclone/rclone.conf INSTALL DOCTOR managed block'
tee -a "$CONFIG_FILE" > /dev/null <<EOT tee -a "$CONFIG_FILE" > /dev/null <<EOT
# INSTALL DOCTOR MANAGED S3 # INSTALL DOCTOR MANAGED S3 START
[{{ .user.username}}-s3] [{{ .user.username}}-s3]
access_key_id = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_ID" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_ID" -}}{{ end }} access_key_id = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_ID" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_ID" -}}{{ end }}
acl = private acl = private
@ -74,7 +74,7 @@ provider = Cloudflare
region = auto region = auto
secret_access_key = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_SECRET" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_SECRET" -}}{{ end }} secret_access_key = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_SECRET" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_SECRET" -}}{{ end }}
type = s3 type = s3
# INSTALL DOCTOR MANAGED S3 # INSTALL DOCTOR MANAGED S3 END
EOT EOT
{{- end }} {{- end }}

View file

@ -1,5 +1,5 @@
{{- if and (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID"))) (env "CLOUDFLARE_R2_ID")) (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET"))) (env "CLOUDFLARE_R2_SECRET")) (ne .user.cloudflare.r2 "") -}} {{- if and (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID"))) (env "CLOUDFLARE_R2_ID")) (or (and (stat (joinPath .host.home ".config" "age" "chezmoi.txt")) (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET"))) (env "CLOUDFLARE_R2_SECRET")) (ne .user.cloudflare.r2 "") -}}
# INSTALL DOCTOR MANAGED S3 # INSTALL DOCTOR MANAGED S3 START
[{{ .user.username}}-s3] [{{ .user.username}}-s3]
access_key_id = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_ID" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_ID" -}}{{ end }} access_key_id = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_ID")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_ID" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_ID" -}}{{ end }}
acl = private acl = private
@ -8,5 +8,5 @@ provider = Cloudflare
region = auto region = auto
secret_access_key = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_SECRET" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_SECRET" -}}{{ end }} secret_access_key = {{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "CLOUDFLARE_R2_SECRET")) }}{{- includeTemplate "secrets/CLOUDFLARE_R2_SECRET" | decrypt | trim -}}{{ else }}{{- env "CLOUDFLARE_R2_SECRET" -}}{{ end }}
type = s3 type = s3
# INSTALL DOCTOR MANAGED S3 # INSTALL DOCTOR MANAGED S3 END
{{- end -}} {{- end -}}

View file

@ -215,6 +215,7 @@ print_banner() {
else else
if command -v neofetch > /dev/null; then if command -v neofetch > /dev/null; then
neofetch neofetch
exit 0
fi fi
fi fi

View file

@ -167,7 +167,7 @@ async function generateInstallOrders(pkgsToInstall) {
packageKey = pkg packageKey = pkg
} else { } else {
log('warn', logStage, `The package \`${pkg}\` was not found in the installation map`) log('warn', logStage, `The package \`${pkg}\` was not found in the installation map`)
console.log('softwarePackages:', softwarePackages) process.env.DEBUG === 'true' && console.log('softwarePackages:', softwarePackages)
console.log('pkg:', pkg) console.log('pkg:', pkg)
continue continue
} }

View file

@ -5,6 +5,15 @@ TYPE="$1"
USER="$2" USER="$2"
MOUNT="$3" MOUNT="$3"
### Mount variables
if [ "$TYPE" = 'user' ]; then
MOUNT_REF="$USER-$MOUNT"
MOUNT_LOWERCASE="user/$USER-$MOUNT"
else
MOUNT_REF="$MOUNT"
MOUNT_LOWERCASE="$(echo "$MOUNT" | tr "[:upper:]" "[:lower:]")"
fi
### Path definitions ### Path definitions
if [ "$TYPE" = 'user' ]; then if [ "$TYPE" = 'user' ]; then
if [ -d /Applications ] && [ -d /System ]; then if [ -d /Applications ] && [ -d /System ]; then
@ -46,13 +55,6 @@ if [ ! -f "$RCLONE_IGNORE" ] && [ -f "/etc/rcloneignore" ]; then
fi fi
### Mount ### Mount
if [ "$TYPE" == 'user' ]; then
MOUNT_REF="$USER-$MOUNT"
MOUNT_LOWERCASE="user/$USER-$MOUNT"
else
MOUNT_REF="$MOUNT"
MOUNT_LOWERCASE="$(echo "$MOUNT" | tr "[:upper:]" "[:lower:]")"
fi
unset AWS_CA_BUNDLE unset AWS_CA_BUNDLE
export PATH="$PATH:/usr/local/bin:/usr/bin" export PATH="$PATH:/usr/local/bin:/usr/bin"
# TODO: Only launch with --rc-web-gui if the servers hostname is the {{ .kubernetesHost }} # TODO: Only launch with --rc-web-gui if the servers hostname is the {{ .kubernetesHost }}
@ -79,9 +81,6 @@ sudo rclone --config "$CONFIG_FOLDER/rclone.conf" \
--no-modtime \ --no-modtime \
--noapplexattr \ --noapplexattr \
--poll-interval 15s \ --poll-interval 15s \
--rc \
--rc-pass rclone \
--rc-user rclone \
--stats 0 \ --stats 0 \
--vfs-cache-max-age 1000h \ --vfs-cache-max-age 1000h \
--vfs-cache-max-size 140G \ --vfs-cache-max-size 140G \

View file

@ -2896,7 +2896,9 @@ softwarePackages:
_bin: mongod _bin: mongod
_github: https://github.com/mongodb/mongo _github: https://github.com/mongodb/mongo
_name: MongoDB _name: MongoDB
brew: mongodb/brew/mongodb _service: mongodb
_service:brew: mongodb/brew/mongodb-community
brew: mongodb/brew/mongodb-community
choco: mongodb choco: mongodb
mongodb-compass: mongodb-compass:
_bin: mongodb-compass _bin: mongodb-compass
@ -4898,7 +4900,7 @@ softwarePackages:
_github: https://github.com/ddworken/hishtory _github: https://github.com/ddworken/hishtory
_name: hiSHtory _name: hiSHtory
_todo: Check for Homebrew version _todo: Check for Homebrew version
_post: source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/private.sh" && echo y | hishtory init "$HISHTORY_USER_SECRET" _post: source source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/private.sh" && echo y | hishtory init "$HISHTORY_USER_SECRET"
script: curl -sSL --compressed https://hishtory.dev/install.py | python3 - script: curl -sSL --compressed https://hishtory.dev/install.py | python3 -
git-town: git-town:
_bin: git-town _bin: git-town
@ -6771,7 +6773,7 @@ softwarePackages:
_github: https://github.com/coder/coder _github: https://github.com/coder/coder
_home: https://coder.com/ _home: https://coder.com/
_name: Coder _name: Coder
brew: cdr/coder/coder-cli brew: coder
pulumi: pulumi:
_bin: pulumi _bin: pulumi
_desc: Pulumi - Infrastructure as Code in any programming language. Build infrastructure intuitively on any cloud using familiar languages _desc: Pulumi - Infrastructure as Code in any programming language. Build infrastructure intuitively on any cloud using familiar languages