### Install fixie-wrench via script Source: https://usefixie.com/documentation/fixie-wrench Run this command in your project directory to install the utility using the provided installer script. ```bash /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/usefixie/fixie-wrench/HEAD/install.sh)" ``` -------------------------------- ### Connect via SSH using ProxyCommand Source: https://usefixie.com/documentation/curl Example for routing SSH traffic through a Fixie SOCKS proxy using ncat. ```bash ssh -o ProxyCommand='ncat --proxy-type socks5 --proxy YOUR-FIXIE-SOCKS-DOMAIN.usefixie.com:1080 --proxy-auth fixie:YOUR-FIXIE-SOCKS-TOKEN %h %p' serveruser@server.ip.address ``` -------------------------------- ### Connect via curl using HTTP and SOCKS proxies Source: https://usefixie.com/documentation/curl Examples for routing HTTP requests through Fixie HTTP or SOCKSv5 proxies. ```bash curl http://welcome.usefixie.com --proxy $FIXIE_URL ``` ```bash curl --socks5-hostname $FIXIE_SOCKS_HOST http://welcome.usefixie.com ``` -------------------------------- ### Install Fixie Addon Source: https://usefixie.com/documentation/heroku Attach the Fixie addon to a Heroku application using the CLI. ```bash $ heroku addons:create fixie -----> Adding fixie to sharp-mountain-4005... done, v18 (free) ``` -------------------------------- ### Connect via curl using FTP Source: https://usefixie.com/documentation/curl Example for routing non-HTTP traffic like FTP through a SOCKSv5 proxy. ```bash curl -v 'ftp://ftp2.census.gov/robots.txt' --socks5-hostname $FIXIE_SOCKS_IP_SPECIFIC_URL ``` -------------------------------- ### Forward Local Port to MySQL via Fixie-Wrench Source: https://usefixie.com/documentation/static-ip/python/heroku/mysql Install the Fixie-Wrench utility and initiate a tunnel from localhost to the remote MySQL server. ```bash # Install Fixie-Wrench in your app build or deploy process. /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/usefixie/fixie-wrench/HEAD/install.sh)" # Start a tunnel from localhost:3306 to mysql.example.com:3306. # Your Python app connects to localhost:3306; Fixie handles the outbound static IP. ./bin/fixie-wrench 3306:mysql.example.com:3306 ``` -------------------------------- ### Start Codex with Proxy Environment Variables Source: https://usefixie.com/documentation/codex-static-ip-address Set the required proxy environment variables in your shell before starting the Codex CLI. ```bash export FIXIE_URL="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export HTTP_PROXY="$FIXIE_URL" export HTTPS_PROXY="$FIXIE_URL" export http_proxy="$FIXIE_URL" export https_proxy="$FIXIE_URL" export NO_PROXY="localhost,127.0.0.1,::1" export no_proxy="$NO_PROXY" codex -c 'sandbox_workspace_write.network_access=true' ``` -------------------------------- ### Configure Persistent OpenClaw Gateway Source: https://usefixie.com/documentation/openclaw-static-ip-address Environment variable configuration for durable gateway service installations. ```bash # ~/.openclaw/.env or $OPENCLAW_STATE_DIR/.env OPENCLAW_PROXY_URL=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 openclaw config set proxy.enabled true openclaw gateway install --force openclaw gateway start ``` -------------------------------- ### Forward a local port to SFTP through Fixie Socks Source: https://usefixie.com/documentation/static-ip/node/heroku/sftp Installation and execution commands for Fixie-Wrench to tunnel local traffic to a remote SFTP server. ```bash # Install Fixie-Wrench in your app build or deploy process. /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/usefixie/fixie-wrench/HEAD/install.sh)" # Start a tunnel from localhost:2222 to sftp.example.com:22. # Your Node app connects to localhost:2222; Fixie handles the outbound static IP. ./bin/fixie-wrench 2222:sftp.example.com:22 ``` -------------------------------- ### Forward local port to Redshift via Fixie Socks Source: https://usefixie.com/documentation/static-ip/python/heroku/redshift Commands to install the Fixie-Wrench utility and initiate a TCP tunnel from localhost to the Redshift cluster. ```bash # Install Fixie-Wrench in your app build or deploy process. /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/usefixie/fixie-wrench/HEAD/install.sh)" # Start a tunnel from localhost:5439 to redshift-cluster.example.com:5439. # Your Python app connects to localhost:5439; Fixie handles the outbound static IP. ./bin/fixie-wrench 5439:redshift-cluster.example.com:5439 ``` -------------------------------- ### Forward local port to Postgres via Fixie-Wrench Source: https://usefixie.com/documentation/static-ip/java/heroku/postgres Commands to install Fixie-Wrench and establish a tunnel from a local port to the remote Postgres server. ```bash # Install Fixie-Wrench in your app build or deploy process. /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/usefixie/fixie-wrench/HEAD/install.sh)" # Start a tunnel from localhost:5432 to postgres.example.com:5432. # Your Java app connects to localhost:5432; Fixie handles the outbound static IP. ./bin/fixie-wrench 5432:postgres.example.com:5432 ``` -------------------------------- ### Export Proxy Variables for Interactive Shell Source: https://usefixie.com/documentation/hermes-static-ip-address Commands to export proxy variables for a temporary shell session before starting Hermes. ```bash export FIXIE_URL="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export HTTP_PROXY="$FIXIE_URL" export HTTPS_PROXY="$FIXIE_URL" export http_proxy="$FIXIE_URL" export https_proxy="$FIXIE_URL" hermes chat ``` -------------------------------- ### Prompt for Lovable Proxy Configuration Source: https://usefixie.com/documentation/lovable-static-ip-address Example prompt to instruct Lovable to update a backend function to use the FIXIE_URL secret for outbound requests. ```text Update the [name] backend function so its request to [destination URL] goes through an HTTP proxy. Read the proxy URL from the FIXIE_URL secret and use Deno.createHttpClient with that proxy URL to create the client used for the fetch call. ``` -------------------------------- ### Forward local port to Redshift via Fixie-Wrench Source: https://usefixie.com/documentation/static-ip/ruby/heroku/redshift Installation and execution commands for Fixie-Wrench to tunnel traffic from localhost to a remote Redshift cluster. ```bash # Install Fixie-Wrench in your app build or deploy process. /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/usefixie/fixie-wrench/HEAD/install.sh)" # Start a tunnel from localhost:5439 to redshift-cluster.example.com:5439. # Your Ruby app connects to localhost:5439; Fixie handles the outbound static IP. ./bin/fixie-wrench 5439:redshift-cluster.example.com:5439 ``` -------------------------------- ### Configure HTTP/S proxy secret and environment variable Source: https://usefixie.com/documentation/koyeb Commands to create a Koyeb secret for the Fixie URL and initialize the application with the corresponding environment variable. ```bash koyeb secret create FIXIE_URL --value "" koyeb app init \ ... --env "FIXIE_URL=@FIXIE_URL" ``` -------------------------------- ### Configure custom http.Client for Fixie Source: https://usefixie.com/documentation/go Create a custom http.Client with a transport configured to use the FIXIE_URL environment variable as a proxy. ```go package main import ( "net/url" "net/http" "os" "io/ioutil" ) func main () { fixieUrl, err := url.Parse(os.Getenv("FIXIE_URL")) customClient := &http.Client{Transport: &http.Transport{Proxy: http.ProxyURL(fixieUrl)}} resp, err := customClient.Get("http://welcome.usefixie.com") if (err != nil) { println(err.Error()) return } defer resp.Body.Close() body, err := ioutil.ReadAll(resp.Body) println(string(body)) } ``` -------------------------------- ### Configure Net::HTTP for Fixie Source: https://usefixie.com/documentation/ruby Manually parses the FIXIE_URL environment variable to initialize a Net::HTTP proxy connection. ```ruby require 'net/http' _, username, password, host, port = ENV["FIXIE_URL"].gsub(/(:|\/|@)/,' ').squeeze(' ').split uri = URI("http://welcome.usefixie.com") request = Net::HTTP.new(uri.host, uri.port, host, port, username, password) response = request.get(uri) ``` -------------------------------- ### Configure Fixie in Serverless Framework Source: https://usefixie.com/documentation/aws-lambda Set environment variables in serverless.yml and manage local credentials via a .env file. ```yaml provider: name: aws runtime: nodejs18.x environment: FIXIE_URL: ${env:FIXIE_URL} functions: myFunction: handler: handler.main ``` ```text FIXIE_URL=http://fixie:your-token@your-subdomain.usefixie.com:80 ``` -------------------------------- ### Verify Static IP Configuration Source: https://usefixie.com/documentation/codex-static-ip-address Run these commands to confirm that the proxy is correctly configured and traffic is routed through the static IP. ```bash curl --proxy "$FIXIE_URL" http://welcome.usefixie.com curl https://api.ipify.org ``` -------------------------------- ### Using http with Fixie Socks Source: https://usefixie.com/documentation/javascript Demonstrates using the socks npm package to create an agent for Node's native http module. ```javascript const http = require('http'); const Socks = require('socks'); const fixieUrl = process.env.FIXIE_SOCKS_HOST; const fixieValues = fixieUrl.split(new RegExp('[/(:\/@)/]+')); const socksAgent = new Socks.Agent({ proxy: { ipaddress: fixieValues[2], port: fixieValues[3], type: 5, authentication: { username: fixieValues[0], password: fixieValues[1] } }}, true, // true HTTPS server, false for HTTP server false // rejectUnauthorized option passed to tls.connect() ); function resHandler(res) { let responseBody = ''; res.on('data', (chunk) => { responseBody += chunk; }); res.on('error', () => { process.exit(1); }); res.on('end', () => { console.log(responseBody); socksAgent.encryptedSocket.end(); }); } http.get({ hostname: 'example.com', port: '443', agent: socksAgent}, resHandler); ``` -------------------------------- ### Configure OkHttpClient with Fixie proxy Source: https://usefixie.com/documentation/static-ip/java/heroku/api Implementation for parsing the FIXIE_URL and configuring an OkHttpClient instance to route traffic through the proxy with basic authentication. ```java String fixieUrl = System.getenv("FIXIE_URL"); String[] fixieValues = fixieUrl.split("[/(:\\/@)/]+"); String fixieUser = fixieValues[1]; String fixiePassword = fixieValues[2]; String fixieHost = fixieValues[3]; int fixiePort = Integer.parseInt(fixieValues[4]); OkHttpClient client = new OkHttpClient.Builder() .proxy(new Proxy(Proxy.Type.HTTP, new InetSocketAddress(fixieHost, fixiePort))) .proxyAuthenticator((route, response) -> { String credential = Credentials.basic(fixieUser, fixiePassword); return response.request().newBuilder() .header("Proxy-Authorization", credential) .build(); }) .build(); ``` -------------------------------- ### Make an HTTP request through Fixie proxy in Go Source: https://usefixie.com/documentation/static-ip/go/aws-lambda/api Initialize an http.Client with a custom transport configured to use the proxy URL parsed from the FIXIE_URL environment variable. ```go package main import ( "net/http" "net/url" "os" ) func main() { fixieURL, err := url.Parse(os.Getenv("FIXIE_URL")) if err != nil { panic(err) } client := &http.Client{ Transport: &http.Transport{Proxy: http.ProxyURL(fixieURL)}, } _, err = client.Get("https://api.example.com/data") if err != nil { panic(err) } } ``` -------------------------------- ### Upgrade Fixie Plan Source: https://usefixie.com/documentation/heroku Migrate the Fixie addon to a different service plan using the CLI. ```bash $ heroku addons:upgrade fixie:newplan -----> Upgrading fixie:newplan to sharp-mountain-4005... done, v18 ($/mo) Your plan has been updated to: fixie:newplan ``` -------------------------------- ### Open Fixie Dashboard via CLI Source: https://usefixie.com/documentation/heroku-socks Access the Fixie Socks management dashboard directly from the command line. ```bash $ heroku addons:open fixie-socks Opening fixie for sharp-mountain-4005… ``` -------------------------------- ### Configure SOCKS proxy secret and environment variable Source: https://usefixie.com/documentation/koyeb Commands to create a Koyeb secret for the Fixie SOCKS host and initialize the application with the corresponding environment variable. ```bash koyeb secret create FIXIE_SOCKS_HOST --value "" koyeb app init \ ... --env "FIXIE_SOCKS_HOST=@FIXIE_SOCKS_HOST" ``` -------------------------------- ### Configure SOCKS5 proxy for net-sftp Source: https://usefixie.com/documentation/ruby Creates a Net::SSH::Proxy::SOCKS5 object using the FIXIE_SOCKS_HOST environment variable. ```ruby proxy_uri = URI.parse("socks://#{FIXIE_SOCKS_HOST}") socks_proxy = Net::SSH::Proxy::SOCKS5.new( proxy_uri.host, proxy_uri.port, user: proxy_uri.user, password: proxy_uri.password, ) ``` -------------------------------- ### Configure Procfile for fixie-wrench Source: https://usefixie.com/documentation/heroku-socks Update the Procfile to initiate port forwarding via the fixie-wrench binary. ```bash web: ./bin/fixie-wrench LOCAL_PORT:REMOTE_HOST:REMOTE_PORT & ... ``` -------------------------------- ### Connect to SFTP through FIXIE_SOCKS_HOST Source: https://usefixie.com/documentation/static-ip/ruby/heroku/sftp Implementation for configuring a SOCKS5 proxy using the FIXIE_SOCKS_HOST environment variable and initiating an SFTP session. ```ruby require "net/sftp" require "net/ssh/proxy/socks5" proxy_uri = URI.parse("socks://#{ENV.fetch("FIXIE_SOCKS_HOST")}") socks_proxy = Net::SSH::Proxy::SOCKS5.new( proxy_uri.host, proxy_uri.port, user: proxy_uri.user, password: proxy_uri.password, ) Net::SFTP.start("sftp.example.com", "deploy", proxy: socks_proxy) do |sftp| sftp.download!("/remote/path/report.csv", "report.csv") end ``` -------------------------------- ### Set global proxy environment variables Source: https://usefixie.com/documentation/go Configure the application to route all outbound requests through Fixie by setting HTTP_PROXY and HTTPS_PROXY environment variables. ```go package main import ( "net/http" "os" "io/ioutil" ) func main () { os.Setenv("HTTP_PROXY", os.Getenv("FIXIE_URL")) os.Setenv("HTTPS_PROXY", os.Getenv("FIXIE_URL")) resp, err := http.Get("http://welcome.usefixie.com") if (err != nil) { println(err.Error()) return } defer resp.Body.Close() body, err := ioutil.ReadAll(resp.Body) println(string(body)) } ``` -------------------------------- ### Use net/proxy for SOCKS5 connections Source: https://usefixie.com/documentation/go Utilize the net/proxy package to create a SOCKS5 dialer for TCP connections, suitable for use with Fixie Socks. ```go package main import ( "fmt" "io/ioutil" "net/http" "os" "strings" "golang.org/x/net/proxy" ) const URL = "http://www.example.com" func main() { fixie_data := strings.Split(os.Getenv("FIXIE_SOCKS_HOST"), "@") fixie_addr := fixie_data[1] auth_data := strings.Split(fixie_data[0], ":") auth := proxy.Auth{ User: auth_data[0], Password: auth_data[1], } dialer, err := proxy.SOCKS5("tcp", fixie_addr, &auth, proxy.Direct) if err != nil { fmt.Fprintln(os.Stderr, "can't connect to the proxy:", err) os.Exit(1) } httpTransport := &http.Transport{} httpClient := &http.Client{Transport: httpTransport} httpTransport.Dial = dialer.Dial req, err := http.NewRequest("GET", URL, nil) if err != nil { fmt.Fprintln(os.Stderr, "can't create request:", err) os.Exit(2) } resp, err := httpClient.Do(req) if err != nil { fmt.Fprintln(os.Stderr, "can't GET page:", err) os.Exit(3) } defer resp.Body.Close() b, err := ioutil.ReadAll(resp.Body) if err != nil { fmt.Fprintln(os.Stderr, "error reading body:", err) os.Exit(4) } fmt.Println(string(b)) } ``` -------------------------------- ### Connect to Postgres through FIXIE_SOCKS_HOST Source: https://usefixie.com/documentation/static-ip/node/aws-lambda/postgres Configure the pg client to route traffic through the Fixie Socks proxy using the FIXIE_SOCKS_HOST environment variable. ```javascript const pg = require('pg'); const SocksConnection = require('socksjs'); const fixieValues = process.env.FIXIE_SOCKS_HOST.split(new RegExp('[/(:\/@)/]+')); const databaseServer = { host: 'postgres.example.com', port: 5432, }; const fixieConnection = new SocksConnection(databaseServer, { user: fixieValues[0], pass: fixieValues[1], host: fixieValues[2], port: fixieValues[3], }); const client = new pg.Client({ user: process.env.DB_USER, password: process.env.DB_PASSWORD, database: process.env.DB_NAME, stream: fixieConnection, ssl: true, }); client.connect() .then(() => client.query('select 1 as ok')) .then((result) => console.log(result.rows[0])); ``` -------------------------------- ### Using fetch with Fixie Source: https://usefixie.com/documentation/javascript Utilizes the https-proxy-agent package to enable proxy support for the fetch API. ```javascript const HttpsProxyAgent = require('https-proxy-agent'); const response = await fetch("https://example.com", { agent: new HttpsProxyAgent({ proxy: process.env.FIXIE_URL }), }); ``` -------------------------------- ### Attach Fixie to Heroku app Source: https://usefixie.com/documentation/static-ip/go/heroku/api Commands to provision the Fixie add-on and retrieve the proxy URL configuration variable. ```bash heroku addons:create fixie heroku config:get FIXIE_URL ``` -------------------------------- ### Configure Apache HttpClient with Fixie Source: https://usefixie.com/documentation/java Uses the FIXIE_URL environment variable to extract proxy credentials and host details for Apache HttpClient. ```java import org.apache.http.HttpHost; import org.apache.http.auth.AuthScope; import org.apache.http.auth.UsernamePasswordCredentials; import org.apache.http.client.CredentialsProvider; import org.apache.http.client.config.RequestConfig; import org.apache.http.client.methods.CloseableHttpResponse; import org.apache.http.client.methods.HttpGet; import org.apache.http.impl.client.BasicCredentialsProvider; import org.apache.http.impl.client.CloseableHttpClient; import org.apache.http.impl.client.HttpClients; import org.apache.http.util.EntityUtils; public class FixieExample { public static void main(String[] args) throws Exception { String fixieUrl = System.getenv("FIXIE_URL"); String[] fixieValues = fixieUrl.split("[/(:\\/@)/]+"); String fixieUser = fixieValues[1]; String fixiePassword = fixieValues[2]; String fixieHost = fixieValues[3]; int fixiePort = Integer.parseInt(fixieValues[4]); CredentialsProvider credsProvider = new BasicCredentialsProvider(); credsProvider.setCredentials( new AuthScope(fixieHost, fixiePort), new UsernamePasswordCredentials(fixieUser, fixiePassword)); CloseableHttpClient httpclient = HttpClients.custom() .setDefaultCredentialsProvider(credsProvider).build(); try { HttpHost proxy = new HttpHost(fixieHost, fixiePort); RequestConfig config = RequestConfig.custom() .setProxy(proxy) .build(); HttpHost target = new HttpHost("www.example.com", 80, "http"); HttpGet httpget = new HttpGet("/"); httpget.setConfig(config); CloseableHttpResponse response = httpclient.execute(target, httpget); try { System.out.println(EntityUtils.toString(response.getEntity())); } finally { response.close(); } } finally { httpclient.close(); } } } ``` -------------------------------- ### Connecting to MySQL with Fixie Socks Source: https://usefixie.com/documentation/javascript Uses connection pooling and a custom stream to connect to MySQL via Fixie Socks. ```javascript const SocksConnection = require('socksjs'); const mysql = require('mysql2'); const fixieUrl = process.env.FIXIE_SOCKS_HOST; const fixieValues = fixieUrl.split(new RegExp('[/(:\/@)/]+')); const mysqlServer = { host: 'your-host.example.com', port: 3306 }; const dbUser = 'user'; const dbPassword = 'password'; const db = 'database'; const fixieConnection = new SocksConnection(mysqlServer, { user: fixieValues[0], pass: fixieValues[1], host: fixieValues[2], port: fixieValues[3], }); const mysqlConnPool = mysql.createPool({ user: dbUser, password: dbPassword, database: db, stream: fixieConnection }); mysqlConnPool.getConnection(function gotConnection(err, connection) { if (err) throw err; queryVersion(connection); }); function queryVersion(connection) { connection.query('SELECT version();', function (err, rows, fields) { if (err) throw err; console.log('MySQL/MariaDB version: ', rows); connection.release(); process.exit(); }); } ``` -------------------------------- ### Configure faraday for Fixie Source: https://usefixie.com/documentation/ruby Initializes a Faraday connection object with the proxy configuration. ```ruby require 'faraday' conn = Faraday.new(:url => "http://welcome.usefixie.com", :proxy => ENV["FIXIE_URL"]) response = conn.get ``` -------------------------------- ### View Local Environment Variables Source: https://usefixie.com/documentation/vercel Display the contents of the local environment file to verify the presence of Fixie configuration variables. ```bash cat .env.local ``` -------------------------------- ### Connect to SFTP via Ruby Source: https://usefixie.com/documentation/ftp Configure the net-sftp library to use a SOCKS5 proxy for secure file transfers. ```ruby proxy_uri = URI.parse("socks://#{FIXIE_SOCKS_HOST}") socks_proxy = Net::SSH::Proxy::SOCKS5.new( proxy_uri.host, proxy_uri.port, user: proxy_uri.user, password: proxy_uri.password, ) Net::SFTP.start( ... proxy: socks_proxy, ) do |sftp| sftp.download!("/path/to/file") end ``` -------------------------------- ### Make an HTTP/S request using Python Source: https://usefixie.com/documentation/http-and-https-requests Uses the requests library with a proxy dictionary configured from the FIXIE_URL environment variable. ```python import os, requests proxyDict = { "http" : os.environ.get('FIXIE_URL', ''), "https" : os.environ.get('FIXIE_URL', '') } r = requests.get('http://example.com', proxies=proxyDict) ``` -------------------------------- ### Create Fixie Socks Add-on Source: https://usefixie.com/documentation/heroku-socks Provision the Fixie Socks add-on for a Heroku application using the CLI. ```bash $ heroku addons:create fixie-socks -----> Adding fixie-socks to sharp-mountain-4005... done, v18 (free) ``` -------------------------------- ### Retrieve FIXIE_SOCKS_HOST Source: https://usefixie.com/documentation/heroku-socks Fetch the SOCKS V5 proxy URL from the application configuration. ```bash $ heroku config:get FIXIE_SOCKS_HOST user:pass@criterium.usefixie.com:1080 ``` -------------------------------- ### Codex App Environment File Configuration Source: https://usefixie.com/documentation/codex-static-ip-address Use this configuration in ~/.codex/.env if the Codex app or IDE extension does not inherit your shell environment. ```bash export FIXIE_URL="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export HTTP_PROXY="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export HTTPS_PROXY="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export http_proxy="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export https_proxy="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export NO_PROXY="localhost,127.0.0.1,::1" export no_proxy="localhost,127.0.0.1,::1" ``` -------------------------------- ### Connect to FTP via cURL Source: https://usefixie.com/documentation/ftp Use the --socks5-hostname flag to route FTP requests through the Fixie proxy host. ```bash curl -v 'ftp://ftp2.census.gov/robots.txt' --socks5-hostname $FIXIE_SOCKS_HOST ``` -------------------------------- ### List Koyeb instances Source: https://usefixie.com/documentation/koyeb Command to check the region of your deployed Koyeb application. ```bash koyeb instances list ``` -------------------------------- ### Using Axios with Fixie Source: https://usefixie.com/documentation/javascript Configures Axios to route requests through the Fixie proxy using environment variables. ```javascript const axios = require('axios'); const url = require('url'); const fixieUrl = url.parse(process.env.FIXIE_URL); const fixieAuth = fixieUrl.auth.split(':'); axios.get('https://example.com', { proxy: { protocol: 'http', host: fixieUrl.hostname, port: fixieUrl.port, auth: {username: fixieAuth[0], password: fixieAuth[1]} } }).then(response => { console.log(response.status); }); ``` -------------------------------- ### View Static IP Addresses Source: https://usefixie.com/documentation/heroku Display the static IP addresses assigned to the Fixie addon instance. ```bash $ heroku addons:create fixie Adding fixie to sharp-mountain-4005… done, v18 (free) Your static IP addresses are 54.174.229.200, 54.176.231.252 ``` -------------------------------- ### Upgrade Fixie Socks plan Source: https://usefixie.com/documentation/heroku-socks Use this command to migrate to a different plan. Note that changing the plan does not change the outbound IP address. ```bash $ heroku addons:upgrade fixie-socks:newplan -----> Upgrading fixie-socks:newplan to sharp-mountain-4005... done, v18 ($/mo) Your plan has been updated to: fixie-socks:newplan ``` -------------------------------- ### Configure Local Environment Source: https://usefixie.com/documentation/heroku Export the FIXIE_URL from Heroku configuration to a local .env file for development. ```bash $ heroku config -s | grep FIXIE_URL >> .env $ more .env ``` -------------------------------- ### Configure Req proxy connection options Source: https://usefixie.com/documentation/elixir Define a function to parse FIXIE_URL and return proxy connection options with authentication headers. ```elixir ... import Base import URI def connect_options() do fixie_url = System.get_env("FIXIE_URL") %URI{userinfo: userinfo, host: proxy_host} = URI.parse(fixie_url) [proxy_username, proxy_password] = String.split(userinfo, ":") proxy_auth = Base.encode64("#{proxy_username}:#{proxy_password}") [ proxy: {:http, proxy_host, 80, []}, proxy_headers: [ {"Proxy-Authorization", "Basic #{proxy_auth}"} ] ] end def post_request(url, form) do Req.post!(url, form: form, connect_options: connect_options()) end ``` -------------------------------- ### Execute SFTP request via Fixie Socks Source: https://usefixie.com/documentation/ruby Uses the configured SOCKS5 proxy object to perform an SFTP download. ```ruby Net::SFTP.start( ... proxy: socks_proxy, ) do |sftp| sftp.download!("/path/to/file") end ``` -------------------------------- ### Route requests via Fixie using urllib2 Source: https://usefixie.com/documentation/python Uses ProxyHandler and build_opener to route specific requests through the Fixie proxy. ```python import os, urllib2 proxy = urllib2.ProxyHandler({'http': os.environ.get('FIXIE_URL', '')}) auth = urllib2.HTTPBasicAuthHandler() opener = urllib2.build_opener(proxy, auth, urllib2.HTTPHandler) response = opener.open('http://www.example.com') html = response.read() ``` -------------------------------- ### Retrieve FIXIE_URL Source: https://usefixie.com/documentation/heroku Confirm the presence of the FIXIE_URL environment variable provided by the addon. ```bash $ heroku config:get FIXIE_URL http://fixie:your-token@your-subdomain.usefixie.com:80 ``` -------------------------------- ### Forward multiple connections with verbose logging Source: https://usefixie.com/documentation/fixie-wrench Use the -v flag to enable verbose logging and specify multiple port mappings in a single command. ```bash fixie-wrench -v 1234:my-first-database.example.com:5432 1235:my-second-database.example.com:5432 ``` -------------------------------- ### Configure OpenClaw Proxy Settings Source: https://usefixie.com/documentation/openclaw-static-ip-address Commands to enable the managed proxy and validate the connection for the OpenClaw runtime. ```bash export FIXIE_URL="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" openclaw config set proxy.enabled true openclaw config set proxy.proxyUrl "$FIXIE_URL" openclaw proxy validate --proxy-url "$FIXIE_URL" openclaw gateway run ``` -------------------------------- ### Route requests via Fixie using the requests library Source: https://usefixie.com/documentation/python Configures a proxy dictionary to route specific requests through the Fixie URL. ```python import os, requests proxyDict = { "http" : os.environ.get('FIXIE_URL', ''), "https" : os.environ.get('FIXIE_URL', '') } r = requests.get('http://www.example.com', proxies=proxyDict) ``` -------------------------------- ### Configure rest-client for Fixie Source: https://usefixie.com/documentation/ruby Sets the global proxy for the rest-client gem using the FIXIE_URL environment variable. ```ruby require 'rest-client' RestClient.proxy = ENV["FIXIE_URL"] response = RestClient.get("http://welcome.usefixie.com") ``` -------------------------------- ### Proxy-Aware Fetch Request Source: https://usefixie.com/documentation/lovable-static-ip-address Implementation of a proxy-aware HTTP client using Deno.createHttpClient to route requests through the Fixie proxy. ```typescript const client = Deno.createHttpClient({ proxy: { url: Deno.env.get("FIXIE_URL")! }, }); const response = await fetch("https://api.example.com/endpoint", { client }); ``` -------------------------------- ### Open Fixie Dashboard Source: https://usefixie.com/documentation/heroku Access the Fixie dashboard directly through the Heroku CLI. ```bash $ heroku addons:open fixie Opening fixie for sharp-mountain-4005… ``` -------------------------------- ### Connect to Amazon Redshift through FIXIE_SOCKS_HOST Source: https://usefixie.com/documentation/static-ip/node/vercel/redshift Implementation using the pg driver and socksjs to route database traffic through the Fixie proxy. ```javascript const pg = require('pg'); const SocksConnection = require('socksjs'); const fixieValues = process.env.FIXIE_SOCKS_HOST.split(new RegExp('[/(:\/@)/]+')); const databaseServer = { host: 'redshift-cluster.example.com', port: 5439, }; const fixieConnection = new SocksConnection(databaseServer, { user: fixieValues[0], pass: fixieValues[1], host: fixieValues[2], port: fixieValues[3], }); const client = new pg.Client({ user: process.env.DB_USER, password: process.env.DB_PASSWORD, database: process.env.DB_NAME, stream: fixieConnection, ssl: true, }); client.connect() .then(() => client.query('select 1 as ok')) .then((result) => console.log(result.rows[0])); ``` -------------------------------- ### Make an HTTP/S request using JavaScript Source: https://usefixie.com/documentation/http-and-https-requests Utilizes the https-proxy-agent package to route fetch requests through the Fixie proxy. ```javascript const HttpsProxyAgent = require('https-proxy-agent'); const response = await fetch("http://example.com", { agent: new HttpsProxyAgent({ proxy: process.env.FIXIE_URL }), }); ``` -------------------------------- ### Connect to MySQL through FIXIE_SOCKS_HOST Source: https://usefixie.com/documentation/static-ip/node/heroku/mysql Configures the mysql2 driver to route traffic through a SOCKS proxy using the FIXIE_SOCKS_HOST environment variable. ```javascript const mysql = require('mysql2'); const SocksConnection = require('socksjs'); const fixieValues = process.env.FIXIE_SOCKS_HOST.split(new RegExp('[/(:\/@)/]+')); const mysqlServer = { host: 'mysql.example.com', port: 3306, }; const fixieConnection = new SocksConnection(mysqlServer, { user: fixieValues[0], pass: fixieValues[1], host: fixieValues[2], port: fixieValues[3], }); const pool = mysql.createPool({ user: process.env.DB_USER, password: process.env.DB_PASSWORD, database: process.env.DB_NAME, stream: fixieConnection, }); pool.query('select version()', (error, rows) => { if (error) throw error; console.log(rows); }); ``` -------------------------------- ### Forward a connection with fixie-wrench Source: https://usefixie.com/documentation/fixie-wrench Use this command to map a local port to a remote host and port, assuming the FIXIE_SOCKS_HOST environment variable is configured. ```bash fixie-wrench $localPort:$host:$remotePort ``` -------------------------------- ### Route all outbound traffic via Fixie using environment variables Source: https://usefixie.com/documentation/python Sets global environment variables to force all outbound requests from requests or urllib2 through the Fixie proxy. ```python import os, requests os.environ['http_proxy'] = os.environ.get('FIXIE_URL', '') os.environ['https_proxy'] = os.environ.get('FIXIE_URL', '') requests.get("http://www.example.com") ``` -------------------------------- ### Configure Shell Environment Policy Source: https://usefixie.com/documentation/codex-static-ip-address Update your Codex configuration to ensure proxy variables are forwarded to spawned commands. ```toml [shell_environment_policy] include_only = [ "PATH", "HOME", "FIXIE_URL", "HTTP_PROXY", "HTTPS_PROXY", "http_proxy", "https_proxy", "NO_PROXY", "no_proxy", ] ``` -------------------------------- ### Configure Fixie in AWS SAM template.yaml Source: https://usefixie.com/documentation/aws-lambda Define environment variables within the AWS SAM template to inject the Fixie proxy URL. ```yaml Resources: MyFunction: Type: AWS::Serverless::Function Properties: # ... other properties Environment: Variables: FIXIE_URL: !Ref FixieUrl Parameters: FixieUrl: Type: String Description: Your Fixie proxy URL ``` -------------------------------- ### Configure Claude Code Proxy via Settings File Source: https://usefixie.com/documentation/claude-code-static-ip-address Add proxy configuration to the ~/.claude/settings.json file to persist settings across sessions. ```json { "env": { "HTTPS_PROXY": "http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80", "HTTP_PROXY": "http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80", "NO_PROXY": "localhost,127.0.0.1,::1" } } ``` -------------------------------- ### Attach Fixie Socks to Heroku App Source: https://usefixie.com/documentation/static-ip/go/heroku/postgres Commands to provision the Fixie Socks add-on and retrieve the proxy host configuration variable. ```bash heroku addons:create fixie-socks heroku config:get FIXIE_SOCKS_HOST ``` -------------------------------- ### Local Testing with AWS SAM Source: https://usefixie.com/documentation/aws-lambda Configure environment variables in env.json and invoke functions locally using SAM CLI. ```json # Add FIXIE_URL to your env.json { "MyFunction": { "FIXIE_URL": "http://fixie:your-token@your-subdomain.usefixie.com:80" } } ``` ```bash # Invoke the function directly sam local invoke MyFunction --env-vars env.json # Or start a local API Gateway sam local start-api --env-vars env.json ``` -------------------------------- ### Configure Java Proxy with Authenticator Source: https://usefixie.com/documentation/java Sets the SOCKS proxy host and provides authentication credentials via a custom Authenticator class. ```java URL fixie = new URL(System.getenv("FIXIE_SOCKS_HOST")); String[] fixieUserInfo = fixie.getUserInfo().split(':'); String fixieUser = fixieUserInfo[0]; String fixiePassword = fixieUserInfo[1]; System.setProperty("socksProxyHost", fixie.getHost()); Authenticator.setDefault(new ProxyAuthenticator(fixieUser, fixiePassword)); //... private class ProxyAuthenticator extends Authenticator { private final PasswordAuthentication passwordAuthentication; private ProxyAuthenticator(String user, String password) { passwordAuthentication = new PasswordAuthentication(user, password.toCharArray()); } @Override protected PasswordAuthentication getPasswordAuthentication() { return passwordAuthentication; } } ``` -------------------------------- ### Pull Vercel Environment Variables Source: https://usefixie.com/documentation/vercel Use the Vercel CLI to pull environment variables, including Fixie configuration, into a local .env.local file. ```bash vercel env pull > Downloading `development` Environment Variables for Project example ✅ Created .env.local file [71ms] ``` -------------------------------- ### Configure Fly.io Secrets Source: https://usefixie.com/documentation/fly Set the Fixie proxy credentials as environment variables in your Fly.io application using the fly CLI. ```bash fly secrets set FIXIE_URL=... # This is where your Proxy URL from Fixie's dashboard goes fly secrets set FIXIE_SOCKS_HOST=... # This is where your Proxy Host from Fixie's dashboard goes ``` -------------------------------- ### Pull Vercel environment variables Source: https://usefixie.com/documentation/static-ip/go/vercel/api Commands to retrieve and verify the FIXIE_URL environment variable in a local development environment. ```bash vercel env pull grep FIXIE_URL .env.local ``` -------------------------------- ### Set a Koyeb secret Source: https://usefixie.com/documentation/static-ip/node/koyeb/api Commands to create a Koyeb secret for the Fixie URL and inject it into the application environment. ```bash koyeb secret create FIXIE_URL --value "..." koyeb app init YOUR_APP_NAME --env "FIXIE_URL=@FIXIE_URL" ``` -------------------------------- ### Set Local Environment Variable Source: https://usefixie.com/documentation/heroku-socks Export the FIXIE_SOCKS_HOST variable to a local .env file for development. ```bash $ heroku config:get FIXIE_SOCKS_HOST -s >> .env ``` -------------------------------- ### Connect to MongoDB through FIXIE_SOCKS_HOST Source: https://usefixie.com/documentation/static-ip/node/heroku/mongodb Implementation for configuring Mongoose to use the Fixie Socks proxy via environment variables. ```javascript const mongoose = require('mongoose'); const fixieValues = process.env.FIXIE_SOCKS_HOST.split(new RegExp('[/(:\/@)/]+')); mongoose.connect(process.env.MONGODB_URI, { proxyUsername: fixieValues[0], proxyPassword: fixieValues[1], proxyHost: fixieValues[2], proxyPort: Number(fixieValues[3]), }).then(() => { console.log('Connected to MongoDB'); }); ``` -------------------------------- ### Configure Claude Code Proxy via Environment Variables Source: https://usefixie.com/documentation/claude-code-static-ip-address Set standard HTTP proxy environment variables in your shell to route Claude Code traffic through Fixie. ```bash export FIXIE_URL="http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80" export HTTPS_PROXY="$FIXIE_URL" export HTTP_PROXY="$FIXIE_URL" export NO_PROXY="localhost,127.0.0.1,::1" claude ``` -------------------------------- ### Channel-Specific Proxy Settings Source: https://usefixie.com/documentation/hermes-static-ip-address Proxy settings for specific messaging channels to egress through Fixie. ```bash TELEGRAM_PROXY=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 DISCORD_PROXY=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 ``` -------------------------------- ### Locate Hermes Environment Path Source: https://usefixie.com/documentation/hermes-static-ip-address Command to find the path to the Hermes environment configuration file. ```bash hermes config env-path ``` -------------------------------- ### Configure PHP cURL with Fixie Proxy Source: https://usefixie.com/documentation/php Uses the FIXIE_URL environment variable to configure proxy settings for cURL requests. Ensure the environment variable is set before execution. ```php ``` -------------------------------- ### Configure httparty for Fixie Source: https://usefixie.com/documentation/ruby Parses the FIXIE_URL and passes proxy credentials to the HTTParty request method. ```ruby fixie = URI.parse ENV['FIXIE_URL'] HTTParty.get( "http://welcome.usefixie.com", http_proxyaddr: fixie.host, http_proxyport: fixie.port, http_proxyuser: fixie.user, http_proxypass: fixie.password ) ``` -------------------------------- ### Make an HTTP request through FIXIE_URL Source: https://usefixie.com/documentation/static-ip/node/aws-lambda/api Configure axios to route requests through the Fixie proxy by parsing the FIXIE_URL environment variable. ```javascript const axios = require('axios'); const fixieUrl = new URL(process.env.FIXIE_URL); axios.get('https://api.example.com/data', { proxy: { protocol: 'http', host: fixieUrl.hostname, // URL drops default ports, so fall back to 80 for Fixie's standard proxy port. port: Number(fixieUrl.port) || 80, auth: { username: fixieUrl.username, password: fixieUrl.password, }, }, }).then((response) => { console.log(response.status); }); ``` -------------------------------- ### Set Proxy Environment Variables for Child Processes Source: https://usefixie.com/documentation/openclaw-static-ip-address Standard proxy variables to ensure child processes and external tools inherit the Fixie proxy configuration. ```bash export HTTP_PROXY="$FIXIE_URL" export HTTPS_PROXY="$FIXIE_URL" export http_proxy="$FIXIE_URL" export https_proxy="$FIXIE_URL" export NO_PROXY="localhost,127.0.0.1,::1" export no_proxy="$NO_PROXY" ``` -------------------------------- ### Establish SSH Connection via Fixie Socks Source: https://usefixie.com/documentation/javascript Utilizes the socksv5 and ssh2 libraries to tunnel an SSH connection through a Fixie Socks proxy. ```javascript var socks = require('socksv5'), SSHClient = require('ssh2').Client; const fixieUrl = process.env.FIXIE_SOCKS_HOST; const fixieValues = fixieUrl.split(new RegExp('[/(:\/@)/]+')); socks.connect({ host: 'ssh.example.org', port: 22, proxyHost: fixieValues[2], proxyPort: fixieValues[3], auths: [socks.auth.UserPassword(fixieValues[0], fixieValues[1])] }, function(socket) { var conn = new SSHClient(); conn.on('ready', function() { conn.exec('uptime', function(err, stream) { if (err) throw err; stream.on('close', function(code, signal) { conn.end(); }).on('data', function(data) { console.log('STDOUT: ' + data); }).stderr.on('data', function(data) { console.log('STDERR: ' + data); }); }); }).connect({ sock: socket, username: 'ssh-user', privateKey: require('fs').readFileSync('/here/is/my/key') }); }); ``` -------------------------------- ### Retrieve Static IP Addresses Source: https://usefixie.com/documentation/heroku-socks View the assigned static IP addresses via the Heroku CLI during add-on creation. ```bash $ heroku addons:create fixie-socks Adding fixie to sharp-mountain-4005… done, v18 (free) Your static IP addresses are 54.174.229.200, 54.176.231.252 ``` -------------------------------- ### Connect to PostgreSQL with pg via SOCKS proxy Source: https://usefixie.com/documentation/database-connections Uses the socksjs library to create a stream for the pg driver, allowing database traffic to be tunneled through a SOCKS proxy. ```javascript const pg = require('pg'); const SocksConnection = require('socksjs'); const fixieUrl = process.env.FIXIE_SOCKS_HOST; const fixieValues = fixieUrl.split(new RegExp('[/(:\/@)/]+')); const pgServer = { host: 'YOUR-HOST', port: 5432 }; const fixieConnection = new SocksConnection(pgServer, { user: fixieValues[0], pass: fixieValues[1], host: fixieValues[2], port: fixieValues[3], }); const connectionConfig = { user: 'YOUR-DB-USERNAME', password: 'YOUR-DB-PASSWORD', database: 'YOUR-DATABASE', stream: fixieConnection, ssl: true // Optional, depending on db config }; var client = new pg.Client(connectionConfig); client.connect(function (err) { if (err) throw err; client.query('SELECT 1+1 as test1', function (err, result) { if (err) throw err; console.log(result.rows[0]); client.end(function (err) { if (err) throw err; }); }); }); ``` -------------------------------- ### Configure Node.js Lambda for Fixie HTTP Proxy Source: https://usefixie.com/documentation/aws-lambda Uses the axios library to route requests through the Fixie HTTP proxy defined in the FIXIE_URL environment variable. ```javascript const axios = require('axios'); const { URL } = require('url'); exports.handler = async (event) => { // Parse the FIXIE_URL const fixieUrl = new URL(process.env.FIXIE_URL); const proxyHost = fixieUrl.hostname; const proxyPort = parseInt(fixieUrl.port) || 80; // Make request through Fixie proxy const response = await axios.get('https://api.example.com/data', { proxy: { protocol: 'http', host: proxyHost, port: proxyPort, auth: { username: fixieUrl.username, password: fixieUrl.password } }, timeout: 10000 }); return { statusCode: 200, headers: { 'Content-Type': 'application/json' }, body: JSON.stringify(response.data) }; }; ``` -------------------------------- ### Make an HTTP request through FIXIE_URL Source: https://usefixie.com/documentation/static-ip/ruby/heroku/api Configures the RestClient proxy globally to route requests through the Fixie URL. ```ruby require "rest-client" RestClient.proxy = ENV["FIXIE_URL"] response = RestClient.get("https://api.example.com/data") puts response.code ``` -------------------------------- ### Configure Hermes Environment Variables Source: https://usefixie.com/documentation/hermes-static-ip-address Proxy environment variables to be added to the .env file for gateway and tool inheritance. ```bash FIXIE_URL=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 HTTP_PROXY=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 HTTPS_PROXY=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 http_proxy=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 https_proxy=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 ALL_PROXY=http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 NO_PROXY=localhost,127.0.0.1,::1 no_proxy=localhost,127.0.0.1,::1 ``` -------------------------------- ### Fixie Proxy URL Format Source: https://usefixie.com/documentation/codex-static-ip-address The format for the Fixie proxy URL retrieved from the Fixie Dashboard. ```text http://fixie:YOUR_TOKEN@YOUR_SUBDOMAIN.usefixie.com:80 ```