# big-bear-pterodactyl-wings configuration
name: big-bear-pterodactyl-wings
# Services section that specifies how the different services should be run
services:
  # This is the main app service for Pterodactyl Wings
  app:
    # Name of the container
    container_name: pterodactyl-wings
    # Docker image to use for the container
    image: ghcr.io/pterodactyl/wings:v1.12.1
    # Determines the restart policy. In this case, the container will always restart if it stops.
    restart: always
    # Maps the host's port 2022 to the container's port 2022
    ports:
      - "8080:8080"
      - "2022:2022"
    # Allocate a pseudo-TTY, making it act like a terminal
    tty: true
    # Set environment variables for the container
    environment:
      # Set the timezone to UTC
      TZ: "UTC"
      # Set the User ID for the Wings process
      WINGS_UID: 988
      # Set the Group ID for the Wings process
      WINGS_GID: 988
      # Set the username for the Wings process
      WINGS_USERNAME: pterodactyl
    # Mount paths from the host into the container
    volumes:
      # Mount the Docker socket, allowing the container to communicate with the host's Docker daemon
      - "/var/run/docker.sock:/var/run/docker.sock"
      # Mount the Docker containers directory
      - "/var/lib/docker/containers/:/var/lib/docker/containers/"
      # Mount the SSL certificates in read-only mode
      - "/etc/ssl/certs:/etc/ssl/certs:ro"
      # Mount a temporary directory for Pterodactyl
      - "/tmp/pterodactyl:/tmp/pterodactyl/"
      # Mount the configuration directory for Pterodactyl
      - "/etc/pterodactyl:/etc/pterodactyl/"
      # Mount the logs directory for Pterodactyl
      - "/var/log/pterodactyl:/var/log/pterodactyl/"
      # Mount the library directory for Pterodactyl
      - "/var/lib/pterodactyl:/var/lib/pterodactyl/"
    x-casaos:
      envs:
        - container: TZ
          description:
            en_us: 'Container Variable: TZ'
        - container: WINGS_UID
          description:
            en_us: 'Container Variable: WINGS_UID'
        - container: WINGS_GID
          description:
            en_us: 'Container Variable: WINGS_GID'
        - container: WINGS_USERNAME
          description:
            en_us: 'Container Variable: WINGS_USERNAME'
      volumes:
        - container: /var/run/docker.sock
          description:
            en_us: 'Container Path: /var/run/docker.sock'
        - container: /var/lib/docker/containers/
          description:
            en_us: 'Container Path: /var/lib/docker/containers/'
        - container: /etc/ssl/certs
          description:
            en_us: 'Container Path: /etc/ssl/certs'
        - container: /tmp/pterodactyl/
          description:
            en_us: 'Container Path: /tmp/pterodactyl/'
        - container: /etc/pterodactyl/
          description:
            en_us: 'Container Path: /etc/pterodactyl/'
        - container: /var/log/pterodactyl/
          description:
            en_us: 'Container Path: /var/log/pterodactyl/'
        - container: /var/lib/pterodactyl/
          description:
            en_us: 'Container Path: /var/lib/pterodactyl/'
      ports:
        - container: "8080"
          description:
            en_us: 'Container Port: 8080'
        - container: "2022"
          description:
            en_us: 'Container Port: 2022'
x-casaos:
  # Supported CPU architectures for this application
  architectures:
    - amd64
    - arm64
  # Main service for this application
  main: app
  # Detailed description for the application
  description:
    en_us: Wings is Pterodactyl's server control plane, built for the rapidly changing gaming industry and designed to be highly performant and secure. Wings provides an HTTP API allowing you to interface directly with running server instances, fetch server logs, generate backups, and control all aspects of the server lifecycle.
  # Brief tagline for the application
  tagline:
    en_us: Pterodactyl Wings
  # Developer's information
  developer: pterodactyl
  # Author of this particular configuration
  author: BigBearTechWorld
  # Icon URL for the application
  icon: https://cdn.jsdelivr.net/gh/selfhst/icons/png/pterodactyl.png
  # Thumbnail image for the application (if any)
  thumbnail: ""
  # Installation tips
  tips:
    before_install:
      en_us: |
        Before setting up Pterodactyl Wings in your container, you need to ensure that the node is properly configured in the Pterodactyl panel. Follow these steps:

        Create the Node in the Pterodactyl Panel: If you haven't already, initiate and configure the node within the Pterodactyl panel.

        Copy the Configuration: After creating the node, the panel will provide a configuration file. You need to copy the content of this configuration and place it in:

        ```
        /etc/pterodactyl/config.yml
        ```

        Tip: Use the CasaOS files app for an easy file management experience.

        Restart the Container: Once the configuration is in place, ensure you restart the container for the changes to take effect.
  # Title for the application
  title:
    en_us: Pterodactyl Wings
  # Category under which the application falls
  category: BigBearCasaOS
  # Default port mapping for the application
  port_map: "2022"
