TheSudoYT / terraform-aws-palworld

Terraform module for Palworld Server Infrastructure on AWS
BSD 3-Clause "New" or "Revised" License
11 stars 5 forks source link

What is the preferable way to install mods? #7

Open ceopaludetto opened 8 months ago

ceopaludetto commented 8 months ago

What is your Question? How can I access the EC2 instance and install mods? Can be done with terraform to keep the modifications saved?

Additional Context I've tried with SCP command line but the key provided does not have sufficient permissions

Josh-Tracy commented 8 months ago

@ceopaludetto If you are having issues with the ssh key permissions, check out this video here to help resolve them: https://www.youtube.com/watch?v=mrUqITjUhL8

Mod installation is not part of the terraform module (yet). This is a planned feature for a future release. If you want to install mods in the mean time SCP is one of the ways to do so. Another method is - putting all of the mods into an Amazon S3 bucket and then using the aws-cli that is installed on the EC2 instance to retrieve them from the S3 bucket. Please note that if you do this you will have to go to the IAM service and find the IAM policy named palworld-instance-role-policy and modify it to allow the EC2 instance to access the S3 bucket that you create.

ceopaludetto commented 8 months ago

@ceopaludetto If you are having issues with the ssh key permissions, check out this video here to help resolve them: https://www.youtube.com/watch?v=mrUqITjUhL8

Mod installation is not part of the terraform module (yet). This is a planned feature for a future release. If you want to install mods in the mean time SCP is one of the ways to do so. Another method is - putting all of the mods into an Amazon S3 bucket and then using the aws-cli that is installed on the EC2 instance to retrieve them from the S3 bucket. Please note that if you do this you will have to go to the IAM service and find the IAM policy named palworld-instance-role-policy and modify it to allow the EC2 instance to access the S3 bucket that you create.

Actually, my access seems to be readonly

Screenshot 2024-02-01 at 17 44 50

I can access the server with ssh, but I can't create a file for example

Josh-Tracy commented 8 months ago

Ah ok. The /palworld-server directory is owned by the steam user and steam group which is a system only service account. To get around this, SCP your files to another directory that ubuntu has access to such as ubuntu's /home directory and then copy the files from that directory to the /palworld-server directory by SSHing into the server as ubuntu and using sudo cp /home/mods /palworld-server/Pal/Content/Paks/

ceopaludetto commented 8 months ago

Ok, thanks!