add env port
This commit is contained in:
@@ -43,7 +43,8 @@ function App() {
|
|||||||
const connectToMqtt = () => {
|
const connectToMqtt = () => {
|
||||||
try {
|
try {
|
||||||
// const connectUrl = `mqtt://${mqttOptions.host}:${mqttOptions.port}`;
|
// const connectUrl = `mqtt://${mqttOptions.host}:${mqttOptions.port}`;
|
||||||
const connectUrl = `${import.meta.env.VITE_MQTT_PROTOCOL}://${mqttOptions.host}:${mqttOptions.port}`;
|
// const connectUrl = `${import.meta.env.VITE_MQTT_PROTOCOL}://${mqttOptions.host}:${mqttOptions.port}`;
|
||||||
|
const connectUrl = `ws://mqtt.idetama.id:443/wss`;
|
||||||
console.log('Attempting to connect to:', connectUrl);
|
console.log('Attempting to connect to:', connectUrl);
|
||||||
|
|
||||||
mqttClient = mqtt.connect(connectUrl, {
|
mqttClient = mqtt.connect(connectUrl, {
|
||||||
|
|||||||
Reference in New Issue
Block a user