diff --git a/README.md b/README.md index f88607b..e9e34ba 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ Many more companies are using Tart in their internal setups. Here are a few of t Try running a Tart VM on your Apple Silicon device running macOS 12.0 (Monterey) or later (will download a 25 GB image): -```shell +```bash brew install cirruslabs/cli/tart tart clone ghcr.io/cirruslabs/macos-ventura-base:latest ventura-base tart run ventura-base @@ -77,7 +77,7 @@ for remaining questions. You can choose disk size upon creation of a virtual machine: - ```shell + ```bash tart create --from-ipsw=latest --disk-size=25 monterey-vanilla ``` @@ -104,7 +104,7 @@ for remaining questions. To change the default network to `192.168.77.1`: - ```shell + ```bash sudo defaults write /Library/Preferences/SystemConfiguration/com.apple.vmnet.plist Shared_Net_Address -string 192.168.77.1 ``` @@ -112,7 +112,7 @@ for remaining questions. The default subnet mask `255.255.255.0` should suffice for most use-cases, however, you can also change it to `255.255.0.0`, for example: - ```shell + ```bash sudo defaults write /Library/Preferences/SystemConfiguration/com.apple.vmnet.plist Shared_Net_Mask -string 255.255.0.0 ``` diff --git a/docs/cirrus-cli.md b/docs/cirrus-cli.md index a23c239..f9830cf 100644 --- a/docs/cirrus-cli.md +++ b/docs/cirrus-cli.md @@ -28,7 +28,7 @@ task: Put the above `.cirrus.yml` file in the root of your repository and run it with the following command: -```shell +```bash brew install cirruslabs/cli/cirrus cirrus run ``` @@ -58,7 +58,7 @@ task: Running Cirrus CLI with `--artifacts-dir` will write defined `artifacts` to the provided local directory on the host: -```shell +```bash cirrus run --artifacts-dir artifacts ``` diff --git a/docs/quick-start.md b/docs/quick-start.md index cff9edd..0dfeb16 100644 --- a/docs/quick-start.md +++ b/docs/quick-start.md @@ -5,7 +5,7 @@ hide: Try running a Tart VM on your Apple Silicon device running macOS 12.0 (Monterey) or later (will download a 25 GB image): -```shell +```bash brew install cirruslabs/cli/tart tart clone ghcr.io/cirruslabs/macos-ventura-base:latest ventura-base tart run ventura-base @@ -19,7 +19,7 @@ tart run ventura-base If the guest VM is running and configured to accept incoming SSH connections you can conveniently connect to it like so: -```shell +```bash ssh admin@$(tart ip macos-monterey-base) ``` @@ -27,7 +27,7 @@ ssh admin@$(tart ip macos-monterey-base) To mount a directory, run the VM with the `--dir` argument: -```shell +```bash tart run --dir=project:~/src/project vm ``` @@ -35,13 +35,13 @@ Here, the `project` specifies a mount name, whereas the `~/src/project` is a pat It is also possible to mount directories in read-only mode by adding a third parameter, `ro`: -```shell +```bash tart run --dir=project:~/src/project:ro vm ``` To mount multiple directories, repeat the `--dir` argument for each directory: -```shell +```bash tart run --dir=www1:~/project1/www --dir=www2:~/project2/www ``` @@ -61,7 +61,7 @@ Note: to use the directory mounting feature, the guest VM needs to run macOS 13. To be able to access the shared directories from the Linux guest, you need to manually mount the virtual filesystem first: -```shell +```bash mount -t virtiofs com.apple.virtio-fs.automount /mnt/shared ``` diff --git a/docs/vm-management.md b/docs/vm-management.md index 4cfec3a..4c2479a 100644 --- a/docs/vm-management.md +++ b/docs/vm-management.md @@ -15,7 +15,7 @@ The only difference is how such VM images are created. Please check sections bel Tart can create VMs from `*.ipsw` files. You can download a specific `*.ipsw` file [here](https://ipsw.me/) or you can use `latest` instead of a path to `*.ipsw` to download the latest available version: -```shell +```bash tart create --from-ipsw=latest monterey-vanilla tart run monterey-vanilla ``` @@ -32,7 +32,7 @@ After the initial booting of the VM you'll need to manually go through the macOS Linux VMs are supported on hosts running macOS 13.0 (Ventura) or newer. -```shell +```bash # Create a bare VM tart create --linux ubuntu @@ -45,7 +45,7 @@ tart run ubuntu After the initial setup please make sure your VM can be SSH-ed into by running the following commands inside your VM: -```shell +```bash sudo apt update sudo apt install -y openssh-server sudo ufw allow ssh @@ -103,7 +103,7 @@ For example, let's say you want to push/pull images to a registry hosted at http First, you need to log in and save credential for `acme.io` host via `tart login` command: -```shell +```bash tart login acme.io ``` @@ -119,7 +119,7 @@ for all registries which might useful for integrating with your CI's secret mana Once credentials are saved for `acme.io`, run the following command to push a local images remotely with two tags: -```shell +```bash tart push my-local-vm-name acme.io/remoteorg/name:latest acme.io/remoteorg/name:v1.0.0 ``` @@ -127,13 +127,13 @@ tart push my-local-vm-name acme.io/remoteorg/name:latest acme.io/remoteorg/name: You can either pull an image: -```shell +```bash tart pull acme.io/remoteorg/name:latest ``` ...or instantiate a VM from a remote image: -```shell +```bash tart clone acme.io/remoteorg/name:latest my-local-vm-name ``` diff --git a/mkdocs.yml b/mkdocs.yml index 956bfa1..448bca6 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -29,6 +29,7 @@ theme: features: - announce.dismiss - content.tabs.link + - content.code.copy - navigation.tabs - navigation.tabs.sticky - navigation.top