code: func appConfig() (*config, error) {
  	configURL := os.Getenv("CAMLI_APP_CONFIG_URL")
  	if configURL == "" {
  		return nil, fmt.Errorf("Publisher application needs a CAMLI_APP_CONFIG_URL env var")
  	}
  	cl, err := app.Client()
  	if err != nil {
  		return nil, fmt.Errorf("could not get a client to fetch extra config: %v", err)
  	}
  	conf := &config{}
  	pause := time.Second
  	giveupTime := time.Now().Add(time.Hour)
  	for {
  		err := cl.GetJSON(context.TODO(), configURL, conf)
  		if err == nil {
  			break
  		}
  		if time.Now().After(giveupTime) {
  			logger.Fatalf("Giving up on starting: could not get app config at %v: %v", configURL, err)
  		}
  		logger.Printf("could not get app config at %v: %v. Will retry in a while.", configURL, err)
  		time.Sleep(pause)
  		pause *= 2
  	}
  	return conf, nil
  }
docs: // appConfig keeps on trying to fetch the extra config from the app handler. If
  // it doesn't succed after an hour has passed, the program exits.