how do I update my go site?

53 views
Skip to first unread message

Daniel Lemon

unread,
May 23, 2016, 1:43:41 PM5/23/16
to Google App Engine

This is a very basic problem.  I must have missed something obvious.  This is one of those things where I don't even know what to search for.

I created a basic go "Hello World" app.  It works great.  What I want to do is now is to make changes to that web page.

I cloned the source code to a local repo, then changed the hello world text in the go file, and then I pushed that change up.  My change is visible in the "master" branch.

But what do I do now?  How do I get this change to be live on the web site?  This is where I am lost.

Daniel Lemon

unread,
May 23, 2016, 2:40:44 PM5/23/16
to Google App Engine
I guess here is some more info.  On AWS, I would use "eb deploy" and it would upload my project files, create a new version, and make it go live.  Whats the equivalent on google app engine?

I feel like this has to be right in front of my face but I have been looking all over the place all morning and I just don't see what I am supposed to do.

Daniel Lemon

unread,
May 23, 2016, 4:10:37 PM5/23/16
to Google App Engine
Maybe there is a different way to frame the problem.

This is the web site: https://orbital-nuance-131419.appspot.com/  it says "Hello, world!"

I am trying to change that text to something else

I have successfully changed the go file to this:

package hello

import (
    "fmt"
    "net/http"
)

func init() {
    http.HandleFunc("/", handler)
}

func handler(w http.ResponseWriter, r *http.Request) {
    fmt.Fprint(w, "Hello, arse!")
}


But the web site hasn't actually changed to reflect that code change.  What do I do to publish this change and make it go live on the web site?  I am searching everywhere... I really cannot figure this out.



On Monday, May 23, 2016 at 11:43:41 AM UTC-6, Daniel Lemon wrote:

Zeehad (Cloud Platform Support)

unread,
May 24, 2016, 11:07:07 AM5/24/16
to Google App Engine
Hello Daniel,

Considering you have the App Engine SDK installed, you can run the following command from your application directory to deploy it to App Engine

appcfg.py update ./ -A orbital-nuance-131419 -V your-version

If your-version is not already the default version, you may also want to run the following command to set it as default

appcfg.py set_default_version ./ -A orbital-nuance-131419 -V your-version

Deployment can also be done using the goapp command

goapp deploy -application orbital-nuance-131419 -version your-version

I hope that helps. Cheers!
Reply all
Reply to author
Forward
0 new messages