Ini akan menghapus halaman "Creating a server on Oracle Cloud Free Tier"
. Harap dipastikan.
Sign up at https://www.oracle.com/cloud/free/
Open the navigation menu and click Compute, then click Instances.
Click Create instance.
In the Image and shape box, click Edit.
Click Change image and select Ubuntu / Canonical Ubuntu 22.04.
In the Add SSH keys box, click Download the private key.
Click Create.
Open the navigation menu and click Networking, then click Virtual Cloud Networks.
Select the VCN you created with your compute instance.
With your VCN displayed, click the link with your subnet name.
Click the Default Security List link.
Click Add Ingress Rules.
Fill in the ingress rules as follows:
Stateless: Checked
Source Type: CIDR
Source CIDR: 0.0.0.0/0
IP Protocol: TCP
Source port range: (leave-blank)
Destination Port Range: 80
Click + Another Ingress Rule.
Stateless: Checked
Source Type: CIDR
Source CIDR: 0.0.0.0/0
IP Protocol: TCP
Source port range: (leave-blank)
Destination Port Range: 443
Click + Another Ingress Rule.
Stateless: Checked
Source Type: CIDR
Source CIDR: 0.0.0.0/0
IP Protocol: TCP
Source port range: (leave-blank)
Destination Port Range: 3025
Click + Another Ingress Rule.
Stateless: Checked
Source Type: CIDR
Source CIDR: 0.0.0.0/0
IP Protocol: UDP
Source port range: (leave-blank)
Destination Port Range: 3024
Click + Another Ingress Rule.
Stateless: Checked
Source Type: CIDR
Source CIDR: 0.0.0.0/0
IP Protocol: UDP
Source port range: (leave-blank)
Destination Port Range: 53
Click Add Ingress Rules.
Download and install PuTTY.
Open PuTTYgen and load the private key.
Type and confirm the (new) passphrase.
Save the private key.
Open Pageant, add the private key and type the passphrase.
Open PuTTY and type the public IP address in Host Name.
Under Connection / Data, type ubuntu
in Auto-login username.
Back to Session, type a name in Saved Sessions and click Save.
Double click the saved session to connect.
sudo iptables -I INPUT 6 -m state --state NEW -p tcp --dport 80 -j ACCEPT
sudo iptables -I INPUT 6 -m state --state NEW -p tcp --dport 443 -j ACCEPT
sudo iptables -I INPUT 6 -m state --state NEW -p tcp --dport 3025 -j ACCEPT
sudo iptables -I INPUT 6 -m state --state NEW -p udp --dport 3024 -j ACCEPT
sudo iptables -I INPUT 6 -m state --state NEW -p udp --dport 53 -j ACCEPT
sudo netfilter-persistent save
Replace xxx.xxx.xxx.xxx
by the public IP address.
sudo apt update
sudo apt install python3-pip
git clone https://github.com/oldnapalm/zwift-offline.git
cd zwift-offline
sudo pip3 install -r requirements.txt
cd storage
touch multiplayer.txt
touch fake-dns.txt
echo xxx.xxx.xxx.xxx > server-ip.txt
If you want Garmin upload support:
sudo pip3 install git+https://github.com/oldnapalm/garmin-uploader.git
sudo nano /etc/systemd/resolved.conf
Change the line #DNS=
to DNS=8.8.8.8
(make sure to delete the #
).
Change the line #DNSStubListener=yes
to DNSStubListener=no
(make sure to delete the #
).
Press Ctrl + X, then Y and Enter.
sudo ln -sf /run/systemd/resolve/resolv.conf /etc/resolv.conf
sudo fallocate -l 2G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
sudo cp /etc/fstab /etc/fstab.bak
echo '/swapfile none swap sw 0 0' | sudo tee -a /etc/fstab
sudo reboot
sudo cp zwift-offline/scripts/services/zoffline.service /etc/systemd/system/
sudo systemctl daemon-reload
sudo systemctl enable zoffline.service
sudo systemctl start zoffline.service
python3 zwift-offline/scripts/get_gameassets.py
cd zwift-offline
git pull
sudo systemctl restart zoffline.service
If Zwift was updated and you have cached game assets:
rm -r cdn/gameassets/Zwift_Updates_Root/Zwift_1.0.*
python3 scripts/get_gameassets.py
Download and install WinSCP.
Click New Site.
Select SCP in File protocol.
Type the public IP address in Host name.
Type ubuntu
in User name and leave Password blank (it will use private key from Pageant).
Click Save and Login.
sudo systemctl stop zoffline.service
Using WinSCP download the file zwift-offline.db from the storage folder.
Download and install DB Browser for SQLite.
Open zwift-offline.db in DB Browser.
Click Browse Data and select the user table.
Change the column is_admin
for your user to 1
and click Write Changes.
Upload the modified zwift-offline.db replacing the original.
sudo systemctl start zoffline.service
Ini akan menghapus halaman "Creating a server on Oracle Cloud Free Tier"
. Harap dipastikan.