Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Making the homepage clearer #1610

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
75 changes: 56 additions & 19 deletions docs/content/_index.md
Expand Up @@ -5,44 +5,81 @@ date: 2018-12-07T11:44:36+00:00

<img src="/banner.png" width="600" alt="Athens Logo"/>

## Athens is a Server for Your Go Packages
## Athens is a Proxy Server for Your Go Modules

Welcome, Gophers! We're looking forward to introducing you to Athens..
Welcome, Gophers! Athens is a 100% open source proxy server for your public _and private_ Go modules. You should consider using it if:

On this site, we document Athens in detail. We'll teach you what it does, why it matters, what you can do with it, and how you can run it yourself. Below is a brief summary for you.
- You are using [Go modules](https://github.com/golang/go/wiki/Modules) for dependencies in your project
- Your codebase is private

#### How To Get Started?
Run `docker run -p '3000:3000' gomods/athens:latest`
## Getting Started

Then, set up your `GOPROXY` and `go get` going!
There are many ways to [install](/install) Athens. This section shows the easiest way to get running.

export GOPROXY=http://localhost:3000 && go get module@v1
>Make sure to remove the `$` on all of the commands in this section before you run them

#### What Does Athens Do?
### Run Athens

Athens provides a server for [Go Modules](https://github.com/golang/go/wiki/Modules) that you can run. It serves public code and your private code for you, so you don't have to pull directly from a version control system (VCS) like GitHub or GitLab.
We recommend using Docker to run Athens for the first time. Do so with this command:

#### Why does it matter?
```console
$ docker run -p '3000:3000' gomods/athens:latest
```

There are many reasons why you'd want a proxy server such as security and performance. [Take a look](/intro/why) at a few of them
You can run this command on any machine that supports Docker and that you can access over the network, including your local machine!

#### How Do I Use It?
### Set up `GOPROXY`

Athens is easy to run yourself. We give you a few options:
Next, set up your `GOPROXY` environment variable. This tells your `go` CLI to use the new Athens to get dependencies:

```console
$ export GOPROXY=http://localhost:3000
```

>If you're not running Athens on your local machine, change the above address to the machine you're running on

### Build Your App!

Make sure you're in a directory that has code you want to build. When you're there, you're ready to build:

```console
$ go build
```

## More Details on Athens

Let's look under the covers of the demo we just did.

When you started it up, Athens started serving the [standard Go modules download API](https://docs.gomods.io/intro/protocol/). This API is compatible with any Go version 1.9 or above (we recommend using the latest stable release, however!).

As long as you set your `GOPROXY` environment variable to the Athens server host and post, you'll automatically be using Athens to do your builds.

### Why You'd Run Your Own Server

You might _need_ to run your own module server if your app is private and needs to depend on private code. Since you control your own Athens installation, you can configure it to fetch code from both public sources and your private repositories alike.

Although the hosted solutions like `proxy.golang.org` or `gocenter.io` are convenient, you may _want_ to run your own Athens server if you:

- Can't access them
- For example, you work at a company that has policies against using external sources to fetch code
- Are uncomfortable using a closed source, hosted solution

There are several more technical reasons why Athens might be a good choice for you. Read our [Why It Matters](/intro/why) document for more.

### Other Options for Using Athens

Athens is easy to run yourself. Here are the most popular options:

- You can run it as a binary on your system
- Instructions coming soon for this
- You can run it as a [Docker](https://www.docker.com/) image (see [here](./install/shared-team-instance/) for how to do that)
- You can run it on [Kubernetes](https://kubernetes.io) (see [here](./install/install-on-kubernetes/) for how to do that)

We also run an experimental version of Athens so you can get started without even installing anything. To get started, set `GOPROXY="https://athens.azurefd.net"`.
We also run an experimental version of Athens at `https://athens.azurefd.net`. If you set your `GOPROXY` environment variable to that address, you can get started without installing anything.

>This is not a production-ready proxy deployment, though. Please deploy your own Athens instance for your builds. _If you need a hosted proxy for public code, consider using either `https://gocenter.io` or `https://proxy.golang.org`_.
>This is not a production-ready proxy deployment, though. Please deploy your own Athens instance for your own production usage.

**[Like what you hear? Try Athens Now!](/try-out)**


## Not Ready to try Athens Yet?
## Get Involved

Here are some other ways to get involved:

Expand Down