cmake -B build -DGGML_CUDA=ON
cmake --build build --config Release -j20
cmake -B build -G Ninja -DGGML_HIP=ON -DAMDGPU_TARGETS=$(amdgpu-arch)
cmake --build build -j20 --config Release
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "context" | |
| "log" | |
| "net" | |
| "os" | |
| "path/filepath" | |
| "time" |
To provide persistent internet connectivity to libvirt virtual machines on a host system where Docker's firewall rules are active. This configuration resolves the conflict where Docker's FORWARD DROP policy blocks VM traffic.
The solution consists of two essential parts:
- Packet Forwarding: Creating high-priority firewall rules to explicitly allow traffic from the VM network (
virbr0) to pass through the host's firewall. - Network Address Translation (NAT): Enabling masquerading on the
libvirtfirewall zone so that the VM's private IP address is translated to the host's IP address for communication with the internet.
ffmpeg -i sounds.m4a -codec:a libmp3lame -b:a 320k output.mp3for m4a -> mp3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| sudo modprobe wireguard | |
| echo "wireguard" | sudo tee -a /etc/modules | |
| sudo modprobe iptable_nat | |
| echo "iptable_nat" | sudo tee -a /etc/modules | |
| sudo modprobe ip6table_nat | |
| echo "ip6table_nat" | sudo tee -a /etc/modules | |
| sudo modprobe iptable_filter | |
| echo "iptable_filter" | sudo tee -a /etc/modules |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| networks: | |
| monitoring: | |
| volumes: | |
| prometheus_data: {} | |
| services: | |
| node-exporter: | |
| image: prom/node-exporter:latest | |
| container_name: node-exporter |
docker run --rm -p 8080:8080 \
-e DataSources__EmissionsDataSource="WattTime" \
-e DataSources__ForecastDataSource="WattTime" \
-e DataSources__Configurations__WattTime__Type="WattTime" \
-e DataSources__Configurations__WattTime__username="" \
-e DataSources__Configurations__WattTime__password="" \
ghcr.io/green-software-foundation/carbon-aware-sdk
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| "sort" | |
| "strconv" | |
| "time" | |
| "github.com/go-git/go-git/v5" | |
| "github.com/go-git/go-git/v5/plumbing/object" |
Some of the important commands
git tag -s -a v1.3.1 -m "version v1.3.1 is out"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "context" | |
| "fmt" | |
| "log" | |
| "github.com/aws/aws-sdk-go-v2/config" | |
| "github.com/aws/aws-sdk-go-v2/service/eks" | |
| "github.com/aws/aws-sdk-go/aws" |
NewerOlder