# create

```
Usage:    hyper func create [OPTIONS] IMAGE [COMMAND] [ARG...]

Create a new function

    -e, --env=[]             Set environment variables
    --entrypoint             Overwrite the default ENTRYPOINT of the image
    --env-file=[]            Read in a file of environment variables
    --expose=[]              Expose a port or a range of ports
    --help                   Print usage
    -l, --label=[]           Set meta data on a container
    --label-file=[]          Read in a line delimited file of labels
    --link=[]                Add link to another container
    --name                   Function name
    --noauto-volume          Do not create volumes specified in image
    -P, --publish-all        Publish all exposed ports to random ports
    -p, --publish=[]         Publish a container's port(s) to the host
    --sg=[]                  Security group for each container
    --size=s4                The size of function containers to run the funciton (e.g. s1, s2, s3, s4, m1, m2, m3, l1, l2, l3)
    --stop-signal=SIGTERM    Signal to stop a container, SIGTERM by default
    -t, --tty                Allocate a pseudo-TTY
    --timeout=300            The maximum execution duration of function call
    --volumes-from=[]        Mount shared volumes from the specified container(s)
    -w, --workdir            Working directory inside the container
```

Creates a new function with the specified image and options.

## Examples

**Create a function:**

```
$ hyper func create --name helloworld ubuntu echo HelloWorld
helloworld is created with the address of https://us-west-1.hyperfunc.io/call/helloworld/e62c014e-386c-42ea-8d07-41d44e98cc3d
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://hyperhq.gitbook.io/docs-hyper-sh/index-2/index/index-7/create.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
