Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • systemes-dinformation/alpha/pocs/cloud-machinist/cloud-machinist-templates/scaleway-attack-instances-template
  • systemes-dinformation/alpha/projects/labo-rust
  • systemes-dinformation/alpha/pocs/cloud-machinist/cloud-machinist-templates/scaleway-instances-template
  • systemes-dinformation/alpha/projects/api-table
  • systemes-dinformation/alpha/pocs/caldera
  • hnouts/scaleway-instances-template
  • bdumont/scaleway-instances-template
  • jrincker/scaleway-instances-template
8 results
Show changes
Commits on Source (3)
This diff is collapsed.
......@@ -55,6 +55,8 @@ After deployment, each resource can be accessed through HTTPS, URL depends on th
- **TTYD :** `https://terminal-<INSTANCE_COUNT>.<ENVIRONMENT>-<INSTANCE_COUNT>.<PROJECT_DOMAIN>.com/`
- **Atrium :** `https://<ENVIRONMENT>-<INSTANCE_COUNT>.<PROJECT_DOMAIN>.com/`
The instance count part of the urls should be removed if there is only one instance deployed.
**Example :**
- https://terminal-1.rust-1.daag.alpha.grandlyon.com/
- https://rust-1.daag.alpha.grandlyon.com/
\ No newline at end of file
......@@ -9,7 +9,7 @@ apps: # optional : applications served by atrium
icon: terminal
color: 4292030255
is_proxy: true
host: terminal-%atrium_count_index%
host: terminal%-atrium_count_index%
target: localhost:8081
secured: true
login: admin
......@@ -20,4 +20,4 @@ users:
- login: admin
password: %user_password_hash%
roles:
- ADMINS
\ No newline at end of file
- ADMINS
......@@ -5,6 +5,7 @@
#
export USER_PASSWORD_HASH=$(echo -n "$(scw-userdata user_password)" | argon2 "$(echo $RANDOM | md5sum | head -c 12)" -id -l 32 -e)
export ATRIUM_COUNT_INDEX=$(scw-userdata atrium_count_index)
mkdir -p /root/atrium/data && mkdir -p /root/atrium/letsencrypt_cache
curl https://forge.grandlyon.com/systemes-dinformation/alpha/pocs/cloud-machinist/cloud-machinist-templates/scaleway-instances-template/-/raw/main/instance-scripts/config-files/atrium.yaml -o root/atrium/atrium.yaml
......@@ -12,7 +13,14 @@ curl https://forge.grandlyon.com/systemes-dinformation/alpha/pocs/cloud-machinis
sed -i "s|%atrium_hostname%|$(scw-userdata atrium_hostname)|g" /root/atrium/atrium.yaml
sed -i "s|%project_domain%|$(scw-userdata project_domain)|g" /root/atrium/atrium.yaml
sed -i "s|%atrium_letsencrypt_email%|$(scw-userdata atrium_letsencrypt_email)|g" /root/atrium/atrium.yaml
sed -i "s|%atrium_count_index%|$(scw-userdata atrium_count_index)|g" /root/atrium/atrium.yaml
if [ "$ATRIUM_COUNT_INDEX" -eq 0 ]; then
sed -i "s|%-atrium_count_index%||g" /root/atrium/atrium.yaml
echo "test1"
else
# Apply this if the value is greater than 0
sed -i "s|%-atrium_count_index%|-$(scw-userdata atrium_count_index)|g" /root/atrium/atrium.yaml
echo "test2"
fi
sed -i "s|%user_password_hash%|$USER_PASSWORD_HASH|g" /root/atrium/atrium.yaml
sed -i "s|%user_password%|$(scw-userdata user_password)|g" /root/atrium/atrium.yaml
chown -Rf 1000:1000 /root/atrium
......@@ -29,3 +37,6 @@ docker run -d --name atrium \
-v /root/atrium/data:/app/data nicolaspernoud/atrium:latest