The easy way to use this is to edit this in your text editor of choice and save the file.

Navigate to the web interface of the gateway and upload the config then reload (but do not save). When you upload, you upload to the "startup" config and when you reload, you tell the gateway to use it's startup config. If you save, you write the already "running-config" to "startup-config" and hence don't change anything.

After reload, check the boot log for errors in the event you didn't remove commented lines and event report to see if there are any immedate issues.

cli version 3.20
#clock rules are set to auto adjust for dst and new york time zone
clock local default-offset -05:00
clock local dst-rule SPRING2011 -04:00 from 02:00 mar 13rd 2011 until 03:00 nov 6th 2011
clock local dst-rule SPRING2012 -04:00 from 02:00 mar 11st 2012 until 03:00 nov 4th 2012
clock local dst-rule SPRING2013 -04:00 from 02:00 mar 10th 2013 until 03:00 nov 3rd 2013
clock local dst-rule SPRING2014 -04:00 from 02:00 mar 9th 2014 until 03:00 nov 2nd 2014
clock local dst-rule SPRING2015 -04:00 from 02:00 mar 8th 2015 until 03:00 nov 1st 2015
clock local dst-rule SPRING2016 -04:00 from 02:00 mar 13rd 2016 until 03:00 nov 6th 2016
# replace with sip dns server, usually sipx ip address
dns-client server
webserver port 80 language en
# sntp servers in this example are sipx then us naval academy clock (tick) in annapolis, md, change to suit your available time servers
sntp-client server primary port 123 version 4
sntp-client server secondary port 123 version 4
sntp-client poll-interval 36000
# replace below with gateway hostname
system hostname telco1.sipdomain.tld


  ic voice 0
    pcm law-select uLaw

  clock-source 1 e1t1 0 0

profile r2 default

profile napt NAPT_WAN
profile napt NAPT

profile ppp default

profile call-progress-tone US_Dialtone
profile call-progress-tone US_Alertingtone
  play 1 2000 440 -19 480 -19
  pause 2 4000

profile call-progress-tone US_Busytone
  play 1 500 480 -24 620 -24
  pause 2 500

profile tone-set default
profile tone-set US
  map call-progress-tone dial-tone US_Dialtone
  map call-progress-tone ringback-tone US_Alertingtone
  map call-progress-tone busy-tone US_Busytone
  map call-progress-tone release-tone US_Busytone
  map call-progress-tone congestion-tone US_Busytone

# this is able to send faxes to sipx media server or receive faxes to fxs gateways properly configured, as well as outbound from them using t.38 protocol
profile voip default
  codec 1 g711ulaw64k rx-length 20 tx-length 20
  codec 2 g711alaw64k rx-length 20 tx-length 20
  dtmf-relay rtp
  flash-hook-relay rtp
  rtp traffic-class local-default
  fax transmission 1 relay t38-udp
  fax detection fax-frames

profile pstn default

profile sip default
  no autonomous-transitioning

profile aaa default
  method 1 local
  method 2 none

context ip router

  interface WAN
    ipaddress dhcp
    use profile napt NAPT_WAN
    tcp adjust-mss rx mtu
    tcp adjust-mss tx mtu

# this is the ip of this gateway
	interface LAN
    tcp adjust-mss rx mtu
    tcp adjust-mss tx mtu

# this is the ip of your default gateway	
context ip router
  route 0

context cs switch
  digit-collection timeout 4

  routing-table called-e164 TAB_OUT
    route default dest-service OUTBOUND

  routing-table called-e164 TAB_IN
    route default dest-interface IF-SIP1

  mapping-table called-e164 to called-e164 STIP-ALL
    map default to ""

  interface isdn IF_PRI_1
    route call dest-table TAB_IN
    use profile tone-set US
    caller-name send-information-following

  interface sip IF-SIP1
    bind context sip-gateway GW-SIP
    route call dest-table TAB_OUT
    remote sipdomain.tld
    overlap-dialing new-transaction emit

  service hunt-group OUTBOUND
    drop-cause normal-unspecified
    drop-cause no-circuit-channel-available
    drop-cause network-out-of-order
    drop-cause temporary-failure
    drop-cause switching-equipment-congestion
    drop-cause access-info-discarded
    drop-cause circuit-channel-not-available
    drop-cause resources-unavailable
    route call 1 dest-interface IF_PRI_1

context cs switch
  no shutdown

# replace with your sipx sipdomain name  
location-service SIPX_VOIP
  domain 1 sipdomain.tld

context sip-gateway GW-SIP

  interface IF-SIP1
    bind interface LAN context router port 5060

context sip-gateway GW-SIP
  bind location-service SIPX_VOIP
  no shutdown

port ethernet 0 0
  medium auto
  encapsulation ip
  bind interface WAN router

port ethernet 0 1
  medium auto
  encapsulation ip
  bind interface LAN router
  no shutdown

port e1t1 0 0
  port-type t1
  clock auto
  linecode b8zs
  framing esf
  encapsulation q921

    uni-side auto
    encapsulation q931

      protocol ni2
      uni-side user
      bchan-number-order ascending-cyclic
      encapsulation cc-isdn
      bind interface IF_PRI_1 switch

port e1t1 0 0
  no shutdown

port e1t1 0 1
  port-type e1
  clock master
  framing crc4

port e1t1 0 2
  port-type e1
  clock master
  framing crc4

port e1t1 0 3
  port-type e1
  clock master
  framing crc4