Skip to content
Open

Floci #2507

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions ct/floci.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
#!/usr/bin/env bash
_CS_DEFAULT_URL="https://raw.githubusercontent.com/community-scripts/DevScripts/main"
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
# Copyright (c) 2021-2026 community-scripts ORG
# Author: Marc Went (Dunky13)
# License: MIT | https://github.com/community-scripts/DevScripts/raw/main/LICENSE
# Source: https://github.com/floci-io/floci

APP="Floci"
var_tags="${var_tags:-aws;developer;testing}"
var_cpu="${var_cpu:-2}"
var_ram="${var_ram:-3072}"
var_disk="${var_disk:-6}"
var_os="${var_os:-debian}"
var_version="${var_version:-13}"
var_arm64="${var_arm64:-yes}"
var_unprivileged="${var_unprivileged:-1}"

header_info "$APP"
variables
color
catch_errors

function update_script() {
header_info
check_container_storage
check_container_resources

if [[ ! -d /opt/floci ]]; then
msg_error "No ${APP} Installation Found!"
exit
fi

if check_for_gh_release "floci" "floci-io/floci"; then
msg_info "Stopping Floci"
systemctl stop floci
msg_ok "Stopped Floci"

JAVA_VERSION="25" setup_java
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "floci" "floci-io/floci" "tarball"

msg_info "Building Floci"
cd /opt/floci
$STD mvn -B clean package -Dmaven.test.skip=true
rm -rf ~/.m2
msg_ok "Built Floci"

msg_info "Starting Floci"
systemctl start floci
msg_ok "Started Floci"
msg_ok "Updated successfully!"
fi
exit
}

start
build_container
description

msg_ok "Completed Successfully!\n"
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
echo -e "${GATEWAY}${BGN}http://${IP}:4566${CL}"
67 changes: 67 additions & 0 deletions install/floci-install.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
#!/usr/bin/env bash

# Copyright (c) 2021-2026 community-scripts ORG
# Author: Marc Went (Dunky13)
# License: MIT | https://github.com/community-scripts/DevScripts/raw/main/LICENSE
# Source: https://github.com/floci-io/floci

source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
color
verb_ip6
catch_errors
setting_up_container
network_check
update_os

JAVA_VERSION="25" setup_java

# after setup_java, so Temurin satisfies maven's Java dependency instead of pulling in OpenJDK
msg_info "Installing Dependencies"
$STD apt install -y maven
msg_ok "Installed Dependencies"

fetch_and_deploy_gh_release "floci" "floci-io/floci" "tarball"

msg_info "Building Floci"
cd /opt/floci
$STD mvn -B clean package -Dmaven.test.skip=true
rm -rf ~/.m2
msg_ok "Built Floci"

msg_info "Configuring Floci"
mkdir -p /opt/floci_data
cat <<EOF >/opt/floci_data/.env
QUARKUS_HTTP_HOST=0.0.0.0
FLOCI_SECURITY_ALLOW_UNSAFE_NETWORK_EXPOSURE=true
FLOCI_BASE_URL=http://${LOCAL_IP}:4566
FLOCI_STORAGE_MODE=persistent
FLOCI_STORAGE_PERSISTENT_PATH=/opt/floci_data/data
FLOCI_SERVICES_UI_ENABLED=false
EOF
msg_ok "Configured Floci"

msg_info "Creating Service"
cat <<EOF >/etc/systemd/system/floci.service
[Unit]
Description=Floci
After=network.target

[Service]
Type=simple
User=root
WorkingDirectory=/opt/floci_data
EnvironmentFile=/opt/floci_data/.env
ExecStart=/usr/bin/java --enable-native-access=ALL-UNNAMED -jar /opt/floci/target/quarkus-app/quarkus-run.jar
SuccessExitStatus=143
Restart=on-failure
RestartSec=5

[Install]
WantedBy=multi-user.target
EOF
systemctl enable -q --now floci
msg_ok "Created Service"

motd_ssh
customize
cleanup_lxc
53 changes: 53 additions & 0 deletions json/floci.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"name": "Floci",
"slug": "floci",
"categories": [
20
],
"date_created": "2026-11-06",
"type": "ct",
"updateable": true,
"privileged": false,
"architectures": [
"amd64",
"arm64"
],
"interface_port": 4566,
"documentation": "https://floci.io/floci/",
"website": "https://floci.io/floci/",
"repository": "https://github.com/floci-io/floci",
"logo": "https://cdn.jsdelivr.net/gh/floci-io/floci@main/docs/assets/floci.svg",
"description": "Floci is a free, open source local AWS emulator for development and CI. It serves S3, SQS, SNS, DynamoDB, IAM, Lambda, Secrets Manager and many more services on a single endpoint at port 4566, so the AWS CLI and SDKs work against it by setting an endpoint URL.",
"install_methods": [
{
"type": "default",
"script": "ct/floci.sh",
"config_path": "/opt/floci_data/.env",
"resources": {
"cpu": 2,
"ram": 3072,
"hdd": 6,
"os": "Debian",
"version": "13"
}
}
],
"default_credentials": {
"username": null,
"password": null
},
"notes": [
{
"text": "Floci has no authentication. Use any non-empty AWS access key and secret (for example test/test), region us-east-1, and set the endpoint URL to http://<container-ip>:4566. Keep it on a trusted network.",
"type": "warning"
},
{
"text": "Docker is not installed, so services that run containers (Lambda, ECS, RDS, ElastiCache, EKS and similar) are limited or unavailable. S3, SQS, SNS, DynamoDB and the other core services work.",
"type": "info"
},
{
"text": "Response URLs such as SQS queue URLs use FLOCI_BASE_URL in /opt/floci_data/.env, set to the container IP at install. Update it and restart floci when the IP changes or clients reach Floci through a hostname.",
"type": "info"
}
]
}
Loading