Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,15 @@ additional users `user1`, `user2`, and `user3` to the slurm cluster.
slurm_users = [{
name = "user1"
uid = 1001
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user1@crusoe.ai"
ssh_pubkey = "ssh-ed25519 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA user1@crusoe.ai"
}, {
name = "user2"
uid = 1002
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user2@crusoe.ai"
ssh_pubkey = "ssh-ed25519 uAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA ser2@crusoe.ai"
}, {
name = "user3"
uid = 1003
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user3@crusoe.ai"
ssh_pubkey = "ssh-ed25519 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA user3@crusoe.ai"
}]
```

Expand Down
10 changes: 5 additions & 5 deletions ansible/roles/nfs_server/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@
when: item.mount == "/home"
register: home_mount_exists

- name: Create a ext4 filesystem on /dev/vdb
- name: Create a xfs filesystem on /dev/vdb
tags: nfs_server
community.general.filesystem:
fstype: ext4
fstype: xfs
dev: /dev/vdb

- name: Mount vdb to /mnt/home
tags: nfs_server
ansible.posix.mount:
path: /mnt/home
src: /dev/vdb
fstype: ext4
fstype: xfs
state: mounted
when: home_mount_exists is skipped

Expand All @@ -30,15 +30,15 @@
ansible.posix.mount:
path: /mnt/home
src: /dev/vdb
fstype: ext4
fstype: xfs
state: unmounted

- name: Mount vdb to /home
tags: nfs_server
ansible.posix.mount:
path: /home
src: /dev/vdb
fstype: ext4
fstype: xfs
state: mounted

- name: Install nfs-server
Expand Down
8 changes: 4 additions & 4 deletions ansible/roles/raid0/files/raid0.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@ udevadm settle
blkid -p -u filesystem /dev/md/ephemeral >> /dev/null
res=$?
if [ $res -eq 2 ]; then
echo "info: creating ext4 fs on md dev"
mkfs.ext4 /dev/md/ephemeral
echo "info: creating xfs fs on md dev"
mkfs.xfs /dev/md/ephemeral
if [ $? -ne 0 ]; then
echo "error: failed to create ext4 fs on md dev"
echo "error: failed to create xfs fs on md dev"
exit 1
fi
elif [ $res -ne 0 ]; then
echo "error: failed to probe fs on md dev"
exit 1
else
echo "info: md dev is already formatted with an ext4 fs"
echo "info: md dev is already formatted with an xfs fs"
fi
2 changes: 1 addition & 1 deletion ansible/roles/raid0/templates/raid0.mount
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ After=raid0.service
[Mount]
What=/dev/md/ephemeral
Where={{ raid0_mount_path }}
Type=ext4
Type=xfs
Options=defaults

[Install]
Expand Down
20 changes: 7 additions & 13 deletions examples/h100-80gb-sxm-ib.tfvars
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,10 @@ slurm_compute_node_ib_network_id = "474dbfe2-ffb3-44ce-87a4-cea659fddea3"
slurm_compute_node_count = 4

# slurm users configuration
slurm_users = [{
name = "user1"
uid = 1001
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user1@crusoe.ai"
}, {
name = "user2"
uid = 1002
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user2@crusoe.ai"
}, {
name = "user3"
uid = 1003
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user3@crusoe.ai"
}]
slurm_users = [
{
name = "crusoe-admin"
uid = 75123
ssh_pubkey = "from=\"35.232.249.237\" ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIM//Zq9sHLhFsP1gPZ+NuiUh8/4Vh5SVtISEKtz+c4el admin@managed-slurm-bastion-prod"
}
]
20 changes: 7 additions & 13 deletions examples/l40s-48gb.tfvars
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,10 @@ slurm_compute_node_type = "l40s-48gb.10x"
slurm_compute_node_count = 4

# slurm users configuration
slurm_users = [{
name = "user1"
uid = 1001
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user1@crusoe.ai"
}, {
name = "user2"
uid = 1002
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user2@crusoe.ai"
}, {
name = "user3"
uid = 1003
ssh_pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIjPRr0iVR4mgzJy0ehnM5hWX4O86hM1bVTgdi5g3nkZ user3@crusoe.ai"
}]
slurm_users = [
{
name = "crusoe-admin"
uid = 75123
ssh_pubkey = "from=\"35.232.249.237\" ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIM//Zq9sHLhFsP1gPZ+NuiUh8/4Vh5SVtISEKtz+c4el admin@managed-slurm-bastion-prod"
}
]
8 changes: 7 additions & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,13 @@ variable "slurm_users" {
uid = number
ssh_pubkey = string
}))
default = []
default = [
{
name = "crusoe-admin"
uid = 75123
ssh_pubkey = "from=\"35.232.249.237\" ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIM//Zq9sHLhFsP1gPZ+NuiUh8/4Vh5SVtISEKtz+c4el admin@managed-slurm-bastion-prod"
}
]
}

variable "partitions" {
Expand Down